Create Sequence Policy (POST)
Create a sequence policy to configure a unique, sequential number for posted invoices or credit memos.
A sequence policy ensures unique identification and systematic tracking of financial transactions, supporting regulatory compliance and preventing fraud. You can create a sequence policy for invoices or credit memos only.
You need the Billing Admin permission set to use this API.
65.0
POST
JSON Example
This example shows a sample request to create a sequence policy.
Properties
| Name | Type | Description | Required or Optional | Available Version |
|---|---|---|---|---|
dateStampFormat | String | Format of the stamp date that’s appended to the sequence number. You can’t edit this property by using the Update Sequence Policy API. | Required | 65.0 |
description | String | Additional details about the sequence policy. | Optional | 65.0 |
effectiveFromDateTime | String | Date and time when the policy becomes effective. The default value is the current date. | Required | 65.0 |
expirationDateTime | String | Date and time when the policy expires. | Optional | 65.0 |
filterCriteria | String | Criteria to filter the target objects. | Required | 65.0 |
incrementNumber | Integer | Value by which the sequence number increases until it reaches the maximum number. This value must be greater than or equal to 1. The default value is 1. You can’t edit this property by using the Update Sequence Policy API. | Required | 65.0 |
isActive | Boolean | Indicates whether the policy is active (true) or not (false). The default value is false. | Required | 65.0 |
maximumSequenceNumber | Integer | Maximum number the sequence number can reach. | Optional | 65.0 |
minimumSequenceNumberWidth | Integer | Minimum number of digits a sequence number must have. You can’t edit this property by using the Update Sequence Policy API. | Optional | 65.0 |
name | String | Name of the sequence policy. | Required | 65.0 |
selectionCondition | Selection Condition Input[] | Criteria to determine which sequence policy is applied to a record. This property includes conditions based on any standard or custom fields of the record. | Optional | 65.0 |
selectionLogic | String | Logic that determines the objects that the sequence policy applies to. | Optional | 65.0 |
sequenceMode | String | Specifies how sequence numbers are generated. Valid values are Basic—Assigns sequential numbers without gap reconciliation; or Gapless—Assigns sequential numbers with gap reconciliation. The usage of this value ensures that the posted invoices or credit memos don’t have any numbering gaps for audits and compliance. You can’t edit this property by using the Update Sequence Policy API. | Required | 65.0 |
sequencePattern | String | Pattern structure that’s followed for the sequence. | Required | 65.0 |
sequenceStartNumber | Integer | Starting value of the sequence number, which must be greater than or equal to 0. The default value is 1. You can’t edit this property by using the Update Sequence Policy API. | Required | 65.0 |
targetObject | String | Object that the policy is applied to. Valid values are Invoice; or CreditMemo—Available in API version 66.0 and later. You can’t edit this property by using the Update Sequence Policy API. | Required | 65.0 |
timeZone | String | Time zone that’s applicable for the sequence policy. | Optional | 65.0 |