Skip to content

Remove Content ​

DELETEhttps://api.repliz.com/public/content/{contentId}

Permanently delete a content/post from the associated social media platform. Once deleted, the content will no longer be available on the platform.

WARNING

Content deletion is only supported on the following platforms: Facebook, Threads, YouTube, LinkedIn, and X (Twitter).

Endpoint Details ​

  • Authentication: Basic Auth (Authorization: Basic Base64(AccessKey:SecretKey))
  • Access Tier: Gold+

Parameters ​

ParameterTypeRequiredDescription
contentIdstringYesID of the post on the platform, the id from Get Content, for example 113958387982006_942538351814577 on Facebook. The post is deleted on the platform.
accountIdstringYesID of the connected account the post belongs to, the _id from Get Account.

Example Request ​

bash
curl -X DELETE "https://api.repliz.com/public/content/113958387982006_942538351814577?accountId=680affa5ce12f2f72916f67e" \
  -H "Authorization: Basic $(echo -n 'YOUR_ACCESS_KEY:YOUR_SECRET_KEY' | base64)"
javascript
import axios from 'axios';

const contentId = '113958387982006_942538351814577';

const response = await axios.delete(`https://api.repliz.com/public/content/${contentId}`, {
  params: {
    accountId: '680affa5ce12f2f72916f67e',
  },
  auth: {
    username: 'YOUR_ACCESS_KEY',
    password: 'YOUR_SECRET_KEY',
  },
});

console.log(response.data);
javascript
const credentials = btoa('YOUR_ACCESS_KEY:YOUR_SECRET_KEY');

const contentId = '113958387982006_942538351814577';

const response = await fetch(
  `https://api.repliz.com/public/content/${contentId}?accountId=680affa5ce12f2f72916f67e`,
  {
    method: 'DELETE',
    headers: {
      Authorization: `Basic ${credentials}`,
    },
  },
);

const data = await response.json();
console.log(data);

Response ​

json
// No content returned on success
json
// Account Not Found
{
  "code": 404,
  "message": "account not found"
}

// Content Not Found
{
  "code": 404,
  "message": "content not found"
}
json
{
  "code": 401,
  "message": "unauthorized"
}