All pages
Powered by GitBook
1 of 1

Loading...

Create currency account

Use case

In this example we will review how to open a currency account with the minimal set of date.

Use case data
API parameters with values

Currency account type

The name of the account holder is Trevor Harry Tuum

Trevor is assigned to the GROUP_A customer group.

The standard price list is assigned to the account

Trevor's residency country is the Great Britain

The account currency code is GBP

Sample API call

To create an account for a person, make the following API call.

Sample request

Below is an example request body of the API call for creating an account.

{
  "accountTypeCode": "CURRENCY",
  "personName": "Trevor Harry Tuum",
  "customerGroupCode": "GROUP_A",
  "priceListTypeCode": "STANDARD",
  "residencyCountryCode": "GB",
  "currencyCode": "GBP"
}
curl -L 'https://account-api.sandbox.tuumplatform.com/api/v4/persons/ID-3392/accounts' \
-H 'x-channel-code: system' \
-H 'x-auth-token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHBpcnlEVGltZSI6IjIwMjMtMDYtMTlUMTg6NDI6MjIiLCJyb2xlcyI6WyJBRE1JTiJdLCJuYW1lIjoiSm9obiBPZmZpY2VyIiwiZW1wbG95ZWVJZCI6IjEiLCJ0ZW5hbnRDb2RlIjoiTUIiLCJleHAiOjE2ODcyMDAxNDJ9.ug4KhUwVSEuRx0VcbBUMc2Emf_RJw-nde3aHdKFbHkY' \
-H 'Content-Type: application/json' \
-d '{
  "accountTypeCode": "CURRENCY",
  "personName": "Trevor Harry Tuum",
  "customerGroupCode": "GROUP_A",
  "priceListTypeCode": "STANDARD",
  "residencyCountryCode": "GB",
  "currencyCode": "GBP"
}'

Sample response

Below you find an example response body to the API call above.

Response
{
    "errors": null,
    "validationErrors": null,
    "data": {
        "accountId": "ID-1279",
        "personId": "ID-3392",
        "accountTypeCode": "CURRENCY",
        "activationDate": "2023-06-19",
        "accountName": null,
        "personName": "Trevor Harry Tuum",
        "statusCode": "ACTIVE",
        "iban": "GB72XXXX04030000000986",
        "bic": "LHVBGB2LXXX",
        "defaultCurrencyCode": "GBP",
        "tenantCode": "MB",
        "residencyCode": "GB",
        "customerGroupCode": "GROUP_A",
        "personTypeCode": null,
        "intraOrgCode": null,
        "accountTypeSetupCode": "STANDARD",
        "serviceProviderCode": "TUUM",
        "interestMethodAssignmentCode": null,
        "accountClassCode": null,
        "balances": [
            {
                "balanceId": "ID-1206",
                "accountId": "ID-1279",
                "currencyCode": "GBP",
                "balanceAmount": 0.00,
                "reservedAmount": 0.00,
                "overdraftLimitAmount": 0.00,
                "defaultCurrencyCode": "GBP",
                "availableBalanceInDefaultCcy": 0.00,
                "negativeBalanceStartDate": null,
                "availableBalanceAmount": 0.00
            }
        ],
        "masterAccountId": null,
        "accountNumbers": [
            {
                "accountNumber": {
                    "value": "00000986",
                    "type": "BBAN"
                },
                "countryCode": "GB",
                "financialInstitutionId": {
                    "value": "040300",
                    "type": "SORT_CODE"
                },
                "defaultCurrencyCode": "GBP",
                "accountNumberId": "ID-1143",
                "accountId": "ID-1279",
                "financialInstitutionIdTypeCode": null,
                "statusCode": "ENABLED"
            }
        ],
        "taxResidencyCountryCode": "GB",
        "jurisdictionCountryCode": "GB"
    }
}

Result

The outcome of the API call is the complete set of account data. Including the parameters generated by the Tuum system:

Parameter and value
Explanation

A unique identifier is assigned to the new account.

The new account is created and activated.

The IBAN assigned to the new account.

The BIC assigned to the new account.

https://account-api.sandbox.tuumplatform.com/api/v4/persons/{personId}/accounts

See more about the endpoint in the Tuum developer portal.

"accountTypeCode": "CURRENCY"
"personName": "Trevor Harry Tuum"
"customerGroupCode": "GROUP_A"
"priceListTypeCode": "STANDARD"
"residencyCountryCode": "GB"
"currencyCode": "GBP"
"accountId": "ID-1279"
"statusCode": "ACTIVE"
"iban": "GB72XXXX04030000000986"
"bic": "LHVBGB2LXXX"
create account