Create a client
curl --request POST \
--url https://api.example.com/clients \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"email": "[email protected]"
}
'import requests
url = "https://api.example.com/clients"
payload = {
"name": "<string>",
"email": "[email protected]"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({name: '<string>', email: '[email protected]'})
};
fetch('https://api.example.com/clients', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "cl_9f2c1ab84d7e4f1fa3c65b0e7d9a2c41",
"status": "provisioning",
"createdAt": "2023-11-07T05:31:56Z",
"name": "<string>",
"email": "<string>",
"phone": "<string>",
"baseSmartWallet": "<string>",
"kybStatus": "notStarted",
"kybApplicationId": "kyb_9f2c1ab84d7e4f1fa3c65b0e7d9a2c41",
"verifiedAt": "2023-11-07T05:31:56Z",
"failure": {
"code": "provisioning_failed",
"message": "<string>",
"retriable": false
},
"pollUrl": "<string>",
"transferPolicy": {
"allowFiat": true,
"allowCrypto": true,
"allowThirdParty": true,
"allowEscrowThirdParty": true,
"allowSwap": true,
"allowPartnerGroupPayments": true,
"dualApproval": true,
"isFrozen": true,
"recoveryModeActivated": true
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {}
}
}Clients
Create a client
Open a company account for a client of yours. HEVN keeps no wallet for it, so register the client’s addresses through /client/accounts. Returns 202 with the client in provisioning. Poll pollUrl with the returned id in X-Hevn-Account until it is ready, which it becomes once the account exists and holds an active external account. Retrying with the same Idempotency-Key returns the same client.
POST
/
clients
Create a client
curl --request POST \
--url https://api.example.com/clients \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"email": "[email protected]"
}
'import requests
url = "https://api.example.com/clients"
payload = {
"name": "<string>",
"email": "[email protected]"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({name: '<string>', email: '[email protected]'})
};
fetch('https://api.example.com/clients', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "cl_9f2c1ab84d7e4f1fa3c65b0e7d9a2c41",
"status": "provisioning",
"createdAt": "2023-11-07T05:31:56Z",
"name": "<string>",
"email": "<string>",
"phone": "<string>",
"baseSmartWallet": "<string>",
"kybStatus": "notStarted",
"kybApplicationId": "kyb_9f2c1ab84d7e4f1fa3c65b0e7d9a2c41",
"verifiedAt": "2023-11-07T05:31:56Z",
"failure": {
"code": "provisioning_failed",
"message": "<string>",
"retriable": false
},
"pollUrl": "<string>",
"transferPolicy": {
"allowFiat": true,
"allowCrypto": true,
"allowThirdParty": true,
"allowEscrowThirdParty": true,
"allowSwap": true,
"allowPartnerGroupPayments": true,
"dualApproval": true,
"isFrozen": true,
"recoveryModeActivated": true
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {}
}
}Authorizations
Headers
Body
application/json
Response
Successful Response
Was this page helpful?