Skip to content

feat(protocol): broker Linear access tokens over a linearcred frame family - #1666

Merged
zfy0701 merged 1 commit into
mainfrom
claude/linearcred-frames
Sep 1, 2026
Merged

feat(protocol): broker Linear access tokens over a linearcred frame family#1666
zfy0701 merged 1 commit into
mainfrom
claude/linearcred-frames

Conversation

@zfy0701

@zfy0701 zfy0701 commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Linear access tokens expire in ~24 h and refresh rotates the refresh token, so the Control Plane is the single durable writer and the daemon pulls a fresh token on demand (linear-integration.md §4.4, §7.3). This is the protocol leg only — the CP handler and daemon client land with their hosts.

  • frames/linearcred.ts: REQ/REP pair mirroring gitcredlinearcred/request names only an integration id; the correlated linearcred/grant carries the token material (never log). Org-scoped; failures ride the shared error reply vocabulary, no family-specific error frame.
  • Registered in FRAME_SCHEMAS, the AnyFrame union, and the barrel export — the same three surfaces gitcred occupies. No feature-negotiation constant: Linear availability is gated by capabilities.platforms, not a server feature.
  • frames/integration.ts: documents the opaque Linear integration-config payload beside its platform peers — a short-lived access-token snapshot plus expiry rather than a durable bot token.

Tests: 8 new cases (schema guards, envelope round-trips, org-scope pin, config payload); protocol suite, daemon + CP typecheck, lint — all green.

🤖 Generated with Claude Code

…amily

Linear access tokens expire in ~24 h and refresh rotates the refresh token, so
the Control Plane is the single durable writer and the daemon pulls a fresh
token on demand (linear-integration.md §4.4, §7.3). Adds the REQ/REP pair
mirroring gitcred — linearcred/request names only an integration id, and the
correlated linearcred/grant carries the token material itself, so the payload
must never be logged. Both frames are org-scoped; failures ride the shared
error reply.

Also documents the opaque Linear integration-config payload beside its
platform peers (§7.2): the projected spec carries a short-lived token snapshot
plus its expiry rather than a durable bot token.

Protocol only — the daemon and Control Plane consumers land separately.

@agentconnect-md-test agentconnect-md-test Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved. The new linearcred/request and linearcred/grant schemas match the accepted Linear token-custody design: the daemon names only an integration, the correlated grant carries only the short-lived access token and expiry, and refresh-token/client-secret custody remains CP-only. Both frame types are registered consistently in FRAME_SCHEMAS and AnyFrame, exported from the protocol barrel, and remain org-scoped. IntegrationLinearConfig also matches the designed restart-safe access-token snapshot.

I found no blocking regressions in this protocol-only leg.

Verification: the protocol suite passed (28 files, 468 tests), the protocol TypeScript 6.0.3 check passed, and git diff --check plus the changed-file Prettier check passed.

sent by review-bot (Codex · gpt-5.6-sol) · open in session

@zfy0701
zfy0701 merged commit f307ea6 into main Sep 1, 2026
14 checks passed
@zfy0701
zfy0701 deleted the claude/linearcred-frames branch September 1, 2026 07:43
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