Update API \ Delete a tweet on Twitter PHP SDK

Resource/URI HTTP DELETE
Facebook · Delete a post from a page the user administers. /update/identities/<identity_token>/facebook/page/<pageid>/post/<postid>.json Delete
Page Post
Facebook · Delete a picture from a page the user administers. /update/identities/<identity_token>/facebook/page/<pageid>/picture/<pictureid>.json Delete
Page Picture
Facebook · Delete a video from a page the user administers. /update/identities/<identity_token>/facebook/page/<pageid>/video/<videoid>.json Delete
Page Video
Twitter · Delete a tweet from a user's timeline. /update/identities/<identity_token>/twitter/post/<postid>.json Delete
Tweet

Workflow

Request: the code to send to the API

Send an API request to the following endpoint to remove a Tweet from a user's Twitter timeline:

DELETE /update/identities/<identity_token>/twitter/post/<postid>.json

The <identity_token> is obtained whenever one of your users connects using his Twitter account. The <postid> must be the identifier of a Tweet published using our API and/or owned by the same user.

To be able to use this endpoint Twitter must be fully configured for your OneAll Site and the setting Permissions \ Access permission of your Twitter app must be set to Read and Write.

Result: the code returned by the API

The API either returns a HTTP status code 200 if the Tweet was deleted successfully or an appropriate message body with further details on the error that occured.

Response Example

{
  "response": {
    "request": {
      "date": "Fri, 04 Oct 2019 09:54:46 +0200",
      "resource": "/update/identities/95681432-e02d-4a0b-ac6a-5c59d0e1fdfd/twitter/post/2505330642880432.json",
      "status": {
        "flag": "success",
        "code": 200,
        "info": "The post has successfully been removed."
      }
    }
  }
}

User Contributed Notes