Skip to content

Sync spec: list pagination and sort params, color palettes, skills - #101

Merged
ernestoongaro merged 2 commits into
mainfrom
sync-spec-list-pagination
Sep 15, 2026
Merged

ernestoongaro merged 2 commits into
mainfrom
sync-spec-list-pagination

Conversation

@ernestoongaro

@ernestoongaro ernestoongaro commented Sep 15, 2026

Copy link
Copy Markdown
Collaborator

Summary

Syncs api/openapi.json from exploreomni/omni@main.

Headline: exploreomni/omni#64034. The documents, folders and models list endpoints now document what their validators enforce. The old docs caused avoidable 400s, many of them from CLI requests.

Command Change
documents list, folders list, models list --page-size is an integer 1–100 (default 20); --sort-direction defaults to desc
documents list --sort-field adds lastViewedAt
folders list --sort-field is name, favorites or path (drops createdAt, updatedAt)
models list --model-kind adds EXTENSION_BRANCH; --sort-field defaults to updatedAt

Also pulled in by the full sync:

  • New color-palettes group: list, get, create, update, delete
  • New skills group: list, get, create, update, delete (list takes --creator-id, --identifier, pagination and sort flags)
  • models content-validator-get: --force-full-validation
  • query wait: the deprecated job_ids param, exposed as --job-ids-2 since it would also become --job-ids. Use --job-ids.
  • query run body: timezone (a body field, so it's set via --body, not a flag)
  • Response and body schema updates for routines, v2 document app writes, documents, topics and whoami

No operations or params were removed.

Generator fix: backticks in descriptions no longer replace the flag placeholder. pflag treats the first backquoted word in a flag's usage as its value placeholder. So a spec description with `job_ids` rendered as --job-ids job_ids, and 18 flags across the spec had the same problem (--creator-id creator.id, --hard-refresh schemas, --model-id rolesByModel, …). Flag descriptions built from the spec (query params, multipart fields, promoted body fields) now quote code spans with ', so every flag shows its type:

--job-ids string      … Required unless the deprecated 'job_ids' is sent.
--creator-id string   Filter by creator membership ID — 'creator.id' from a listed skill, …

Test plan

  • make build, make test
  • --help for every changed command shows the new flags and enums
  • Placeholder fix: unit tests for query params and multipart fields; a test over the real spec checks that every generated flag's placeholder is its type name and that no usage string contains a backtick; a regression test covers the known flags. All four fail with the fix reverted (18 bad placeholders).
  • --help sweep over all 246 generated commands: none fail. Placeholders are only string, int, stringArray and boolean, and no flag section contains a backtick.
  • Params reach the wire under their spec names (checked against a local echo server): force_full_validation, job_ids, pageSize/sortField/sortDirection, modelKind, creatorId/identifier
  • Live against a playground org:
    • documents list, folders list and models list accept --page-size 100 and return 400 for 101 and 0. The default page is 20 records.
    • documents list --sort-field lastViewedAt works; folders list --sort-field createdAt returns 400 listing the allowed values.
    • models list --model-kind EXTENSION_BRANCH and --include activeBranches work.
    • models content-validator-get works with and without --force-full-validation true.
    • color-palettes: create → get → update (name, type, colors) → get → delete → get returns 404. Invalid hex returns 400.
    • skills: create → get → update → list by --identifier and by sort → a duplicate identifier returns 409 → delete → get returns 404.
    • query wait returns the same result for --job-ids and --job-ids-2, and renders with --format human and --chart.
    • Flags whose descriptions had backticks, run live:
      • whoami --model-id narrows rolesByModel.
      • documents v2-get --pretty true returns indented JSON, false compact.
      • ai-eval prompt-sets-list --archived and --model-ids return the right set: a temporary prompt set appears under --archived false before archiving and under --archived true after.
      • ai-eval runs-list --archived works.
      • ai-model-suggestions model-suggestions-list --status all|ignored works.
      • skills list --creator-id returns your own skills and 404 for an unknown membership.
      • models refresh --hard-refresh false completed a soft refresh; an invalid value returns 400.

🤖 Generated with Claude Code

https://claude.ai/code/session_0174fd5xx9JyExdkPYJXECu4

ernestoongaro and others added 2 commits September 15, 2026 15:49
Headline (exploreomni/omni#64034): documents, folders and models list
endpoints now document the params their validators enforce. pageSize is an
integer 1-100 (default 20), sortDirection defaults to desc, documents gains
sortField lastViewedAt, folders drops createdAt/updatedAt from sortField,
and models gains modelKind EXTENSION_BRANCH.

Also pulled in by the full sync:
- New color-palettes group: list, get, create, update, delete
- New skills group: list, get, create, update, delete
- models content-validator-get: --force-full-validation
- query wait: deprecated job_ids param, exposed as --job-ids-2
- query run body: timezone
- Response/schema updates for routines, v2 document app writes, documents,
  topics and whoami

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0174fd5xx9JyExdkPYJXECu4
pflag reads the first backquoted word in a flag's usage as its value
placeholder, so a spec description mentioning `job_ids` rendered as
--job-ids job_ids. Generated flag descriptions (query params, multipart
fields, promoted body fields) now quote code spans with ' instead, and every
flag shows its type.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0174fd5xx9JyExdkPYJXECu4
@ernestoongaro
ernestoongaro force-pushed the sync-spec-list-pagination branch from 80c0bd2 to 9e4d7f9 Compare September 15, 2026 14:50
@ernestoongaro
ernestoongaro merged commit d55bf49 into main Sep 15, 2026
2 checks passed
@ernestoongaro
ernestoongaro deleted the sync-spec-list-pagination branch September 15, 2026 14:51
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