Document the change feed in openapi.yaml - #11
Merged
Conversation
/changes and /changes/stream were missing from the spec, which SKILL.md points agents at as the full API reference. web/usage.md covers them, but an agent reading the reference finds nothing and guesses parameter names. The guess that costs you is the resume cursor: it is `since`, and an unrecognized query parameter is ignored rather than rejected, so `?cursor=` silently replays the feed from event 1 instead of resuming. Harmless on a short feed, not on a long one. Both endpoint descriptions now say so explicitly. Also documents the `workspace` query override (403 when the token is confined, 404 when the workspace is unknown), the repeatable `kind` filter and its event kinds, the Last-Event-ID header, limit's 100/1000 default/cap, and an Event schema. Verified against a running v1.5.0: parameter names, the limit cap, the repeatable kind filter, cursor scope binding, and both workspace error codes.
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.
/changesand/changes/streamshipped in v1.5.0 but are absent fromopenapi.yaml— the fileskills/tracker/SKILL.mdpoints agents at as "the full API reference".web/usage.mddocuments them well; the spec doesn't mention them at all.Why it matters
The parameter you have to guess is the resume cursor. It's
since, and an unrecognized query parameter is ignored rather than rejected — so?cursor=doesn't error, it silently replays the feed from event 1. I hit this while smoke-testing v1.5.0: the stream looked like it was working, and only reading the handler explained why old events kept arriving. On a 4-event feed that's invisible; on a real one it's a consumer reprocessing everything from the beginning.Both endpoint descriptions now call that out by name rather than just documenting the happy path.
Also documented
workspacequery override — 403workspace_forbiddenwhen the token is confined, 404 when the workspace is unknown (as a reusableWorkspaceQueryparameter)kindfilter and the nine event kindsLast-Event-IDheader as the alternative tosincelimitdefault 100 / cap 1000Eventschema, including whatxact_idis forworkspace_forbiddenadded to theErrorcode listVerification
Spec parses as YAML and every local
$refresolves. Behaviour checked against a running v1.5.0 rather than read off the source: parameter names, the limit cap, the repeatablekindfilter, cursor scope binding to the kind filter, and both workspace error codes.Docs only — no code, no behaviour change.
One thing left alone:
info.versionstill reads1.3.0. Bumping it seemed like your call, not mine.