Wallets

Bulk Upload Wallets

Adds wallets for recipients in your organization (1 to 1000 per call). Needs a CLIENT_ORG_ADMIN or FINANCE_ADMIN token and the Token Grants module. If any row has an unknown network, wallet type or recipient, or a blank address, nothing is created and the call returns HTTP 200 with success false and a message.

POSThttps://app.toku.com/api/tokuApi/v1/bulkUploadMultipleWallets

This is the v1 (legacy) API. The current API is in the API reference.

curl --request POST \
  --url 'https://app.toku.com/api/tokuApi/v1/bulkUploadMultipleWallets' \
  --header 'Authorization: Bearer <token>' \
  --header 'x-role-type: CLIENT_ORG_ADMIN' \
  --header 'Content-Type: application/json' \
  --data '{
  "wallets": [
    {
      "recipientID": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "walletAddress": "string",
      "networkName": "Ethereum",
      "walletType": "string",
      "nickName": "string"
    }
  ]
}'
200 response
{
  "data": {
    "success": true,
    "createdWallets": 0,
    "message": "string"
  },
  "error": null
}

Authorizations

Authorizationstringheaderrequired

Bearer authentication header of the form Bearer <token>, where <token> is your API token.

Headers

x-role-typestringrequired

Seat role the token acts as. The token's creator must hold this role in the token's organization; TOKU_ADMIN and unknown values are refused with 401. This operation accepts CLIENT_ORG_ADMIN and FINANCE_ADMIN; other roles get 403. FINANCE_ADMIN seats are refused in new-system organizations.

Available options: CLIENT_ORG_ADMIN, FINANCE_ADMIN

Body

application/json

walletsobject[]required

Allowed: 1 to 1000 items

Show child attributes
recipientIDstring<uuid>required

roleInOrgID of the recipient

walletAddressstringrequired

Allowed: at least 1 characters

networkNamestringrequired

Name of one of the organization's networks

Allowed: at least 1 characters

walletTypestringrequired

Name of one of the organization's custom wallet types (GET /getWalletTypes)

Allowed: at least 1 characters

nickNamestring

Response

200Wallets uploaded
dataobjectrequired
Show child attributes
successbooleanrequired
createdWalletsintegerrequired
messagestring

Set when success is false

errorobject | nullrequired

Always null on success

401The token is missing, invalid or expired
errorstringrequired

What went wrong

403The token's seat doesn't have the permission this operation needs
errorobjectrequired
Show child attributes
messagestringrequired
429Too many requests from this address or token. Wait for the number of seconds in the Retry-After header, then retry.
errorstringrequired

What went wrong

500The operation failed. This includes input that doesn't match what the operation accepts; error.message says what was wrong.
errorobjectrequired
Show child attributes
messagestringrequired
Was this page helpful? Suggest edits