/createAccount
1 min
POST
/createAccount
account_typearray<p>OMNIBUS accounts assume that all deposited funds will not remain at their deposit address, but instead will be collected to the Main Account by the GK8 Collector. SEGREGATED accounts assume that funds may remain in user-accessible deposit wallets.</p>
account_infoobject<p>AccountInfo:</p>
<ul>
<li>name: The name of the account. The name must be between 3 and 40 characters long, and can only contain alphanumeric characters (both lowercase and uppercase), underscores, parentheses, spaces, and hyphens. The name must not begin or end with a space or tab; only single spaces between words are accepted.</li>
<li>transaction_notification_user_ids: The email addresses of users that will receive transaction notifications for the account.</li>
<li>required_account_change_approvers: How many of the available approvers are required to approve account changes.</li>
<li>available_account_change_approver_user_ids: The email addresses of all users that are allowed to approve account changes.</li>
<li>bitcoin_address_format: Enum to specify the bitcoin address format, by default is BECH32(Native Segwit). Other options are: LEGACY: Legacy (P2PKH), NESTED_SEGWIT: Nested SegWit (P2SH)</li>
</ul>
request_extra_dataobject<p>RequestExtraData:</p>
<ul>
<li>SessionId: Unique identifier of the session.</li>
<li>MessageNumber: Sequential message of when in the session the call is made.
If this is a new session the ID must be generated. For an ongoing session, fetch the session ID from the /getAdministrativeSessionInfo endpoint.</li>
</ul>
force_approve_address_choiceboolean<p>If false, the address will be checked for balance and if a bitcoin address in a different format has a balance, the request will be rejected.</p>
acceptstringGenerated from available response content types
bodyobject
200success
curl --request POST \
--url '/createAccount?account_type=OMNIBUS&account_info=%22{%5Cn%20%20%5C%22name%5C%22%3A%20%5C%22NewAccount%5C%22%2C%20%20%5Cn%20%20%5C%22transaction_notification_user_ids%5C%22%3A%20[%5C%22user1%40org.com%5C%22%2C%20%5C%22user2%40org.com%5C%22]%2C%20%5Cn%20%20%5C%22required_account_change_approvers%5C%22%3A%202%2C%20%20%5Cn%20%20%5C%22available_account_change_approver_user_ids%5C%22%3A%20[%5C%22user3%40org.com%5C%22%2C%20%5C%22user4%40org.com%5C%22]%20%20%5Cn}%5Cn%22&request_extra_data=%22None%22&force_approve_address_choice=true' \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data-raw '{
"FunctionData": {
"AvailableAccountChangeApproverUserIds": [
"[email protected]",
"[email protected]"
],
"Name": "NewAccount",
"RequestExtraData": {
"MessageNumber": 2,
"SessionId": "645eebbd-a833-4767-9c49-e48fc312d6ab"
},
"RequiredAccountChangeApprovers": 2,
"TransactionNotificationUserIds": [
"user1",
"user2"
]
},
"Meta": {
"FunctionName": "createAccount",
"RandomData": "288cd49d4b8bf00e7d6114b78d5668d5581d6b953fafef779133caa844cd4229",
"Destination": "b9cb8afe52f1d52521cf2b62dfe12146156ad5328f83c62c20c7da81b263356a61340de745c858998544c041798b01c2f4fac31bebe52a19280a32cd57d6d374ea",
"Time": "2021-02-07T18:37:46.948Z",
"Source": "048b99461a70a49abe63fd585cb224177a22a92d2e9e4ddfbc0027887bee9d1843388f42a3eb2e740565e115ad8b7981abf59e3b03b771f4b063b53c517d7a9d99",
"AccessToken": "51311c84d2c8fd2fafbe56ceb1fb30a99d3417abfc55769577338ab286798087"
}
}'