fix(docs): replace phantom FORMAT_INCOMPATIBLE with UNSUPPORTED_FEATURE#4860
Merged
Conversation
The `create_media_buy` docs referenced `FORMAT_INCOMPATIBLE` in the error
table and two JSON response examples, but the code was never defined in
`error-code.json`. SDKs that validate `errors[].code` against the published
enum would reject responses built from the docs literally.
Migrated all three references to `UNSUPPORTED_FEATURE` — semantics match
("a requested feature or field is not supported by this seller" = "format
not in the product's accepted set"). The error-table row was also merged
with the sibling `UNSUPPORTED_FEATURE` row added in #4845 (v2
`capability_ids[]` failure modes), so a single row now spans both v1
`format_ids[]` and v2 `capability_ids[]` mismatch cases.
Closes #4852.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
LGTM. Real bug, clean fix — phantom enum value in publisher docs now points at a code that actually exists on the wire.
Things I checked
FORMAT_INCOMPATIBLEis absent fromstatic/schemas/source/enums/error-code.jsonand from every other file in the tree post-merge (grep acrossdocs/,mintlify-docs/,static/schemas/returns nothing).UNSUPPORTED_FEATUREis defined atstatic/schemas/source/enums/error-code.json:22withenumDescriptionsat L104 — "A requested feature or field is not supported by this seller. Recovery: correctable" — semantic match for the format-mismatch case is exact.- Three call sites migrated (error-table row + two JSON examples at L933, L1044). The L1060 case is unrelated and was already
UNSUPPORTED_FEATUREfrom #4845. - Row merge at
create_media_buy.mdx:921is the right shape — single row now spans v1 (format_ids[]) and v2 (capability_ids[]) format-mismatch failure modes, which lines up with thepackages[i].capability_idsrow at L189 that already specifiesUNSUPPORTED_FEATUREas the canonical code. - Changeset present (
.changeset/fix-format-incompatible-phantom-code.md) and correctly typedpatch— docs-only fix, no wire shape change. - Lineage cited (#4845, #4852) and accurate.
Follow-ups (non-blocking)
- Test-plan checkbox "Mintlify renders the merged error-table row cleanly" is unchecked. The merged description cell is dense — worth a glance at the rendered Mintlify preview before assuming the table doesn't wrap awkwardly. Non-blocking; CI gate plus the surrounding rows being similarly verbose means the risk is cosmetic.
Safe to merge.
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.
Summary
Closes #4852.
create_media_buydocs referencedFORMAT_INCOMPATIBLEin the error table and two JSON response examples, but the code is not defined instatic/schemas/source/enums/error-code.json. SDKs that validateerrors[].codeagainst the published enum would reject responses built from the docs literally — sellers reading the spec either ship a non-conformant code or invent their own.Surfaced during review of #4845 (added
capability_ids[]toPackageRequest), where the new failure modes were deliberately routed toUNSUPPORTED_FEATUREto avoid inheriting the bug.Change
Migrated all three references to
UNSUPPORTED_FEATURE— the enum value whose semantics ("a requested feature or field is not supported by this seller") match the "format not in the product's accepted set" case exactly. The error-table row was also merged with the siblingUNSUPPORTED_FEATURErow added in #4845 (which covered the v2capability_ids[]failure modes), so a single row now spans both v1 (format_ids[]) and v2 (capability_ids[]) format-mismatch cases.Files
docs/media-buy/task-reference/create_media_buy.mdx— 1 table row merged, 2 JSON example bodies.changeset/fix-format-incompatible-phantom-code.md—patchTest plan
🤖 Generated with Claude Code