Skip to main content
POST
/
api
/
partner
/
v2
/
user
/
{userId}
/
wallets
cURL
curl --request POST \
  --url https://staging-api.capa.fi/api/partner/v2/user/{userId}/wallets \
  --header 'Content-Type: application/json' \
  --header 'partner-api-key: <partner-api-key>' \
  --data '
{
  "vmType": "EVM",
  "walletAddress": "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
  "alias": "<string>"
}
'
{
  "success": true,
  "data": {
    "id": "8374f327-38bd-4b0b-b8a7-2524599eb903",
    "userId": "8374f327-38bd-4b0b-b8a7-2524599eb903",
    "walletAddress": "0x4d2f3d8f83b6f2f8e0f3f4f3f3f3f3f3f3f3f3f3",
    "alias": "My Polygon Wallet",
    "vmType": "EVM",
    "enabled": true,
    "createdAt": "2025-05-08T18:00:00Z"
  }
}
Creates a new wallet for a user. The wallet address must be valid for the specified virtual machine type (EVM, SVM, or STK).

Important Notes

  • Wallet address validation is performed based on the vmType. An EVM address cannot be used with SVM, and vice versa.

Error Codes

Common Errors

HTTP StatusCodeMessage
401UNAUTHORIZED”API Key is missing”
401UNAUTHORIZED”Invalid API Key format”
401UNAUTHORIZED”Invalid API Key”
403INVALID_PARTNER_FLOW”The partner has an invalid flow.”

User Ownership Errors

HTTP StatusCodeMessage
401UNAUTHORIZED”Partner information is required for this operation”
401UNAUTHORIZED”User is not associated with the partner”

Endpoint-Specific Errors

HTTP StatusCodeMessage
400INVALID_USER_INPUT_ERROR”Invalid User Input”
400UserOnRampWalletDuplicateError”A wallet with this address and VM type already exists.”

Headers

partner-api-key
string
required

Api key for the affiliated partner that is performing the request

Path Parameters

userId
string
required

The userId of the user

Example:

"8374f327-38bd-4b0b-b8a7-2524599eb903"

Body

application/json
vmType
enum<string>
required

The virtual machine type for the wallet

Available options:
EVM,
SVM,
STK
Example:

"EVM"

walletAddress
string
required

The wallet address

Example:

"0x71C7656EC7ab88b098defB751B7401B5f6d8976F"

alias
string
required

The alias name for the wallet

Response

201 - application/json

Creates a new wallet for a user

success
boolean
Example:

true

data
object