Skip to content

chore(decisioning): AuthInfo migration to kind-discriminated credential variant #358

@bokelley

Description

@bokelley

Summary

Sub-task of Tier 2 but deserves its own tracking. Current AuthInfo is flat (kind: str + key_id + principal + scopes). Migrate to a credential: ApiKeyCredential | OAuthCredential | HttpSigCredential discriminated union per JS ResolvedAuthInfo.

Design

  • New shape: AuthInfo.credential is a discriminated union keyed by kind
  • Keep flat shape as deprecated alias for one minor with DeprecationWarning
  • Existing adopter context_factory hooks continue to work via wrap-around shim
  • Removal in next minor after deprecation lands

Compatibility

Wrap-around shim translates flat → discriminated for legacy context_factory callsites. Adopters migrate at their own pace within the deprecation window.

Cross-references

🤖 Generated with Claude Code

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions