# Cancel a post (/zh/growsocmed/docs/api-reference/posts/cancel-post)

Cancel the accounts of a post that have not published yet

DELETE /posts/{id}

```json
{
  "tags": [
    "Posts"
  ],
  "summary": "Cancel a post",
  "parameters": [
    {
      "schema": {
        "type": "string",
        "format": "uuid"
      },
      "required": true,
      "name": "id",
      "in": "path"
    }
  ],
  "responses": {
    "200": {
      "description": "OK",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "post": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "text": {
                    "type": "string"
                  },
                  "status": {
                    "type": "string",
                    "enum": [
                      "scheduled",
                      "publishing",
                      "published",
                      "partial",
                      "failed",
                      "canceled"
                    ]
                  },
                  "source": {
                    "type": "string"
                  },
                  "scheduled_at": {
                    "type": "string"
                  },
                  "created_at": {
                    "type": "string"
                  },
                  "created_by": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "properties": {
                      "id": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "id",
                      "name"
                    ]
                  },
                  "media": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "image",
                            "video",
                            "document"
                          ]
                        },
                        "url": {
                          "type": [
                            "string",
                            "null"
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "type",
                        "url"
                      ]
                    }
                  },
                  "targets": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "account_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "platform": {
                          "type": "string"
                        },
                        "username": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "display_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "avatar_url": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "pending",
                            "publishing",
                            "published",
                            "failed",
                            "canceled"
                          ]
                        },
                        "text": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "media_ids": {
                          "type": [
                            "array",
                            "null"
                          ],
                          "items": {
                            "type": "string"
                          }
                        },
                        "permalink": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "error_code": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "error_message": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "published_at": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "options": {
                          "type": "object",
                          "additionalProperties": {}
                        }
                      },
                      "required": [
                        "id",
                        "account_id",
                        "platform",
                        "username",
                        "display_name",
                        "avatar_url",
                        "status",
                        "text",
                        "media_ids",
                        "permalink",
                        "error_code",
                        "error_message",
                        "published_at",
                        "options"
                      ]
                    }
                  }
                },
                "required": [
                  "id",
                  "text",
                  "status",
                  "source",
                  "scheduled_at",
                  "created_at",
                  "created_by",
                  "media",
                  "targets"
                ]
              }
            },
            "required": [
              "post"
            ]
          }
        }
      }
    }
  },
  "operationId": "cancel-post",
  "description": "Cancel the accounts of a post that have not published yet"
}
```