Skip to content

fix(asm): rename deleteAsset operationId to archiveAsset#2

Open
dmchaledev wants to merge 1 commit into
mainfrom
claude/elegant-edison-MKGw1
Open

fix(asm): rename deleteAsset operationId to archiveAsset#2
dmchaledev wants to merge 1 commit into
mainfrom
claude/elegant-edison-MKGw1

Conversation

@dmchaledev
Copy link
Copy Markdown
Contributor

Problem

DELETE /assets/{asset_id} has operationId: deleteAsset, but the operation does not delete — it soft-archives the asset. The summary and description already say "Archive asset" / "Marks an asset as archived", so the operationId is the only inconsistency.

This matters because:

  • SDK generators (openapi-generator, oapi-codegen, etc.) use operationId as the method name. Every generated client ships a deleteAsset() method that actually archives, which is confusing and potentially dangerous — callers may avoid it fearing permanent data loss, or call it expecting deletion.
  • OpenAPI tooling (mock servers, contract tests, documentation renderers) surfaces the operationId prominently. The mismatch erodes trust in the spec's accuracy.

Fix

One-line rename: deleteAssetarchiveAsset.

# before
operationId: deleteAsset

# after
operationId: archiveAsset

This is a breaking change for existing generated clients that reference deleteAsset by name, but it is the correct fix — shipping a spec with a misleading operationId pushes that breakage downstream to every consumer indefinitely.

Test plan

  • CI Spectral lint passes on the updated spec
  • Verify no other files in the repo reference the old deleteAsset operationId

Generated by Claude Code

The DELETE /assets/{asset_id} operation soft-archives assets rather than
permanently removing them. The misleading operationId causes SDK generators
to emit a deleteAsset() method that is at odds with its actual behaviour,
and risks callers avoiding the operation out of fear of data loss.

https://claude.ai/code/session_017hoUmwWaX3gAQTqJF7qcCC
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants