Create MT4 Account
POST /public/v1/users/{user_id}/mt4/accounts
Path Variables
| Name | Type | Required | Rule | Description |
|---|---|---|---|---|
| user_id | string | Mandatory | length 8 | the unique ID of client |
Request Body
| Key | Type | Required | Rule | Description |
|---|---|---|---|---|
| connection_id | string | Mandatory | MT4 Server ID given by this API | |
| group | string | Mandatory | MT4 group name | |
| leverage | number | Mandatory | minimum 1 maximum 5000 | account leverage |
| login | number | Optional | custom account login | |
| account_type_id | string | Optional | length 8 | CRM account type |
| rebate_user_id | string | Optional | length 8 | CRM user that gets the commission |
| master_password | string | Optional | min length 5 max length 15, at least two of three character types (lowercase, uppercase, or digits) | master password |
| investor_password | string | Optional | min length 5 max length 15, at least two of three character types (lowercase, uppercase, or digits) | investor password |
| enable_readonly | boolean | Optional | disallow trading on account | |
| enable_rebate | boolean | Optional | set this account as commission receiving account | |
| send_email | boolean | Optional | send CRM user an email for account creation | |
| send_pop_up | boolean | Optional | send CRM user an in-app popup for account creation | |
| language | string | Optional | language code | user language for email/popup |
Expected HTTP status code
- 200
Response
| Name | Type | Description |
|---|---|---|
| login | number | account login |
| master_password | string | master password |
| investor_password | string | investor password |
Error
| Code | Type | Description |
|---|---|---|
400 | mt4_connection_not_found | Cannot find connection from given connection_id |