Try it out! Use the API playground on the right to test the Cancel Schedule endpoint directly.
Overview
Cancel a scheduled post to prevent it from being published. This permanently removes the scheduled post from the queue.
This action is permanent. Once cancelled, the scheduled post cannot be recovered. You’ll need to create a new schedule if you want to publish the video.
You can only cancel posts with pending status. Posts that have already been published cannot be deleted through this API - you’ll need to delete them directly on the platform.
Endpoint
DELETE /v1/schedule/{scheduleId}
Path Parameters
The unique ID of the scheduled post to cancel
Request Examples
const scheduleId = 'post_abc123xyz' ;
const response = await fetch ( `https://api.hooked.so/v1/schedule/ ${ scheduleId } ` , {
method: 'DELETE' ,
headers: {
'x-api-key' : process . env . HOOKED_API_KEY
}
});
const data = await response . json ();
if ( data . success ) {
console . log ( 'Schedule cancelled successfully' );
} else {
console . error ( 'Failed to cancel:' , data . message );
}
Bulk Cancel Example
async function cancelMultipleSchedules ( scheduleIds ) {
const results = await Promise . allSettled (
scheduleIds . map ( async ( id ) => {
const response = await fetch ( `https://api.hooked.so/v1/schedule/ ${ id } ` , {
method: 'DELETE' ,
headers: { 'x-api-key' : process . env . HOOKED_API_KEY }
});
return { id , result: await response . json () };
})
);
const cancelled = results
. filter ( r => r . status === 'fulfilled' && r . value . result . success )
. map ( r => r . value . id );
const failed = results
. filter ( r => r . status === 'rejected' || ! r . value . result . success )
. map ( r => r . value ?. id || 'unknown' );
return { cancelled , failed };
}
// Usage
const { cancelled , failed } = await cancelMultipleSchedules ([
'post_abc123' ,
'post_def456' ,
'post_ghi789'
]);
console . log ( `Cancelled: ${ cancelled . length } , Failed: ${ failed . length } ` );
curl -X DELETE "https://api.hooked.so/v1/schedule/post_abc123xyz" \
-H "x-api-key: your_api_key_here"
Response
Success Response
Error - Already Published
Error - Not Found
Error - Forbidden
{
"success" : true ,
"message" : "Schedule cancelled successfully" ,
"data" : {
"id" : "post_abc123xyz" ,
"deleted" : true
}
}
Important Notes
What Happens After Cancellation
The scheduled post is permanently deleted
The video itself is NOT deleted - only the schedule
You can schedule the same video again with a new schedule
Webhooks for this schedule will not be triggered
Published Posts
If a post has already been published (status: published), you cannot delete it through this API. To remove published content:
YouTube : Go to YouTube Studio and delete the video
TikTok : Open TikTok app and delete the post
Instagram : Use Instagram app to delete the reel/post
Error Handling
Error Description Solution Schedule not foundInvalid schedule ID Check the schedule ID is correct Cannot delete a published postAlready published Delete directly on the platform Schedule does not belong to your teamWrong ownership Use correct API key
Next Steps
Create Schedule Schedule a new video
List Scheduled View all scheduled posts
List Videos View all your videos
List Integrations View connected platforms
Schedule cancelled successfully