{ "opencollection": "1.0.0", "info": { "name": "Addresses Introduction Account Addresses Promotions Standard API", "version": "25.1126.6886238" }, "request": { "auth": { "type": "bearer", "token": "{{bearerToken}}" } }, "items": [ { "info": { "name": "Promotions Standard", "type": "folder" }, "items": [ { "info": { "name": "Get all Promotions", "type": "http" }, "http": { "method": "GET", "url": "https://useast.api.elasticpath.com/v2/promotions", "headers": [ { "name": "Authorization", "value": "" } ], "params": [ { "name": "page[offset]", "value": "", "type": "query", "description": "The number of records to offset the results by." }, { "name": "page[limit]", "value": "", "type": "query", "description": "The number of records per page." } ] }, "docs": "Returns all promotions.\n\n:::note\n\nYou can use pagination with this resource. For more information, see [pagination](/guides/Getting-Started/pagination).\n\n:::\n\n### Filtering\n\nThe following operators and attributes are available when filtering on this endpoint. See [Supported Filtering Characters](https://elasticpath.dev/guides/Getting-Started/filtering#supported-characters).\n\nUse `code` filter to search codes within promotions.\n\n| Attribute | Type | Operator | Example " }, { "info": { "name": "Create a Promotion", "type": "http" }, "http": { "method": "POST", "url": "https://useast.api.elasticpath.com/v2/promotions", "headers": [ { "name": "Authorization", "value": "" } ], "body": { "type": "json", "data": "{}" } }, "docs": "You can use this endpoint to create the following types of promotion:\n - Cart Fixed Discount Promotion\n - Cart Percent Discount Promotion\n - X for Y Discount Promotion\n - X for Amount Discount Promotion\n - Fixed Bundle Discount Promotion\n - Item Fixed Discount Promotion\n - Item Percent Discount Promotion\n - Free Gift Promotion\n\n### The `schema` object\n\nPromotions are defined by schemas that are used internally to verify promotions and calculate discounts. You must define a schema when you create" }, { "info": { "name": "Get a Promotion", "type": "http" }, "http": { "method": "GET", "url": "https://useast.api.elasticpath.com/v2/promotions/:promotionID", "headers": [ { "name": "Authorization", "value": "" } ], "params": [ { "name": "promotionID", "value": "", "type": "path", "description": "The ID of the promotion." } ] }, "docs": "Retrieves a promotion." }, { "info": { "name": "Update a Promotion", "type": "http" }, "http": { "method": "PUT", "url": "https://useast.api.elasticpath.com/v2/promotions/:promotionID", "headers": [ { "name": "Authorization", "value": "" } ], "params": [ { "name": "promotionID", "value": "", "type": "path", "description": "The unique promotion identifier." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Use this endpoint to update a specific promotion.\n\n:::note\n\n You can re-enable an expired promotion by updating the end date to a future date. However, when you enable a promotion again, all codes previously attached to it are deleted to make sure that duplicate promotion codes do not exist on different promotions.\n\n:::\n\n### Errors\n\nWhen extending the end date of an expired promotion with over 1000 codes, you will receive the following error response. In such cases, we recommend duplicating the" }, { "info": { "name": "Delete a Promotion", "type": "http" }, "http": { "method": "DELETE", "url": "https://useast.api.elasticpath.com/v2/promotions/:promotionID", "headers": [ { "name": "Authorization", "value": "" } ], "params": [ { "name": "promotionID", "value": "", "type": "path", "description": "The ID of the promotion that you want to delete." } ] }, "docs": "Use this endpoint to delete a specific promotion." }, { "info": { "name": "Get a Promotion History", "type": "http" }, "http": { "method": "GET", "url": "https://useast.api.elasticpath.com/v2/promotions/:promotionID/history", "headers": [ { "name": "Authorization", "value": "" } ], "params": [ { "name": "promotionID", "value": "", "type": "path", "description": "The ID of the promotion." } ] }, "docs": "Use this endpoint to retrieve a promotion history." } ] } ], "bundled": true }