Withdrawal methods
Use these methods to obtain data about withdrawal methods and groups configured in the Back Office, as well as withdrawal currencies enabled for these methods and commissions that are charged when clients withdrawing funds from their accounts.
GET[host]/api/v2/withdrawals/groups |
|
GET[host]/api/v2/withdrawals/groups/{groupId} |
|
POST[host]/api/v2/withdrawals/groups |
|
PUT[host]/api/v2/withdrawals/groups/{groupId} PATCH[host]/api/v2/withdrawals/groups/{groupId} |
|
DELETE[host]/api/v2/withdrawals/groups/{groupId} |
GET[host]/api/v2/withdrawals/methods |
|
GET[host]/api/v2/withdrawals/methods/{methodId} |
|
POST[host]/api/v2/withdrawals/methods |
|
PUT[host]/api/v2/withdrawals/methods/{methodId} PATCH[host]/api/v2/withdrawals/methods/{methodId} |
|
DELETE[host]/api/v2/withdrawals/methods/{methodId} |
GET[host]/api/v2/withdrawals/methods/{methodId}/commissions |
|
GET[host]/api/v2/withdrawals/methods/{methodId}/commissions/{commissionId} |
|
POST[host]/api/v2/withdrawals/methods/{methodId}/commissions |
|
PUT[host]/api/v2/withdrawals/methods/{methodId}/commissions/{commissionId} PATCH[host]/api/v2/withdrawals/methods/{methodId}/commissions/{commissionId} |
|
DELETE[host]/api/v2/withdrawals/methods/{methodId}/commissions/{commissionId} |
GET[host]/api/v2/withdrawals/methods/{methodId}/currencies |
|
GET[host]/api/v2/withdrawals/methods/{methodId}/currencies/{currencyId} |
|
POST[host]/api/v2/withdrawals/methods/{methodId}/currencies |
|
PUT[host]/api/v2/withdrawals/methods/{methodId}/currencies/{currencyId} PATCH[host]/api/v2/withdrawals/methods/{methodId}/currencies/{currencyId} |
|
DELETE[host]/api/v2/withdrawals/methods/{methodId}/currencies/{currencyId} |
Use the following methods to manage the attributes added to the Constructor withdrawal method.
GET[host]/api/v2/withdrawals/methods/{methodId}/attributes |
|
GET[host]/api/v2/withdrawals/methods/{methodId}/attributes/{attributeId} |
|
POST[host]/api/v2/withdrawals/methods/{methodId}/attributes |
|
DELETE[host]/api/v2/withdrawals/methods/{methodId}/attributes/{attributeId} |
GET[host]/api/v2/withdrawals/methods/{methodId}/restrictions |
|
GET[host]/api/v2/withdrawals/methods/{methodId}/restrictions/{restrictionId} |
|
POST[host]/api/v2/withdrawals/methods/{methodId}/restrictions |
|
PUT[host]/api/v2/withdrawals/methods/{methodId}/restrictions/{restrictionId} PATCH[host]/api/v2/withdrawals/methods/{methodId}/restrictions/{restrictionId} |
|
DELETE[host]/api/v2/withdrawals/methods/{methodId}/restrictions/{restrictionId} |
Get a list of withdrawal groups
Use this method to obtain a list of withdrawal groups configured in the Back Office.
Request
Header parameters:
Authorization: Bearer <token>
Query parameters:
The following filter parameters are available for this method:
- isEnabled
If
true
, a group is enabled; otherwise,false
.- name
The withdrawal group name used in the Back Office.
- caption
The withdrawal group name displayed to clients in the B2Core UI.
The following sorting parameter is available for this method:
- createTime
The date and time when a withdrawal group was configured.
Refer to the Query parameters section in the API Overview for details on applying filter and sorting parameters.
GET[host]/api/v2/withdrawals/groups
curl --location -g --request GET 'https://host.name/api/v2/withdrawals/groups?limit=10&offset=0&sort_order=desc&filter[isEnabled]=1&filter[name]=crypto&filter[caption]=crypto id&sort_by=createTime' \
--header 'Authorization: Bearer <token>' \
--header 'accept-language: ja'
Response
A response contains an array of Withdrawal Group objects providing information about the withdrawal groups matching the request parameters.
Get withdrawal group details
Use this method to obtain detailed information about a specified withdrawal group.
Request
Header parameters:
Authorization: Bearer <token>
Path parameters:
- groupId required
The identifier of a withdrawal group.
GET[host]/api/v2/withdrawals/groups/{groupId}
curl --location --request GET 'https://host.name/api/v2/withdrawals/groups/1' \
--header 'Authorization: Bearer <token>' \
--header 'accept-language: ja'
Response
A response contains a Withdrawal Group object providing information about the specified withdrawal group.
Create a withdrawal group
Use this method to create a withdrawal group.
Request
Header parameters:
Authorization: Bearer <token>
Body:
Specify the following parameters for a new withdrawal group:
- name string
The withdrawal group name used in the Back Office.
- caption string
The withdrawal group name displayed to client in the B2Core UI.
- isEnabled boolean
If
true
, a group is enabled; otherwise,false
.- icon string
The filename of an image that is displayed as a withdrawal group icon.
- description string
The withdrawal group description.
POST[host]/api/v2/withdrawals/groups
curl --location --request POST 'https://host.name/api/v2/withdrawals/groups' \
--header 'Authorization: Bearer <token>' \
--header 'accept-language: ja' \
--data-raw '{
"name": "crypto",
"caption": "crypto",
"isEnabled": false,
"icon": "image.png",
"description": "description"
}'
Response
A response contains a Withdrawal Group object providing information about the created withdrawal group.
Update a withdrawal group
Use this method to update a specified withdraw group.
Note
Instead of the method described below, you can use a similar method that uses the HTTP verb PATCH.
Request
Header parameters:
Authorization: Bearer <token>
Path parameters:
- groupId required
The identifier of a withdrawal group.
Body:
The following field values can be updated for a specified withdrawal group:
- name string
The withdrawal group name used in the Back Office.
- caption string
The withdrawal group name displayed to client in the B2Core UI.
- isEnabled boolean
If
true
, a group is enabled; otherwise,false
.- icon string
The filename of an image that is displayed as a withdrawal group icon.
- description string
The withdrawal group description.
- priority integer
The priority index assigned to a withdrawal group.
PUT[host]/api/v2/withdrawals/groups/{groupId}
curl --location --request PATCH 'https://host.name/api/v2/withdrawals/groups/1' \
--header 'Authorization: Bearer <token>' \
--header 'accept-language: ja' \
--data-raw '{
"name": "crypto",
"caption": "crypto",
"isEnabled": false,
"icon": "image.png",
"description": "description",
"priority": 1
}'
Response
A response contains a Withdrawal Group object providing information about the withdrawal group that was updated.
Delete a withdrawal group
Use this method to delete a specified withdrawal group.
Request
Header parameters:
Authorization: Bearer <token>
Path parameters:
- groupId required
The identifier of a withdrawal group.
DELETE[host]/api/v2/withdrawals/groups/{groupId}
curl --location --request DELETE 'https://host.name/api/v2/withdrawals/groups/1' \
--header 'Authorization: Bearer <token>'
Response
In case of success, no response body is returned.
Get a list of withdrawal methods
Use this method to obtain a list of withdrawal methods configured in the Back Office.
Request
Header parameters:
Authorization: Bearer <token>
Query parameters:
The following filter parameters are available for this method:
- isEnabled
If
true
, a method is enabled; otherwise,false
.- name
The withdrawal method name used in the Back Office.
- groupId
The identifier of a group in which a withdrawal method is included.
- provider
The name of a payment system used to make withdrawals.
- currencyNumericCode
The numeric code of a currency that is added to a withdrawal method.
The following sorting parameter is available for this method:
- createTime
The date and time when a withdrawal method was configured.
Refer to the Query parameters section in the API Overview for details on applying filter and sorting parameters.
GET[host]/api/v2/withdrawals/methods
curl --location -g --request GET 'https://host.name/api/v2/withdrawals/methods?limit=10&offset=0&sort_order=desc&filter[isEnabled]=1&filter[name]=B2BinPay&filter[groupId]=1&filter[provider]=B2BinPay&filter[currencyNumericCode]=840&sort_by=createTime' \
--header 'Authorization: Bearer <token>' \
--header 'accept-language: ja'
Response
A response contains an array of Withdrawal Method objects providing information about the withdrawal methods matching the request parameters.
Get withdrawal method details
Use this method to obtain detailed information about a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <token>
Path parameters:
- methodId required
The identifier of a withdrawal method.
GET[host]/api/v2/withdrawals/methods/{methodId}
curl --location --request GET 'https://host.name/api/v2/withdrawals/methods/1' \
--header 'Authorization: Bearer <token>' \
--header 'accept-language: ja'
Response
A response contains a Withdrawal Method object providing information about the specified withdrawal method.
Create a withdrawal method
Use this method to create a withdrawal method.
Request
Header parameters:
Authorization: Bearer <token>
Body:
Specify the following parameters for a new withdrawal method:
- name string
The withdrawal method name used in the Back Office.
- provider string
The name of a payment system used to make withdrawals.
- caption string
The withdrawal method name displayed to clients in the B2Core UI.
- connectionId string
The identifier of an external connection configured for accessing a payment provider.
- groupIds array
The identifier of a group in which a withdrawal method is included.
- isEnabled boolean
If
true
, a method is enabled; otherwise,false
.- timeToFundKey string
A hint displayed to clients in the B2Core UI about the period during which a withdrawal transaction is processed.
- precalculate boolean
If
true
, the commission amount charged for withdrawing funds is calculated and displayed to a client in the B2Core UI; otherwise,false
.- icon string
The filename of an image that is displayed as a withdrawal method icon.
- priority integer
The priority index assigned to a withdrawal method.
- ipWhiteList string
The list of allowed IP addresses.
- ratesProvider string
The name of an exchange rate provider associated with a withdrawal method.
- providerOptions object
The settings specific to a payment provider used to make withdrawals.
- resources object
An array of resource objects, specifying localized strings for user interface pages displayed to a client.
POST[host]/api/v2/withdrawals/methods
curl --location --request POST 'https://host.name/api/v2/withdrawals/methods' \
--header 'Authorization: Bearer <token>' \
--header 'accept-language: ja' \
--data-raw '{
"name": "B2BinPay",
"provider": "B2BinPay",
"caption": "B2BinPay",
"connectionId": 1,
"groupIds": [
1,
2
],
"isEnabled": true,
"timeToFundKey": "Depending on the blockchain",
"precalculate": true,
"icon": "image.png",
"priority": 1,
"ipWhiteList": "",
"ratesProvider": "B2BinPay2",
"providerOptions": {},
"resources": [
{
"key": "caption",
"locale": "en_US",
"value": "Bitcoin"
},
{
"key": "caption",
"locale": "ja_JP",
"value": "ビットコイン"
}
]
}'
Response
A response contains a Withdrawal Method object providing information about the created withdrawal method.
Update a withdrawal method
Use this method to update a specified withdraw method.
Note
Instead of the method described below, you can use a similar method that uses the HTTP verb PATCH.
Request
Header parameters:
Authorization: Bearer <token>
Content-Type: application/json
Path parameters:
- methodId required
The identifier of a withdrawal method.
Body:
The following field values can be updated for a withdrawal method:
- name string
The withdrawal method name used in the Back Office.
- caption string
The withdrawal method name displayed to clients in the B2Core UI.
- connectionId string
The identifier of an external connection configured for accessing a payment provider.
- groupId array
The identifier of a group in which a withdrawal method is included.
- isEnabled boolean
If
true
, a method is enabled; otherwise,false
.- timeToFundKey string
A hint displayed to clients in the B2Core UI about the period during which a withdrawal transaction is processed.
- precalculate boolean
If
true
, the commission amount charged for withdrawing funds is calculated and displayed to a client in the B2Core UI; otherwise,false
.- icon string
The filename of an image that is displayed as a withdrawal method icon.
- priority integer
The priority index assigned to a withdrawal method.
- ipWhiteList string
The list of allowed IP addresses.
- ratesProvider string
The name of an exchange rate provider associated with a withdrawal method.
- providerOptions object
The settings specific to a payment provider used to make withdrawals.
- resources object
An array of resource objects, specifying localized strings for user interface pages displayed to a client.
PUT[host]/api/v2/withdrawals/methods/{methodId}
curl --location --request PATCH 'https://host.name/api/v2/withdrawals/methods/1' \
--header 'Authorization: Bearer <token>' \
--header 'accept-language: ja' \
--data-raw '{
"name": "B2BinPay",
"caption": "B2BinPay",
"groupIds": [
1,
1
],
"isEnabled": true,
"timeToFundKey": "Depending on the blockchain",
"precalculate": false,
"icon": "image.png",
"priority": 1,
"ipWhiteList": "IP White List",
"ratesProvider": "B2BinPay2",
"providerOptions": {},
"resources": [
{
"key": "caption",
"locale": "ru_RU",
"value": "Lorem"
},
{
"key": "caption",
"locale": "ja_JP",
"value": "ビットコイン"
}
]
}'
Response
A response contains a Withdrawal Method object providing information about the withdrawal method that was updated.
Delete a withdrawal method
Use this method to delete a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <token>
Path parameters:
- methodId required
The identifier of a withdrawal method.
DELETE[host]/api/v2/withdrawals/methods/{methodId}
curl --location --request DELETE 'https://host.name/api/v2/withdrawals/methods/1' \
--header 'Authorization: Bearer <token>'
Response
In case of success, no response body is returned.
Get a list of withdrawal commissions
Use this method to obtain a list of commissions configured for a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <access_token>
Query parameters:
The following filter parameters are available for this method:
- recipientType
Indicates whether a commission is charged by a broker or payment system. Possible values:
vendor
— a commission is charged by a brokerprovider
— a commission is charged by a payment system
- currencyNumericCode
The numeric code of a currency in which a commission is charged.
The following sorting parameter is available for this method:
- createTime
The date and time when a withdrawal commission was configured.
Refer to the Query parameters section in the API Overview for details on applying filter and sorting parameters.
Path parameters
- methodId required
The identifier of a withdrawal method.
GET[host]/api/v2/withdrawals/methods/{methodId}/commissions
curl --location -g --request GET 'https://host.name/api/v2/withdrawals/methods/1/commissions?limit=10&offset=0&sort_order=desc&filter[recipientType]=vendor&filter[currencyNumericCode]=840&sort_by=createTime' \
--header 'Authorization: Bearer <token>'
Response
A response contains an array of Withdrawal Commission objects providing information about the commissions matching the request parameters.
Get withdrawal commission details
Use this method to obtain detailed information about a specified commission configured for a withdrawal method.
Request
Path parameters:
- methodId required
The identifier of a withdrawal method.
- commissionId required
The commission identifier.
GET[host]/api/v2/withdrawals/methods/{methodId}/commissions/{commissionId}
curl --location --request GET 'https://host.name/api/v2/withdrawals/methods/1/commissions/1' \
--header 'Authorization: Bearer <token>'
Response
A response contains a Withdrawal Commission object providing information about a specified commission.
Add a withdrawal commission
Use this method to configure a new commission for a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <token>
Body:
Specify the following parameters when adding a withdrawal commission:
- currencyNumericCode integer required
The numeric code of a currency in which a commission is charged.
- type string required
The commission type.
- recipientType string required
Indicates whether a commission is charged by a broker or payment system. Possible values:
vendor
— a commission is charged by a brokerprovider
— a commission is charged by a payment system
- percent string
The percentage of a withdrawal amount charged as a commission.
- fix string
The fixed commission amount.
- min string
The minimum commission amount.
- max string
The maximum commission amount.
POST[host]/api/v2/withdrawals/methods/{methodId}/commissions
curl --location --request POST 'https://host.name/api/v2/withdrawals/methods/1/commissions' \
--header 'Authorization: Bearer <token>' \
--data-raw '{
"currencyNumericCode": 840,
"type": "default",
"recipientType": "vendor",
"percent": "5.00",
"fix": "10.00",
"min": "15.00",
"max": "20.00"
}'
Response
A response body includes a Withdrawal Commission object providing information about a commission configured for a withdrawal method.
Update a withdrawal commission
Use this method to update a specified commission configuration for a withdrawal method.
Note
Instead of the method described below, you can use a similar method that uses the HTTP verb PATCH.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters:
- methodId required
The identifier of a withdrawal method.
- commissionId required
The commission identifier.
Body:
The following field values can be updated for a withdrawal method commission:
- type string
The commission type.
- recipientType string
Indicates whether a commission is charged by a broker or payment system. Possible values:
vendor
— a commission is charged by a brokerprovider
— a commission is charged by a payment system
- percent string
The percentage of a withdrawal amount charged as a commission.
- fix string
The fixed amount of commission.
- min string
The minimum commission amount.
- max string
The maximum commission amount.
PUT[host]/api/v2/withdrawals/methods/{methodId}/commissions/{commissionId}
curl --location --request PATCH 'https://host.name/api/v2/withdrawals/methods/1/commissions/1' \
--header 'Authorization: Bearer <token>' \
--data-raw '{
"type": "default",
"recipientType": "vendor",
"percent": "5.00",
"fix": "10.00",
"min": "15.00",
"max": "20.00"
}'
Response
A response includes a Withdrawal Commission object providing information about the commission that was updated.
Delete a withdrawal commission
Use this method to delete a commission that was previously configured for a withdrawal method.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters:
- methodId required
The identifier of a withdrawal method.
- commissionId required
The commission identifier.
DELETE[host]/api/v2/withdrawals/methods/{methodId}/commissions/{commissionId}
curl --location --request DELETE 'https://host.name/api/v2/withdrawals/methods/1/commissions/1' \
--header 'Authorization: Bearer <token>'
Response
In case of success, no response body is returned.
Get a list of withdrawal currencies
Use this method to obtain a list of currencies added to a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <access_token>
Query parameters:
The following filter parameters are available for this method:
- isEnabled
If
true
, a currency is enabled for a withdrawal method; otherwisefalse
.- type
The type of a currency added to a withdrawal method. Possible values:
tradersRoom
— transaction currenciespaymentSystem
— payment currencies
- currencyNumericCode
The numeric code of a currency (such as
1000
).
The following sorting parameter is available for this method:
- createTime
The date and time when a currency was added to a withdrawal method.
Refer to the Query parameters section in the API Overview for details on applying filter and sorting parameters.
Path parameters
- methodId required
The identifier of a withdrawal method.
GET[host]/api/v2/withdrawals/methods/{methodId}/currencies
curl --location -g --request GET 'https://host.name/api/v2/withdrawals/methods/1/currencies?sort_order=desc&limit=10&offset=0&filter[isEnabled]=1&filter[type]=tradersRoom&filter[currencyNumericCode]=1000&sort_by=createTime' \
--header 'Authorization: Bearer <token>'
Response
A response contains an array of Withdrawal Currency objects providing information about the currencies matching the request parameters.
Get withdrawal currency details
Use this method to obtain detailed information about a specified currency added to a withdrawal method.
Request
Path parameters:
- methodId required
The identifier of a withdrawal method.
- currencyId required
The identifier of a withdrawal currency.
GET[host]/api/v2/withdrawals/methods/{methodId}/currencies/{currencyId}
curl --location --request GET 'https://host.name/api/v2/withdrawals/methods/1/currencies/1' \
--header 'Authorization: Bearer <token>'
Response
A response contains a Withdrawal Currency object providing information about a specified currency added to a withdrawal method.
Add a withdrawal currency
Use this method to add a currency to a withdrawal method.
Request
Header parameters:
Authorization: Bearer <token>
Path parameters:
- methodId required
The identifier of a withdrawal method.
Body:
Specify the following parameters when adding a currency:
- type string required
The currency type. Possible values:
tradersRoom
— a currency is added as a transaction currencypaymentSystem
— a currency is added as a payment currency
- currencyNumericCode integer required
The numeric code of a currency (such as
1000
).- isEnabled boolean required
If
true
, a currency is enabled for a withdrawal method; otherwise,false
.- min string
The minimum amount that can be withdrawn in a currency.
- max string
The maximum amount that can be withdrawn in a currency.
- blockExporter string
Applicable only for cryptocurrencies.
The cryptocurrency block explorer.
- blockchainCode integer
Applicable only for cryptocurrencies.
The currency code in a blockchain.
POST[host]/api/v2/withdrawals/methods/{methodId}/currencies
curl --location --request POST 'https://host.name/api/v2/withdrawals/methods/1/currencies' \
--header 'Authorization: Bearer <token>' \
--data-raw '{
"type": "tradersRoom",
"currencyNumericCode": 1000,
"isEnabled": true,
"min": "0.01",
"max": "2.00",
"blockExporter": "Test",
"blockchainCode": 123
}'
Response
A response body includes a Withdrawal Currency object providing information about the added currency.
Update a withdrawal currency
Use this method to update a specified currency added to a withdrawal method.
Note
Instead of the method described below, you can use a similar method that uses the HTTP verb PATCH.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters:
- methodId required
The identifier of a withdrawal method.
- currencyId required
The identifier of a withdrawal currency.
Body:
The following field values can be updated for a withdrawal currency:
- isEnabled boolean
If
true
, a currency is enabled for a withdrawal method; otherwise,false
.- min string
The minimum amount that can be withdrawn in a currency.
- max string
The maximum amount that can be withdrawn in a currency.
- blockExporter string
Applicable only for cryptocurrencies.
The cryptocurrency block explorer.
- blockchainCode integer
Applicable only for cryptocurrencies.
The currency code in a blockchain.
PUT[host]/api/v2/withdrawals/methods/{methodId}/currencies/{currencyId}
curl --location --request PATCH 'https://host.name/api/v2/withdrawals/methods/1/currencies/1' \
--header 'Authorization: Bearer <token>' \
--data-raw '{
"isEnabled": true,
"min": "1.00",
"max": "2.00",
"blockExporter": "Test",
"blockchainCode": 123
}'
Response
A response includes a Withdrawal Currency object providing information about the currency that was updated.
Delete a withdrawal currency
Use this method to delete a currency that was previously added to a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters
- methodId required
The identifier of a withdrawal method.
- currencyId required
The identifier of a withdrawal currency that you want to delete.
DELETE[host]/api/v2/withdrawals/methods/{methodId}/currencies/{currencyId}
curl --location --request DELETE 'https://host.name/api/v2/withdrawals/methods/1/currencies/-46668202' \
--header 'Authorization: Bearer <token>'
Response
In case of success, no response body is returned.
Get a list of withdrawal method attributes
Use this method to obtain a list of attributes added to a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters
- methodId required
The identifier of a withdrawal method.
GET[host]/api/v2/withdrawals/methods/{methodId}/attributes
curl --location -g 'https://host.name/api/v2/withdrawals/methods/1/attributes' \
--header 'Authorization: Bearer <token>' \
Response
A response contains an array of Withdrawal Method Attribute objects providing information about the attributes matching the request parameters.
Get withdrawal method attribute details
Use this method to obtain detailed information about a specified attribute added to a withdrawal method.
Request
Path parameters:
- methodId required
The identifier of a withdrawal method.
- attributeId required
The identifier of a withdrawal method attribute.
GET[host]/api/v2/withdrawals/methods/{methodId}/attributes/{attributeId}
curl --location 'https://host.name/api/v2/withdrawals/methods/1/attributes/1' \
--header 'Authorization: Bearer <token>' \
Response
A response contains a Withdrawal Method Attribute object providing information about a specified attribute added to a withdrawal method.
Add a withdrawal method attribute
Use this method to add an attribute to a withdrawal method.
Request
Header parameters:
Authorization: Bearer <token>
Path parameters:
- methodId required
The identifier of a withdrawal method.
Body:
Specify the following parameters when adding an attribute:
- caption string required
The attribute name displayed to clients in the B2Core UI.
- type string required
The attribute type. Possible values:
selectAutocomplete
input
POST[host]/api/v2/withdrawals/methods/{methodId}/attributes
curl --location 'https://host.name/api/v2/withdrawals/methods/1/attributes' \
--header 'Authorization: Bearer <token>' \
--data-raw '{
"caption": "<string>",
"type": "selectAutocomplete"
}'
Response
A response body includes a Withdrawal Method Attribute object providing information about the added attribute.
Delete a withdrawal method attribute
Use this method to delete an attribute that was previously added to a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters
- methodId required
The identifier of a withdrawal method.
- attributeId required
The identifier of a withdrawal method attribute that you want to delete.
DELETE[host]/api/v2/withdrawals/methods/{methodId}/attributes/{attributeId}
curl --location --request DELETE 'https://host.name/api/v2/withdrawals/methods/1/attributes/1' \
--header 'Authorization: Bearer <token>'
Response
In case of success, no response body is returned.
Get a list of withdrawal method restrictions
Use this method to obtain a list of restrictions added for a specified withdrawal method.
Use a separate method to get withdrawal method restriction details.
Request
Header parameters:
Authorization: Bearer <token>
Path parameters:
- methodId required
The withdrawal method identifier.
Query parameters:
The following filter parameter is available for this method:
- name string
The withdrawal method restriction name. Possible values:
country
— allows or forbids the use of a withdrawal method for specified countries.client_type
— allows or forbids the use of a withdrawal method for specified client types.verification_level_restriction
— allows or forbids the use of a withdrawal method for specified client verification levels.
GET[host]/api/v2/withdrawals/{methodId}/restrictions
curl --location -g --request GET 'https://host.name/api/v2/withdrawals/methods/1/restrictions?limit=10&offset=0&sort_order=desc&filter[name]=name' \
--header 'Authorization: Bearer <token>' \
Response
A response includes an array of Withdrawal Method Restriction objects providing information about the withdrawal method restrictions matching the request parameters.
Get withdrawal method restriction details
Use this method to obtain detailed information about a specified withdrawal method restriction.
Use a separate method to get a list of withdrawal method restrictions.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters:
- methodId integer required
The withdrawal method identifier.
- restrictionId integer required
The identifier of a withdrawal method restriction.
GET[host]/api/v2/withdrawals/{methodId}/restrictions/{restrictionId}
curl --location --request GET 'https://host.name/api/v2/withdrawals/methods/1/restrictions/1' \
--header 'Authorization: Bearer <token>' \
Response
A response contains a Withdrawal Method Restriction object providing information about the specified withdrawal method restriction.
Add a withdrawal method restriction
Use this method to add a new restriction for a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters:
- methodId required
The identifier of a withdrawal method for which a restriction is to be added.
Body:
Specify the following parameters when adding a new withdrawal method restriction:
- name string required
The withdrawal method restriction name. Possible values:
country
- allows or forbids the use of a deposit method for specified countries.client_type
- allows or forbids the use of a deposit method for specified client types.verification_level_restriction
- allows or forbids the use of a deposit method for specified client verification levels.
- isEnabled boolean required
If
true
, a restriction is enabled for a withdrawal method; otherwise,false
.- type string required
A string value specifying the type of a withdrawal method restriction. Possible values:
allow
deny
- ids array
An array of string values identifying the countries, client types or client verification levels to which a restriction applies.
POST[host]/api/v2/withdrawals/{methodId}/restrictions
curl --location --request POST 'https://host.name/api/v2/withdrawals/methods/1/restrictions' \
--header 'Authorization: Bearer <token>' \
--data-raw '{
"name": "withdrawal_restriction",
"isEnabled": true,
"type": "allow",
"ids": [
"22",
"3"
]
}'
Response
A response includes a Withdrawal Method Restriction object providing information about the added withdrawal method restriction.
Update a withdrawal method restriction
Use this method to update a specified withdrawal method restriction.
Note
Instead of the method described below, you can use a similar method that uses the HTTP verb PATCH.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters:
- methodId required
The identifier of a withdrawal method for which a restriction is to be updated.
- restrictionId required
The identifier of a withdrawal method restriction to be updated.
Body:
Specify the following parameters when updating a withdrawal method restriction:
- isEnabled boolean
If
true
, a restriction is enabled for a withdrawal method; otherwise,false
.- type string
A string value specifying the type of a withdrawal method restriction. Possible values:
allow
deny
- ids array
An array of string values identifying the countries, client types or client verification levels to which a restriction applies.
PUT[host]/api/v2/withdrawals/{methodId}/restrictions/{restrictionId}
curl --location --request PATCH 'https://host.name/api/v2/withdrawals/methods/1/restrictions/1' \
--header 'Authorization: Bearer <token>' \
--data-raw '{
"isEnabled": true,
"type": "deny",
"ids": [
"22",
"3"
]
}'
Response
A response includes a Withdrawal Method Restriction object providing information about the withdrawal method restriction that was updated.
Delete a withdrawal method restriction
Use this method to remove a restriction for a specified withdrawal method.
Request
Header parameters:
Authorization: Bearer <access_token>
Path parameters:
- methodId required
The withdrawal method identifier.
- restrictionId required
The identifier of a withdrawal method restriction to be removed.
DELETE[host]/api/v2/withdrawals/{methodId}/restrictions/{restrictionId}
curl --location --request DELETE 'https://host.name/api/v2/withdrawals/methods/1/restrictions/1' \
--header 'Authorization: Bearer <token>'
Response
In case of success, no response body is returned.