Skip to content

docs(api): make the reference examples internally consistent - #249

Merged
ysyneu merged 2 commits into
mainfrom
feat/api-review-auto-fix-20260806
Aug 6, 2026
Merged

docs(api): make the reference examples internally consistent#249
ysyneu merged 2 commits into
mainfrom
feat/api-review-auto-fix-20260806

Conversation

@ysyneu

@ysyneu ysyneu commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

Fixes six examples that contradicted themselves on the rendered page: a filtered ServiceMap fleet response returning a host that fails the filter while its coverage counts say otherwise; a preset-severity rule whose create priority disagreed with the list it appears in; history examples whose total did not match the items beside it and whose "snapshot taken before the change" already carried the change; a resource order_id dated a year after the resource it provisioned, with a billing window not anchored where the field descriptions say. Example addresses move to the RFC 5737 documentation range this corpus already uses elsewhere.

No downstream release needed — examples feed no code generation, and regenerating the SDK against this spec produces zero generated-code changes while its spec-example round-trip test still passes.

ysyneu added 2 commits August 6, 2026 08:07
Each of these contradicted itself on the rendered page:

- ServiceMap fleet: the response showed a single `active` host for a request
  filtering on `degraded`/`stale`, while `coverage` claimed two returned and
  counted one of each. Now two hosts that match both the filter and the counts.
- Preset-severity: the rule returned by `create` carried a priority the `list`
  example contradicted, and the history example's "empty" snapshot was
  timestamped after a rule that already existed. Rebuilt as one timeline — two
  creates and a disable, three snapshots, each holding the state the call that
  wrote it was about to change.
- History `total` now equals the number of items returned, in both the
  preset-severity and error-ingestion examples.
- Resource info: the order id encoded a date a year after the `created_at` of
  the resource it provisioned, and the billing window was not the 30-day span
  anchored at `created_at` that the field descriptions promise.
- Example addresses now use the RFC 5737 documentation range, which the rest of
  the corpus already uses, instead of private-range ones.

Examples feed no code generation — only the request-side ones reach the CLI, and
none of those change here — so the generated SDK and CLI are unaffected.
docs(api): make the reference examples internally consistent
@ysyneu
ysyneu merged commit 2da764f into main Aug 6, 2026
1 check passed
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.

1 participant