Here, we will create a single currency account limit type with the account scope.
The limit must be applicable on the account level.
The limit is active on a montly basis.
The limit is calculated per currency.
The that was generated in the previous call.
To create an account limit type, make the following call.
https://account-api.sandbox.tuumplatform.com/api/v1/limits/types
Below is an example request body of the API call for creating an account and setting access rights.
{
"scopeTypeCode": "ACCOUNT",
"periodTypeCode": "MONTHLY",
"calcTypeCode": "PER_CURRENCY",
"limitCode": "NEW_ACCOUNT_LIMIT"
}
curl -L 'https://account-api.sandbox.tuumplatform.com/api/v1/limits/types' \
-H 'x-channel-code: SYSTEM' \
-H 'x-auth-token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHBpcnlEVGltZSI6IjIwMjMtMDctMTFUMTU6MDA6MTUiLCJyb2xlcyI6WyJBRE1JTiJdLCJuYW1lIjoiSm9obiBPZmZpY2VyIiwiZW1wbG95ZWVJZCI6IjEiLCJ0ZW5hbnRDb2RlIjoiTUIiLCJleHAiOjE2ODkwODc2MTV9.wfWaIi2x7wg64c0UPBPBHoezz5EhajJqQp1oHD7Rm7o' \
-H 'Content-Type: application/json' \
-d '{
"scopeTypeCode": "ACCOUNT",
"periodTypeCode": "MONTHLY",
"calcTypeCode": "PER_CURRENCY",
"limitCode": "NEW_ACCOUNT_LIMIT"
}'
Below you find an example response body to the API call above.
A new single currency account limit type is created - ID-1002
. In the further API call, we will assign this limit type to an existing account and define the limit amount.
"scopeTypeCode": "ACCOUNT"
"periodTypeCode": "MONTHLY"
"calcTypeCode": "PER_CURRENCY"
"limitCode": "NEW_ACCOUNT_LIMIT"