Repository navigation
Music billed by generated length, final refund state on job.failed, 410 for retired models - #37
Merged
Merged
Conversation
…10 for retired models - Webhooks: the refund is booked before job.failed is sent, so refunded and price in that payload are final; the example now shows a refunded job at 0. The jobs endpoint stays the reference for a job that was never charged. - Text-to-music: billed by the length actually generated. The price quote is for the requested duration and is the maximum; the difference is returned once the result is stored, and the final charge is in the job result and the job.completed webhook (music pages and pricing). - Errors: document 410 Gone with code model_retired, retired_at and replacement. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
webhooks.mdx,openapi*.json): the refund is booked beforejob.failedis sent, sorefundedandpricein that payload are final. The example shows a refunded job at0.music.mdx,music-price.mdx,pricing.mdx): billed by the length actually generated. The/pricequote is for the requesteddurationand is the maximum; the difference is returned once the result is stored, and the final charge ispricein the job result and thejob.completedwebhook.errors.mdx): new410 Gonefor retired models, withcode: "model_retired",retired_atandreplacement, also returned by the model's/priceendpoint. The example is a real response for a retired model.Checks
410body (including on/price) checked against the production API.npx mint@latest broken-links(node:22, LF copy): no broken links found.