Create a client wallet
Changed onThis POST endpoint creates a new wallet for your own client account, in the requested currency. <br> To use this endpoint, you need to provide the currency_code as a JSON parameter in the Request Body. It must be an ISO 4217 currency code, such as USD, EUR or MXN. <br> A client can hold at most one wallet per currency, so the operation is idempotent: if you already have a wallet in the requested currency, that existing wallet is returned unchanged with a 200 status code instead of 201, and its balance reflects the current balance. <br> Newly created wallets start with a zero balance and can be funded through top-ups, pay-ins or wallet transfers. Client wallets are listed by the GET operation on /payout/account/balance. <br> A client wallet in a currency you have not funded payouts from before may need to be linked to a liquidity provider by MassPay before it can fund payouts; contact your account manager after creating one.
Request
- Base URLhttps://api.masspay.io/v1.0.0
- Auth
- API key in header Authorization
- or API key in header x-api-key
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Headers
Unique key to prevent duplicate processing
Request body
Example request
{
"currency_code": "EUR"
}Response
You already have a wallet in the requested currency; the existing wallet is returned and nothing is created.
Example response
{
"token": "usr_wlt_9e5a349e-8d10-4a0b-9d8f-6b3f2a1c4d7e",
"type": "USER_FUNDS",
"user_token": "usr_59a9ccce-0280-4207-9200-891c9109915c",
"currency_code": "MXN",
"active": true,
"client_paying_fees": true,
"fee_wallet_token": "clnt_wlt_ba4275f2-bae1-488d-9d6f-20af1cd83574"
}Changes
- info
endpoint added
- info