Show examples in:
Javascript HTTP
Endpoint info
Available examples

Content Management API > Scheduled publication

Delete a scheduled publication

Returns

Returns a resource object of type item.

Examples

1
DELETE https://site-api.datocms.com/items/:item_id/scheduled-publication HTTP/1.1
2
Authorization: Bearer YOUR-API-TOKEN
3
Accept: application/json
4
X-Api-Version: 3
Terminal window
1
curl -g 'https://site-api.datocms.com/items/:item_id/scheduled-publication' \
2
-X DELETE \
3
-H "Authorization: Bearer YOUR-API-TOKEN" \
4
-H "Accept: application/json" \
5
-H "X-Api-Version: 3"
1
await fetch(
2
"https://site-api.datocms.com/items/:item_id/scheduled-publication",
3
{
4
method: "DELETE",
5
headers: {
6
Authorization: "Bearer YOUR-API-TOKEN",
7
Accept: "application/json",
8
"X-Api-Version": "3",
9
},
10
},
11
);
1
HTTP/1.1 200 OK
2
Content-Type: application/json
3
Cache-Control: cache-control: max-age=0, private, must-revalidate
4
X-RateLimit-Limit: 30
5
X-RateLimit-Remaining: 28
6
7
{
8
"data": {
9
"type": "item",
10
"id": "hWl-mnkWRYmMCSTq4z_piQ",
11
"relationships": {
12
"item_type": {
13
"data": {
14
"type": "item_type",
15
"id": "DxMaW10UQiCmZcuuA-IkkA"
16
}
17
}
18
},
19
"attributes": {
20
"title": "My first blog post!",
21
"content": "Lorem ipsum dolor sit amet...",
22
"category": "24",
23
"image": {
24
"alt": "Alt text",
25
"title": "Image title",
26
"custom_data": {},
27
"focal_point": null,
28
"upload_id": "20042921"
29
}
30
},
31
"meta": {
32
"created_at": "2020-04-21T07:57:11.124Z",
33
"updated_at": "2020-04-21T07:57:11.124Z",
34
"published_at": "2020-04-21T07:57:11.124Z",
35
"first_published_at": "2020-04-21T07:57:11.124Z",
36
"publication_scheduled_at": "2020-04-21T07:57:11.124Z",
37
"unpublishing_scheduled_at": "2020-04-21T07:57:11.124Z",
38
"status": "published",
39
"is_current_version_valid": true,
40
"is_published_version_valid": true,
41
"current_version": "4234",
42
"stage": null
43
}
44
}
45
}