You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PR #768 changed createCommunicationAdapter from sync to async with no migration guide, deprecation period, or token security hardening. This PRD covers the migration guide for the breaking change and addresses four token security gaps (no tenant isolation, no revoke mechanism, no auth timeout, stale token reuse).
Problem Statement
Breaking change: Existing code calling createCommunicationAdapter synchronously will break with no guidance
Token security: Module-level cached auth token has no tenant isolation — wrong tenant in multi-tenant deployments
No revoke: Tokens persist indefinitely with no logout mechanism
No timeout: Device-code auth flow could hang indefinitely on failed auth
Stale tokens: Token not cleared on auth error — invalid token reused on retry
Proposed Approach
Phase 1 — Migration Guide + Deprecation (P0)
Document the sync→async breaking change with before/after code examples
Add runtime deprecation warning if sync call pattern is detected (if feasible)
Update CHANGELOG and any samples that use the sync API
Add migration section to docs/ or UPGRADING.md
Phase 2 — Token Security Hardening (P1)
Tenant-scoped token cache: key tokens by tenant ID, not global singleton
Explicit revoke() method on the adapter for logout/cleanup
Device-code timeout guard: 15-minute max, configurable, clear error on timeout
Clear token on auth error — force re-auth on next call
Phase 3 — Multi-Tenant Testing (P2)
Integration tests: two tenants, verify tokens are isolated
Timeout test: device-code flow with simulated timeout
Activity
diberry commentedon Apr 6, 2026
Summary
PR #768 changed
createCommunicationAdapterfrom sync to async with no migration guide, deprecation period, or token security hardening. This PRD covers the migration guide for the breaking change and addresses four token security gaps (no tenant isolation, no revoke mechanism, no auth timeout, stale token reuse).Problem Statement
createCommunicationAdaptersynchronously will break with no guidanceProposed Approach
Phase 1 — Migration Guide + Deprecation (P0)
docs/orUPGRADING.mdPhase 2 — Token Security Hardening (P1)
revoke()method on the adapter for logout/cleanupPhase 3 — Multi-Tenant Testing (P2)
Acceptance Criteria
revoke()method implemented and documentedArchitecture Notes
packages/squad-sdk/src/platform/comms-teams.tsfix(sdk): Teams adapter token security + migration guide
fix(sdk): Teams adapter token security + migration guide
diberry commentedon Apr 10, 2026
🔒 On hold — focusing on low-touch and medium-touch issues first.