Delete a Promotion
DELETEhttps://useast.api.elasticpath.com/v2/promotions/:promotionID
Use this endpoint to delete a specific promotion.
Request
Path Parameters
promotionID stringrequired
The ID of the promotion that you want to delete.
Header Parameters
Authorization Bearerrequired
The Bearer token required to get access to the API.
Responses
- 204
- 401
No Content
Unauthorized
- application/json
- Schema
- Example (auto)
- Example
Schema
detailstring
statusstring
titlestring
[
null
]
[
{
"errors": [
{
"status": 401,
"title": "Unauthorized"
}
]
}
]
Authorization: http
name: bearerAuthtype: httpscheme: bearer
- csharp
- curl
- dart
- go
- http
- java
- javascript
- kotlin
- c
- nodejs
- objective-c
- ocaml
- php
- powershell
- python
- r
- ruby
- rust
- shell
- swift
- HTTPCLIENT
- RESTSHARP
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Delete, "https://useast.api.elasticpath.com/v2/promotions/:promotionID");
request.Headers.Add("Authorization", "Bearer <token>");
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
ResponseClear