diff --git a/doc/compiled.json b/doc/compiled.json index 50246a1c..09065e17 100644 --- a/doc/compiled.json +++ b/doc/compiled.json @@ -5926,7 +5926,7 @@ "/projects/{project_id}/documents/{id}": { "delete": { "summary": "Delete document", - "description": "Delete an existing document.", + "description": "Permanently deletes a document and all of its associated translation segments from the project. Use this when you want to remove a document that is no longer needed; the deletion cannot be reversed and all associated segments will be lost.\n", "operationId": "document/delete", "tags": [ "Documents" @@ -5953,8 +5953,7 @@ "$ref": "#/components/responses/401" }, "403": { - "$ref": "#/components/responses/403", - "description": "Forbidden. Returned when the access token lacks the `write` scope or when the requesting user is not allowed to delete this document." + "$ref": "#/components/responses/403" }, "404": { "$ref": "#/components/responses/404" @@ -5967,10 +5966,6 @@ } }, "x-code-samples": [ - { - "lang": "Curl", - "source": "curl \"https://api.phrase.com/v2/projects/:project_id/documents/:id\" \\\n -u USERNAME_OR_ACCESS_TOKEN \\\n -X DELETE \\\n -H 'Content-Type: application/json'" - }, { "lang": "CLI v2", "source": "phrase documents delete \\\n--project_id \\\n--id \\\n--access_token " diff --git a/paths/documents/destroy.yaml b/paths/documents/destroy.yaml index bcae3e6e..176a69c0 100644 --- a/paths/documents/destroy.yaml +++ b/paths/documents/destroy.yaml @@ -1,6 +1,7 @@ --- summary: Delete document -description: Delete an existing document. +description: | + Permanently deletes a document and all of its associated translation segments from the project. Use this when you want to remove a document that is no longer needed; the deletion cannot be reversed and all associated segments will be lost. operationId: document/delete tags: - Documents @@ -13,24 +14,17 @@ responses: "$ref": "../../responses.yaml#/200" '400': "$ref": "../../responses.yaml#/400" - '404': - "$ref": "../../responses.yaml#/404" '401': "$ref": "../../responses.yaml#/401" '403': "$ref": "../../responses.yaml#/403" - description: Forbidden. Returned when the access token lacks the `write` scope or when the requesting user is not allowed to delete this document. + '404': + "$ref": "../../responses.yaml#/404" '422': "$ref": "../../responses.yaml#/422" '429': "$ref": "../../responses.yaml#/429" x-code-samples: -- lang: Curl - source: |- - curl "https://api.phrase.com/v2/projects/:project_id/documents/:id" \ - -u USERNAME_OR_ACCESS_TOKEN \ - -X DELETE \ - -H 'Content-Type: application/json' - lang: CLI v2 source: |- phrase documents delete \