Voucher codes
Get all voucher codes
Returns all voucher codes filtered by Voucher or other filter parameters. Note this operation uses Pagination and supports Portfolio Access Tokens.
Request
[PlatformAddress]/api/connector/v1/voucherCodes/getAll
Property | Type | Contract | Description |
---|---|---|---|
| string | required | Token identifying the client application. |
| string | required | Access token of the client application. |
| string | required | Name and version of the client application. |
| array of string | optional, max 1000 items | Unique identifiers of the Enterprises. If not specified, the operation returns data for all enterprises within scope of the Access Token. |
| array of string | optional, max 1000 items | Unique identifiers of the voucher codes. |
| array of string | optional, max 1000 items | Unique identifiers of vouchers. |
| optional, max length 3 months | Interval of Voucher code last update date and time. | |
| required | Limitation on the quantity of data returned. |
Response
Property | Type | Contract | Description |
---|---|---|---|
| array of Voucher code | optional | Information about voucher codes used by customers. |
| string | optional | Unique identifier of the item one newer in time order than the items to be returned. If Cursor is not specified, i.e. null, then the latest or most recent items will be returned. |
Voucher code
Property | Type | Contract | Description |
---|---|---|---|
| string | required | Unique identifier of the voucher code. |
| string | required | Unique identifier of Voucher the code belongs to. |
| string | required | Value of voucher code used by customers. |
| string | optional | If specified, marks the beginning of interval in which the code can be used. |
| string | optional | If specified, marks the end of interval in which the code can be used. |
| string | required | Creation date and time of the voucher in UTC timezone in ISO 8601 format. |
| string | required | Last update date and time of the voucher in UTC timezone in ISO 8601 format. |
| string Activity state | required | Whether voucher code is active or deleted. |
Add voucher codes
Adds voucher codes to the specified Vouchers. Note this operation supports Portfolio Access Tokens.
Request
[PlatformAddress]/api/connector/v1/voucherCodes/add
Property | Type | Contract | Description |
---|---|---|---|
| string | required | Token identifying the client application. |
| string | required | Access token of the client application. |
| string | required | Name and version of the client application. |
| string | optional | Unique identifier of the Enterprise. Required when using a Portfolio Access Token, ignored otherwise. |
| array of Voucher code parameters | required, max 1000 items | Voucher codes to be added. |
Voucher code parameters
Property | Type | Contract | Description |
---|---|---|---|
| string | required | Unique identifier of Voucher the code belongs to. |
| string | required, max 128 characters | Value of voucher code used by customers. |
| string | optional | If specified, marks the beginning of interval in which the code can be used. |
| string | optional | If specified, marks the end of interval in which the code can be used. |
Response
Property | Type | Contract | Description |
---|---|---|---|
| array of Voucher code | optional | Information about voucher codes used by customers. |
Delete voucher codes
Delete specified voucher codes. Note this operation supports Portfolio Access Tokens.
Request
[PlatformAddress]/api/connector/v1/voucherCodes/delete
Property | Type | Contract | Description |
---|---|---|---|
| string | required | Token identifying the client application. |
| string | required | Access token of the client application. |
| string | required | Name and version of the client application. |
| string | optional | Unique identifier of the Enterprise. Required when using a Portfolio Access Token, ignored otherwise. |
| array of string | required, max 1000 items | Unique identifiers of the voucher codes to be deleted. |
Response
Activity state
Active
- active records (the validity might be restricted by another parameter i.e. interval).Deleted
- deleted records.
Last updated