Skip to content

feat(gateway): repo-targeted Charter brief tool for multi-repo agents #49

@stackbilt-admin

Description

@stackbilt-admin

Context

charter#116 defines the integration goal: expose repo-targeted Charter brief retrieval through stackbilt-mcp-gateway for multi-repo agent workflows.

Charter-side charter_brief exists in per-repo charter serve, but gateway execution ownership belongs here.

Goal

Add a gateway tool that returns a Charter brief for an explicit target repo under tenant auth constraints.

Proposed contract (v1)

Tool: stackbilt_repo_brief

Input:

  • repo: string (for example Stackbilt-dev/charter)
  • optional freshness controls (refresh, ttlMinutes) only if needed after initial rollout

Output:

  • canonical brief payload from Charter surface
  • source metadata (repo, generatedAt, freshness hints)

Scope

  1. Repo targeting and tenant-to-repo authorization using existing gateway OAuth model.
  2. Brief retrieval strategy that avoids unnecessary cold start costs.
  3. Contract tests for:
    • authorized repo access
    • unauthorized repo rejection
    • missing repo / missing Charter context behavior
    • deterministic payload shape

Dependencies / links

Notes

Keep this issue as execution source-of-truth in gateway repo. Charter #116 remains the consumer-side contract and cross-repo coordination issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions