Repository navigation
docs(runbooks): provisioning a hosted agent (W2 operator runbook) - #1345
Merged
Merged
Conversation
…book Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_013pc6nGXRS8mHvrwcXMSRDK
samxu01
pushed a commit
that referenced
this pull request
Sep 26, 2026
…s (TASK-145) Both removal paths left every grant on a removed connection `active`: `DELETE /api/integrations/:id` hard-deleted the row (integrations.ts:756) and the installable path tombstoned it (installableInstallationService.ts), while `revokeGrant` had exactly one caller — the granter's own route (grants.ts:424). After the hard delete that route could not act either: ownership resolves through `findConnection` (grants.ts:257), so each grant on the connection answered 403 `access_denied`, and nothing recorded a revoke. One shared step now runs on both paths, before the row moves: `revokeConnectionGrants` (roomGrantService.ts) addresses a connection by the row's `_id`, its top-level `installationId` and `config.installationId`, revokes each grant on it (cascading the lineage) and returns the count. The installable path calls it once per uninstall, ahead of both the projector loop and the retired-manifest tombstone. Two follow-ups from the gate, folded at this head: * The grants step was guarded by `if (revokedBy)`, which fails in the wrong direction — an empty actor skipped the revoke and still reached the delete (Vera 74462). The identity is now a floor: no id, no delete, 401. `auth` always sets one, so it is unreachable today; it is there so it cannot become reachable in silence, and the route suite witnesses it. * `DELETE /:id` was the one write sink on the router without a limiter — `js/missing-rate-limiting` #1345 (open on main, integrations.ts:746) names it, while `POST /` and `PATCH /:id` already carry `writeIntegrationsRateLimit`. Authority already ended at the call boundary — toolBrokerService.ts:464-467 refuses a missing row, `status !== 'connected'` or `revokedAt`, and grants expire — so this is the revocation record and the granter's remedy, not a live bypass (tools plan §10.5).
samxu01
pushed a commit
that referenced
this pull request
Sep 26, 2026
…s (TASK-145) Both removal paths left every grant on a removed connection `active`: `DELETE /api/integrations/:id` hard-deleted the row (integrations.ts:756) and the installable path tombstoned it (installableInstallationService.ts), while `revokeGrant` had exactly one caller — the granter's own route (grants.ts:424). After the hard delete that route could not act either: ownership resolves through `findConnection` (grants.ts:257), so each grant on the connection answered 403 `access_denied`, and nothing recorded a revoke. One shared step now runs on both paths, before the row moves: `revokeConnectionGrants` (roomGrantService.ts) addresses a connection by the row's `_id`, its top-level `installationId` and `config.installationId`, revokes each grant on it (cascading the lineage) and returns the count. The installable path calls it once per uninstall, ahead of both the projector loop and the retired-manifest tombstone. Two follow-ups from the gate, folded at this head: * The grants step was guarded by `if (revokedBy)`, which fails in the wrong direction — an empty actor skipped the revoke and still reached the delete (Vera 74462). The identity is now a floor: no id, no delete, 401. `auth` always sets one, so it is unreachable today; it is there so it cannot become reachable in silence, and the route suite witnesses it. * `DELETE /:id` was the one write sink on the router without a limiter — `js/missing-rate-limiting` #1345 (open on main, integrations.ts:746) names it, while `POST /` and `PATCH /:id` already carry `writeIntegrationsRateLimit`. Authority already ended at the call boundary — toolBrokerService.ts:464-467 refuses a missing row, `status !== 'connected'` or `revokedAt`, and grants expire — so this is the revocation record and the granter's remedy, not a live bypass (tools plan §10.5).
samxu01
pushed a commit
that referenced
this pull request
Sep 26, 2026
…s (TASK-145) Both removal paths left every grant on a removed connection `active`: `DELETE /api/integrations/:id` hard-deleted the row (integrations.ts:756) and the installable path tombstoned it (installableInstallationService.ts), while `revokeGrant` had exactly one caller — the granter's own route (grants.ts:424). After the hard delete that route could not act either: ownership resolves through `findConnection` (grants.ts:257), so each grant on the connection answered 403 `access_denied`, and nothing recorded a revoke. One shared step now runs on both paths, before the row moves: `revokeConnectionGrants` (roomGrantService.ts) addresses a connection by the row's `_id`, its top-level `installationId` and `config.installationId`, revokes each grant on it (cascading the lineage) and returns the count. The installable path calls it once per uninstall, ahead of both the projector loop and the retired-manifest tombstone. Two follow-ups from the gate, folded at this head: * The grants step was guarded by `if (revokedBy)`, which fails in the wrong direction — an empty actor skipped the revoke and still reached the delete (Vera 74462). The identity is now a floor: no id, no delete, 401. `auth` always sets one, so it is unreachable today; it is there so it cannot become reachable in silence, and the route suite witnesses it. * `DELETE /:id` was the one write sink on the router without a limiter — `js/missing-rate-limiting` #1345 (open on main, integrations.ts:746) names it, while `POST /` and `PATCH /:id` already carry `writeIntegrationsRateLimit`. Authority already ended at the call boundary — toolBrokerService.ts:464-467 refuses a missing row, `status !== 'connected'` or `revokedAt`, and grants expire — so this is the revocation record and the granter's remedy, not a live bypass (tools plan §10.5).
lilyshen0722
added a commit
to thantiklermcirony/commonly
that referenced
this pull request
Oct 9, 2026
…s (TASK-145) (Team-Commonly#1922) Both removal paths left every grant on a removed connection `active`: `DELETE /api/integrations/:id` hard-deleted the row (integrations.ts:756) and the installable path tombstoned it (installableInstallationService.ts), while `revokeGrant` had exactly one caller — the granter's own route (grants.ts:424). After the hard delete that route could not act either: ownership resolves through `findConnection` (grants.ts:257), so each grant on the connection answered 403 `access_denied`, and nothing recorded a revoke. One shared step now runs on both paths, before the row moves: `revokeConnectionGrants` (roomGrantService.ts) addresses a connection by the row's `_id`, its top-level `installationId` and `config.installationId`, revokes each grant on it (cascading the lineage) and returns the count. The installable path calls it once per uninstall, ahead of both the projector loop and the retired-manifest tombstone. Two follow-ups from the gate, folded at this head: * The grants step was guarded by `if (revokedBy)`, which fails in the wrong direction — an empty actor skipped the revoke and still reached the delete (Vera 74462). The identity is now a floor: no id, no delete, 401. `auth` always sets one, so it is unreachable today; it is there so it cannot become reachable in silence, and the route suite witnesses it. * `DELETE /:id` was the one write sink on the router without a limiter — `js/missing-rate-limiting` Team-Commonly#1345 (open on main, integrations.ts:746) names it, while `POST /` and `PATCH /:id` already carry `writeIntegrationsRateLimit`. Authority already ended at the call boundary — toolBrokerService.ts:464-467 refuses a missing row, `status !== 'connected'` or `revokedAt`, and grants expire — so this is the revocation record and the granter's remedy, not a live bypass (tools plan §10.5).
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.
Five-minute operator path for a hosted agent once a model key exists: deploy the worker with its two secrets, register + mint like any BYO agent, provision, verify via /status, deprovision. Failure signatures table maps every lastError the runtime can emit. Known boundaries cross-referenced (#1344, D3.1, compaction).
🤖 Generated with Claude Code
https://claude.ai/code/session_013pc6nGXRS8mHvrwcXMSRDK