Partner attribution
Broker → cTrader endpoints for managing the partnerId used in trader attribution. Authenticated with the Manager Token (see Authentication of API calls).
Set a partner identifier
Assigns a partner identifier from the broker's backend to an existing user or account in cTrader.
| Method | URL |
|---|---|
PUT | /oauth2/ctid/referral |
Request body
| Key | Required? | Data type | Description |
|---|---|---|---|
brokerCrmName | Yes | string | See broker identification. |
partnerId | Yes | string | The partner identifier string to assign. |
userId | No (required if assigning to a user) | integer | The unique ID of the user. |
ctidTraderAccountId | No (required if assigning to an account) | integer | The unique ID of the linkage between a user and a trading account. |
Expected status code
200
Errors
See Error codes.
Read a partner identifier
Retrieves the partner identifier assigned to a specific user or account.
| Method | URL |
|---|---|
GET | /oauth2/ctid/referral |
Query parameters
| Parameter | Required? | Data type | Description |
|---|---|---|---|
brokerCrmName | Yes | string | See broker identification. |
userId | No (required if the partner is a user) | integer | The unique ID of the user. |
ctidTraderAccountId | No (required if the partner is an account) | integer | The unique ID of the linkage between a user and a trading account. |
Output
| Key | Data type | Description |
|---|---|---|
userId | integer | The unique ID of the user. |
ctidTraderAccountId | integer | The unique ID of the linkage between a user and a trading account. |
partnerId | string | The partner identifier string assigned to the entity. |
Expected status code
200
Errors
See Error codes.
Delete a partner identifier
Deletes the partner identifier attached to a specific user or account.
| Method | URL |
|---|---|
DELETE | /oauth2/ctid/referral |
Query parameters
| Parameter | Required? | Data type | Description |
|---|---|---|---|
brokerCrmName | Yes | string | See broker identification. |
userId | Yes | integer | The unique ID of the user. |
ctidTraderAccountId | No | integer | The unique ID of the linkage between a user and a trading account. If unspecified, only the user-level record is deleted. |
Expected status code
200
Errors
See Error codes.