Bulk Import of Promo Code Pools
Method Description
Invoked with a POST request. Request address is set up via Maestra framework.
POST https://api.maestra.io/v3/operations/bulk?endpointId={API endpoint ID}&operation=DirectCrm.PromoCodeTypes.Import&csvCodePage=65001&folderSystemName={internal folder name}
HTTP/1.1
Authorization: SecretKey {Secret Key}
Accept: application/xml
Content-Type: text/csv
- csvCodePage: Windows codepage ID for CSV file. 65001 (UTF-8) is preferred.
- csvColumnDelimiter: Column delimiter symbol in CSV file.
- folderSystemName: Internal name of the folder, where the promo codes are added
- csvTextQualifier: Optional start/end character in column value, masking otherwise invalid characters.
- Authorization key: The value is obtained via Maestra.
- The service allows up to 60 imports per hour. When this limit is exceeded, you’ll receive 429 Too Many Requests until the ratio of tasks queued/hour drops below 60.
Field Descriptions
Title | Description |
---|---|
ExternalId | Promo code pool ID |
Name | Promo code pool name |
IssueStartDateTimeUtc | Promo code pool issuance start date in UTC+0. |
IssueEndDateTimeUtc | Promo code pool issuance end date in UTC+0. |
Sample Request
POST https://api.maestra.io/v3/operations/bulk?endpointId=Maestra&operation=DirectCrm.PromoCodeTypes.Import&csvCodePage=65001&folderSystemName=Registration
Authorization: SecretKey VRY294
Accept: application/xml
Content-Type: text/csv
ExternalId;Name;IssueStartDateTimeUtc;IssueEndDateTimeUtc
1;New promo code pool;2017-11-11 13:30:00;2017-12-11 13:30:00
Updated about 1 month ago