Activities
- Overview
- Create API Keys
- Create Authenticators
- Create Invitations
- Create Oauth Providers
- Create Policies
- Create Policy
- Create Private Key Tag
- Create Private Keys
- Create Read Only Session
- Create Read Write Session
- Create Sub-Organization
- Create User Tag
- Create Users
- Create Wallet
- Create Wallet Accounts
- Delete API Keys
- Delete Authenticators
- Delete Invitation
- Delete Oauth Providers
- Delete Policy
- Delete Private Key Tags
- Delete Private Keys
- Delete Sub Organization
- Delete User Tags
- Delete Users
- Delete Wallets
- Export Private Key
- Export Wallet
- Export Wallet Account
- Import Private Key
- Import Wallet
- Init Email Recovery
- Init Import Private Key
- Init Import Wallet
- Init OTP auth
- Oauth
- OTP auth
- Perform Email Auth
- Recover a user
- Remove Organization Feature
- Set Organization Feature
- Sign Raw Payload
- Sign Raw Payloads
- Sign Transaction
- Update Policy
- Update Private Key Tag
- Update Root Quorum
- Update User
- Update User Tag
- Update Wallet
Queries
- Overview
- Get Activity
- Get API key
- Get Authenticator
- Get Authenticators
- Get Configs
- Get Oauth providers
- Get Policy
- Get Private Key
- Get Suborgs
- Get User
- Get Verified Suborgs
- Get Wallet
- Get Wallet Account
- List Activities
- List Policies
- List Private Key Tags
- List Private Keys
- List User Tags
- List Users
- List Wallets
- List Wallets Accounts
- Who am I?
Create Sub-Organization
Create a new Sub-Organization
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/create_sub_organization \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V7",
"timestampMs": "<string> (e.g., 1745474677467)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"subOrganizationName": "<string>",
"rootUsers": [
{
"userName": "<string>",
"userEmail": "<string>",
"userPhoneNumber": "<string>",
"apiKeys": [
{
"apiKeyName": "<string>",
"publicKey": "<string>",
"curveType": "<API_KEY_CURVE_P256>",
"expirationSeconds": "<string>"
}
],
"authenticators": [
{
"authenticatorName": "<string>",
"challenge": "<string>",
"attestation": {
"credentialId": "<string>",
"clientDataJson": "<string>",
"attestationObject": "<string>",
"transports": [
"<AUTHENTICATOR_TRANSPORT_BLE>"
]
}
}
],
"oauthProviders": [
{
"providerName": "<string>",
"oidcToken": "<string>"
}
]
}
],
"rootQuorumThreshold": 123,
"wallet": {
"walletName": "<string>",
"accounts": [
{
"curve": "<CURVE_SECP256K1>",
"pathFormat": "<PATH_FORMAT_BIP32>",
"path": "<string>",
"addressFormat": "<ADDRESS_FORMAT_UNCOMPRESSED>"
}
],
"mnemonicLength": 123
},
"disableEmailRecovery": true,
"disableEmailAuth": true,
"disableSmsAuth": true,
"disableOtpEmailAuth": true
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V7",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g., 1745474677467)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"createSubOrganizationIntentV7": {
"subOrganizationName": "<string>",
"rootUsers": [
{
"userName": "<string>",
"userEmail": "<string>",
"userPhoneNumber": "<string>",
"apiKeys": [
{
"apiKeyName": "<string>",
"publicKey": "<string>",
"curveType": "<API_KEY_CURVE_P256>",
"expirationSeconds": "<string>"
}
],
"authenticators": [
{
"authenticatorName": "<string>",
"challenge": "<string>",
"attestation": {
"credentialId": "<string>",
"clientDataJson": "<string>",
"attestationObject": "<string>",
"transports": [
"<AUTHENTICATOR_TRANSPORT_BLE>"
]
}
}
],
"oauthProviders": [
{
"providerName": "<string>",
"oidcToken": "<string>"
}
]
}
],
"rootQuorumThreshold": 123,
"wallet": {
"walletName": "<string>",
"accounts": [
{
"curve": "<CURVE_SECP256K1>",
"pathFormat": "<PATH_FORMAT_BIP32>",
"path": "<string>",
"addressFormat": "<ADDRESS_FORMAT_UNCOMPRESSED>"
}
],
"mnemonicLength": 123
},
"disableEmailRecovery": true,
"disableEmailAuth": true,
"disableSmsAuth": true,
"disableOtpEmailAuth": true
}
},
"result": {
"createSubOrganizationResultV7": {
"subOrganizationId": "<string>",
"wallet": {
"walletId": "<string>",
"addresses": [
"<string_element>"
]
},
"rootUserIds": [
"<string_element>"
]
}
}
}
}
}
}
Authorizations
Body
Enum options: ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V7
Timestamp (in milliseconds) of the request, used to verify liveness of user requests.
Unique identifier for a given Organization.
parameters field
Root users to create within this sub-organization
The user’s phone number in E.164 format e.g. +13214567890
A list of API Key parameters. This field, if not needed, should be an empty array in your request body.
The public component of a cryptographic key pair used to sign messages and transactions.
Enum options: API_KEY_CURVE_P256
, API_KEY_CURVE_SECP256K1
, API_KEY_CURVE_ED25519
A list of Authenticator parameters. This field, if not needed, should be an empty array in your request body.
Human-readable name for an Authenticator.
Challenge presented for authentication purposes.
attestation field
The cbor encoded then base64 url encoded id of the credential.
A base64 url encoded payload containing metadata about the signing context and the challenge.
A base64 url encoded payload containing authenticator data and any attestation the webauthn provider chooses.
The threshold of unique approvals to reach root quorum. This value must be less than or equal to the number of root users
wallet field
Enum options: CURVE_SECP256K1
, CURVE_ED25519
Enum options: ADDRESS_FORMAT_UNCOMPRESSED
, ADDRESS_FORMAT_COMPRESSED
, ADDRESS_FORMAT_ETHEREUM
, ADDRESS_FORMAT_SOLANA
, ADDRESS_FORMAT_COSMOS
, ADDRESS_FORMAT_TRON
, ADDRESS_FORMAT_SUI
, ADDRESS_FORMAT_APTOS
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2PKH
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2SH
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2WPKH
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2WSH
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2TR
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2PKH
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2SH
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2WPKH
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2WSH
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2TR
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2PKH
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2SH
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2WPKH
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2WSH
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2TR
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2PKH
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2SH
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2WPKH
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2WSH
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2TR
, ADDRESS_FORMAT_SEI
, ADDRESS_FORMAT_XLM
, ADDRESS_FORMAT_DOGE_MAINNET
, ADDRESS_FORMAT_DOGE_TESTNET
, ADDRESS_FORMAT_TON_V3R2
, ADDRESS_FORMAT_TON_V4R2
, ADDRESS_FORMAT_XRP
Response
A successful response returns the following fields:
The activity object containing type, intent, and result
The intent of the activity
The createSubOrganizationIntentV7 object
Name for this sub-organization
Root users to create within this sub-organization
Human-readable name for a User.
The user’s phone number in E.164 format e.g. +13214567890
A list of API Key parameters. This field, if not needed, should be an empty array in your request body.
Human-readable name for an API Key.
The public component of a cryptographic key pair used to sign messages and transactions.
curveType field
Enum options: API_KEY_CURVE_P256
, API_KEY_CURVE_SECP256K1
, API_KEY_CURVE_ED25519
A list of Authenticator parameters. This field, if not needed, should be an empty array in your request body.
Human-readable name for an Authenticator.
Challenge presented for authentication purposes.
attestation field
The cbor encoded then base64 url encoded id of the credential.
A base64 url encoded payload containing metadata about the signing context and the challenge.
A base64 url encoded payload containing authenticator data and any attestation the webauthn provider chooses.
The type of authenticator transports.
A list of Oauth providers. This field, if not needed, should be an empty array in your request body.
The threshold of unique approvals to reach root quorum. This value must be less than or equal to the number of root users
wallet field
Human-readable name for a Wallet.
A list of wallet Accounts. This field, if not needed, should be an empty array in your request body.
curve field
Enum options: CURVE_SECP256K1
, CURVE_ED25519
pathFormat field
Enum options: PATH_FORMAT_BIP32
Path used to generate a wallet Account.
addressFormat field
Enum options: ADDRESS_FORMAT_UNCOMPRESSED
, ADDRESS_FORMAT_COMPRESSED
, ADDRESS_FORMAT_ETHEREUM
, ADDRESS_FORMAT_SOLANA
, ADDRESS_FORMAT_COSMOS
, ADDRESS_FORMAT_TRON
, ADDRESS_FORMAT_SUI
, ADDRESS_FORMAT_APTOS
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2PKH
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2SH
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2WPKH
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2WSH
, ADDRESS_FORMAT_BITCOIN_MAINNET_P2TR
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2PKH
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2SH
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2WPKH
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2WSH
, ADDRESS_FORMAT_BITCOIN_TESTNET_P2TR
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2PKH
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2SH
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2WPKH
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2WSH
, ADDRESS_FORMAT_BITCOIN_SIGNET_P2TR
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2PKH
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2SH
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2WPKH
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2WSH
, ADDRESS_FORMAT_BITCOIN_REGTEST_P2TR
, ADDRESS_FORMAT_SEI
, ADDRESS_FORMAT_XLM
, ADDRESS_FORMAT_DOGE_MAINNET
, ADDRESS_FORMAT_DOGE_TESTNET
, ADDRESS_FORMAT_TON_V3R2
, ADDRESS_FORMAT_TON_V4R2
, ADDRESS_FORMAT_XRP
Disable email recovery for the sub-organization
Disable email auth for the sub-organization
Disable OTP SMS auth for the sub-organization
The result of the activity
The createSubOrganizationResultV7 object
subOrganizationId field
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/create_sub_organization \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V7",
"timestampMs": "<string> (e.g., 1745474677467)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"subOrganizationName": "<string>",
"rootUsers": [
{
"userName": "<string>",
"userEmail": "<string>",
"userPhoneNumber": "<string>",
"apiKeys": [
{
"apiKeyName": "<string>",
"publicKey": "<string>",
"curveType": "<API_KEY_CURVE_P256>",
"expirationSeconds": "<string>"
}
],
"authenticators": [
{
"authenticatorName": "<string>",
"challenge": "<string>",
"attestation": {
"credentialId": "<string>",
"clientDataJson": "<string>",
"attestationObject": "<string>",
"transports": [
"<AUTHENTICATOR_TRANSPORT_BLE>"
]
}
}
],
"oauthProviders": [
{
"providerName": "<string>",
"oidcToken": "<string>"
}
]
}
],
"rootQuorumThreshold": 123,
"wallet": {
"walletName": "<string>",
"accounts": [
{
"curve": "<CURVE_SECP256K1>",
"pathFormat": "<PATH_FORMAT_BIP32>",
"path": "<string>",
"addressFormat": "<ADDRESS_FORMAT_UNCOMPRESSED>"
}
],
"mnemonicLength": 123
},
"disableEmailRecovery": true,
"disableEmailAuth": true,
"disableSmsAuth": true,
"disableOtpEmailAuth": true
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V7",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g., 1745474677467)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"createSubOrganizationIntentV7": {
"subOrganizationName": "<string>",
"rootUsers": [
{
"userName": "<string>",
"userEmail": "<string>",
"userPhoneNumber": "<string>",
"apiKeys": [
{
"apiKeyName": "<string>",
"publicKey": "<string>",
"curveType": "<API_KEY_CURVE_P256>",
"expirationSeconds": "<string>"
}
],
"authenticators": [
{
"authenticatorName": "<string>",
"challenge": "<string>",
"attestation": {
"credentialId": "<string>",
"clientDataJson": "<string>",
"attestationObject": "<string>",
"transports": [
"<AUTHENTICATOR_TRANSPORT_BLE>"
]
}
}
],
"oauthProviders": [
{
"providerName": "<string>",
"oidcToken": "<string>"
}
]
}
],
"rootQuorumThreshold": 123,
"wallet": {
"walletName": "<string>",
"accounts": [
{
"curve": "<CURVE_SECP256K1>",
"pathFormat": "<PATH_FORMAT_BIP32>",
"path": "<string>",
"addressFormat": "<ADDRESS_FORMAT_UNCOMPRESSED>"
}
],
"mnemonicLength": 123
},
"disableEmailRecovery": true,
"disableEmailAuth": true,
"disableSmsAuth": true,
"disableOtpEmailAuth": true
}
},
"result": {
"createSubOrganizationResultV7": {
"subOrganizationId": "<string>",
"wallet": {
"walletId": "<string>",
"addresses": [
"<string_element>"
]
},
"rootUserIds": [
"<string_element>"
]
}
}
}
}
}
}
Was this page helpful?
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/create_sub_organization \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V7",
"timestampMs": "<string> (e.g., 1745474677467)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"subOrganizationName": "<string>",
"rootUsers": [
{
"userName": "<string>",
"userEmail": "<string>",
"userPhoneNumber": "<string>",
"apiKeys": [
{
"apiKeyName": "<string>",
"publicKey": "<string>",
"curveType": "<API_KEY_CURVE_P256>",
"expirationSeconds": "<string>"
}
],
"authenticators": [
{
"authenticatorName": "<string>",
"challenge": "<string>",
"attestation": {
"credentialId": "<string>",
"clientDataJson": "<string>",
"attestationObject": "<string>",
"transports": [
"<AUTHENTICATOR_TRANSPORT_BLE>"
]
}
}
],
"oauthProviders": [
{
"providerName": "<string>",
"oidcToken": "<string>"
}
]
}
],
"rootQuorumThreshold": 123,
"wallet": {
"walletName": "<string>",
"accounts": [
{
"curve": "<CURVE_SECP256K1>",
"pathFormat": "<PATH_FORMAT_BIP32>",
"path": "<string>",
"addressFormat": "<ADDRESS_FORMAT_UNCOMPRESSED>"
}
],
"mnemonicLength": 123
},
"disableEmailRecovery": true,
"disableEmailAuth": true,
"disableSmsAuth": true,
"disableOtpEmailAuth": true
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V7",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g., 1745474677467)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"createSubOrganizationIntentV7": {
"subOrganizationName": "<string>",
"rootUsers": [
{
"userName": "<string>",
"userEmail": "<string>",
"userPhoneNumber": "<string>",
"apiKeys": [
{
"apiKeyName": "<string>",
"publicKey": "<string>",
"curveType": "<API_KEY_CURVE_P256>",
"expirationSeconds": "<string>"
}
],
"authenticators": [
{
"authenticatorName": "<string>",
"challenge": "<string>",
"attestation": {
"credentialId": "<string>",
"clientDataJson": "<string>",
"attestationObject": "<string>",
"transports": [
"<AUTHENTICATOR_TRANSPORT_BLE>"
]
}
}
],
"oauthProviders": [
{
"providerName": "<string>",
"oidcToken": "<string>"
}
]
}
],
"rootQuorumThreshold": 123,
"wallet": {
"walletName": "<string>",
"accounts": [
{
"curve": "<CURVE_SECP256K1>",
"pathFormat": "<PATH_FORMAT_BIP32>",
"path": "<string>",
"addressFormat": "<ADDRESS_FORMAT_UNCOMPRESSED>"
}
],
"mnemonicLength": 123
},
"disableEmailRecovery": true,
"disableEmailAuth": true,
"disableSmsAuth": true,
"disableOtpEmailAuth": true
}
},
"result": {
"createSubOrganizationResultV7": {
"subOrganizationId": "<string>",
"wallet": {
"walletId": "<string>",
"addresses": [
"<string_element>"
]
},
"rootUserIds": [
"<string_element>"
]
}
}
}
}
}
}