Skip to content

docs(API): improve delete /projects/{project_id}/documents/{id} documentation#1185

Open
Stephen Lumenta (sbl) wants to merge 2 commits into
mainfrom
devex-119-documents-delete-document
Open

docs(API): improve delete /projects/{project_id}/documents/{id} documentation#1185
Stephen Lumenta (sbl) wants to merge 2 commits into
mainfrom
devex-119-documents-delete-document

Conversation

@sbl

Copy link
Copy Markdown
Contributor

Improves the documentation for delete /projects/{project_id}/documents/{id}: sharper descriptions, parameter docs, error responses, and usage examples.

Drafted with AI assistance and grounded in the API implementation. Please review for technical accuracy before merging; nothing is merged automatically.

🤖 Generated with Claude Code

@sbl Stephen Lumenta (sbl) added the developer-hub-api-quality API doc quality fix from the API Grader label Jun 15, 2026
@github-actions

github-actions Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

API changelog (oasdiff)

Doc-only edits (descriptions, examples) do not appear here.

10 changes: 0 error, 0 warning, 10 info
info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/api_name` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/default_encoding` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/default_file` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/description` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/exportable` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/extension` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/importable` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/includes_locale_information` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/name` became required for the status `200`

info	[response-property-became-required] at doc/compiled.json
	in API GET /formats
		the response property `items/renders_default_locale` became required for the status `200`

@sbl

Copy link
Copy Markdown
Contributor Author

This PR replaces #1177, which was closed after jablan's review.

Feedback addressed from #1177:

Comment Status
"numeric primary key is an internal development detail and should not be exposed" ✅ Fixed
"This 403 description is almost fully generic and could be moved to the referenced section" ✅ Fixed

What changed:

  • The description no longer mentions numeric primary key or DocumentPolicy#destroy?. Implementation details are translated into caller-facing behaviour: "Requires the write scope on the access token and manage permission on the document."
  • The 403 description is now endpoint-specific: "Obtain a token with the write scope or request manage access from a project administrator." Generic 403 prose has been removed rather than moved inline.

🤖 Generated with Claude Code

@sbl Stephen Lumenta (sbl) changed the title feat(API): improve delete /projects/{project_id}/documents/{id} documentation fix(API): improve delete /projects/{project_id}/documents/{id} documentation Jun 17, 2026
Comment thread paths/documents/destroy.yaml Outdated
Comment thread paths/documents/destroy.yaml Outdated
…{id}

- CLI v2 sample: replace slug-like example values (my-project-xyz123,
  doc-abc456) with the <project_id>/<id> placeholders used by every other
  endpoint, and fix --access_token to take <token> rather than a
  username (a username will not authenticate). (theSoenke)
- Drop the scope/permission sentence from the top-level description; the
  403 response already documents the write-scope and manage-permission
  requirement.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@sbl Stephen Lumenta (sbl) changed the title fix(API): improve delete /projects/{project_id}/documents/{id} documentation docs(API): improve delete /projects/{project_id}/documents/{id} documentation Jun 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

developer-hub-api-quality API doc quality fix from the API Grader

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants