Add Child Account
Add child account to a parent account, the parent account needs to be enabled by the “partner” field. A SMS code will be sent to child account for verification
HTTP Request
- cURL
- JavaScript
curl -X GET \
'https://apistg.ahamove.com/v1/partner/add_child_account?token=<TOKEN_STG>&child_id=84xxxxxxxxx' \
-H 'cache-control: no-cache'
var requestOptions = {
method: 'GET',
redirect: 'follow',
};
fetch(
'https://apistg.ahamove.com/v1/partner/add_child_account?token=<TOKEN_STG>&child_id=84xxxxxxxxx',
requestOptions
)
.then((response) => response.text())
.then((result) => console.log(result))
.catch((error) => console.log('error', error));
GET https://apistg.ahamove.com/v1/partner/add_child_account
Query Parameters
Parameter | Type | Required | Description |
---|---|---|---|
token | String | Yes | Parent token. |
child_id | String | Yes | Child Account ID. |
Response
JSON response example:
{}
Status-Code: 200 OK
Errors
Code | Text | Description |
---|---|---|
404 | Not Found | Token not found, child_id not found. |
401 | Unauthorized | Parent account doesn’t have the “partner” field or child account belongs to another partner. |
409 | Conflict | Parent account existed, Sub-child accounts existed (The child account already has a parent or is already a parent of other accounts). |
500 | Internal Server Error | We had a problem with our server. Try again later. |
503 | Service Unavailable | We're temporarily offline for maintenance. Please try again later. |