Create account type class rule

Use case

In this example, we will review how to create an account class rule.

Use case data
API parameters

Setting a new rule for the internal accounts type.

"accountTypeCode": "INTERNAL"

The account class code was generated in the previous API call.

"accountClassCode": "NEW"

The validity range of the rule. The validity range format: YYYY-MM-DD.

"validityRange": {
    "startDate": "2023-07-31"
  }

Sample API call

To create a new account type class rule, make the following API call.

https://account-api.sandbox.tuumplatform.com/api/v1/account-type-class-rules

See more about the create account type class rule endpoint in the Tuum developer portal.

Sample request

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

{
  "accountTypeCode": "INTERNAL",
  "accountClassCode": "NEW",
  "validityRange": {
    "startDate": "2023-07-31"
  }
}

Sample response

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

Response
{
    "errors": null,
    "validationErrors": null,
    "data": {
        "accountTypeCode": "INTERNAL",
        "accountClassCode": "NEW",
        "validityRange": {
            "startDate": "2023-07-31",
            "endDate": null
        },
        "accountTypeClassRuleId": "ID-1007"
    }
}

Result

A new account type class rule was created.

Last updated

Was this helpful?