Skip to content

[upstream-adapt] Call arbitrary Google Discovery APIs as an escape hatch #194

Closed

Description

@itsjeremyjohnson

Outcome

Power users can list/describe Discovery APIs and call methods that are not yet first-class commands, under the same account/safety controls as the rest of gog.

Why

Escape hatch for long-tail APIs without waiting for first-class commands. Upstream discovery api group.

Context

  • Source: upstream feature review of openclaw/gogcli (2026-08-11)
  • Intake rule: adapt the outcome in our architecture — do not cherry-pick or copy upstream implementation
  • Suggested triage priority: P2
  • Area: API

Non-goals for this issue

  • No prescribed flags, package layout, or upstream file ports
  • No requirement to match upstream UX naming
  • Implementation design happens during triage / agent brief

Notes for triage

Should be tightly gated by readonly/allowlists—design later.

Acceptance (triage will refine)

  • Desired user/agent-visible outcome is clear and still wanted
  • Not already fully covered by current main
  • Scope is bounded enough for an agent brief (or split)
  • Priority confirmed or re-bucketed

Activity

  1. added
    enhancementNew feature or request
    needs-triageMaintainer needs to evaluate this issue
    upstream-adaptFeature adapted from upstream openclaw/gogcli (rebuild our way)
    on Aug 11, 2026
  2. itsjeremyjohnson commented on Aug 12, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The current machine-readable schema describes first-class gog commands, and exact command-path policies plus runtime read-only protection constrain that known surface. There is no generic Discovery document loader or arbitrary-method dispatcher. No prior issue or merged pull request implements the proposed escape hatch.

    An arbitrary API dispatcher would materially change the safety model: command policies cannot name unknown provider methods, semantic-read POST allowlisting is deliberately exact and fail-closed, request-body validation would be generic, and OAuth scope expansion could bypass first-class service review. The requested "same controls" outcome does not define how those controls map to dynamic methods.

    Recommendation: retain needs-triage until the maintainer decides whether this escape hatch is compatible with the command-policy and runtime read-only ADR, and defines method allowlisting, scope acquisition, mutation opt-in, and schema/output boundaries.

  3. itsjeremyjohnson commented on Aug 13, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes only registered first-class commands, and exact command-path policies plus the runtime read-only transport guard constrain that known surface. The snapshot contains no Discovery-document loader or arbitrary-method dispatcher. No historical duplicate or prior rejection was found.

    An arbitrary API escape hatch materially changes the established safety model: dynamic provider methods do not naturally map to known command paths, semantic-read POST access is intentionally reviewed and fail-closed, generic request bodies weaken command-specific validation, and new scopes could bypass first-class service review. “Under the same controls” does not yet define an enforceable contract.

    Recommendation: retain needs-triage until the maintainer decides whether this surface is compatible with the command-policy and runtime read-only boundaries and defines method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior.

  4. itsjeremyjohnson commented on Aug 14, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and the runtime read-only transport guard constrain that known surface. The snapshot contains no Discovery-document loader or arbitrary-method dispatcher.

    No closed issue, merged pull request, or prior-rejection record duplicates the proposed escape hatch.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is intentionally reviewed and fail-closed; generic request bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” therefore does not define an enforceable safety contract. A maintainer must decide whether the surface is compatible with the recorded command-policy and runtime read-only boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema and output behavior.

    Recommendation: retain needs-triage until those safety and product-boundary decisions are recorded.

  5. itsjeremyjohnson commented on Aug 15, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and the runtime read-only transport guard constrain that known surface. The snapshot contains no Discovery-document loader or arbitrary-method dispatcher, and no historical duplicate or prior rejection was found.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is deliberately reviewed and fail-closed; generic request bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” therefore does not define an enforceable safety contract. A maintainer must decide whether the surface is compatible with the recorded boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema and output behavior.

    Recommendation: retain needs-triage until those safety and product-boundary decisions are recorded.

  6. itsjeremyjohnson commented on Aug 16, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and the runtime read-only transport guard constrain that known surface. The snapshot contains no Discovery-document loader or arbitrary-method dispatcher, and no historical duplicate or prior-rejection record was found.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is deliberately reviewed and fail-closed; generic request bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” therefore does not define an enforceable safety contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Retain needs-triage until those decisions are recorded.

  7. itsjeremyjohnson commented on Aug 16, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and the runtime read-only transport guard constrain that known surface. The snapshot contains no Discovery-document loader or arbitrary-method dispatcher, and no closed issue, merged pull request, or prior-rejection record duplicates the proposed escape hatch.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is deliberately reviewed and fail-closed; generic request bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” therefore does not define an enforceable safety contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Retain needs-triage until those decisions are recorded.

  8. itsjeremyjohnson commented on Aug 17, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and the runtime read-only transport guard constrain that known surface. The snapshot contains no Discovery-document loader or arbitrary-method dispatcher. The supplied historical snapshots contain no duplicate, and there is no prior-rejection record.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is deliberately reviewed and fail-closed; generic request bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” therefore does not define an enforceable safety contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Retain needs-triage until those decisions are recorded.

  9. itsjeremyjohnson commented on Aug 18, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and the runtime read-only transport guard constrain that known surface. The snapshot contains no Discovery-document loader or arbitrary-method dispatcher. The historical snapshots contain no duplicate, and there is no prior-rejection record.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is deliberately reviewed and fail-closed; generic request bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” therefore does not define an enforceable safety contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Retain needs-triage until those decisions are recorded.

  10. itsjeremyjohnson commented on Aug 20, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and the runtime read-only transport guard constrain that known surface. The current snapshot contains no Discovery-document loader or arbitrary-method dispatcher. The supplied histories contain no duplicate, and there is no prior-rejection record.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is deliberately reviewed and fail-closed; generic request bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” therefore does not define an enforceable safety contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Retain needs-triage until those decisions are recorded.

  11. itsjeremyjohnson commented on Aug 21, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and the runtime read-only transport guard constrain that known surface. The command and client registries contain no Discovery-document loader or arbitrary-method dispatcher. Searches of the supplied histories found no duplicate implementation; no prior-rejection record exists.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is deliberately reviewed and fail-closed; generic request bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” therefore does not define an enforceable safety contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Retain needs-triage until those decisions are recorded.

  12. itsjeremyjohnson commented on Aug 23, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command restrictions, persisted policies, and runtime read-only protection constrain that known surface. There is no Discovery-document loader or arbitrary-method dispatcher. Searches of the supplied histories found no duplicate implementation, and there is no prior-rejection record.

    Dynamic provider methods do not naturally map to known command paths; semantic-read POST access is deliberately reviewed and fail-closed; generic bodies weaken command-specific validation; and scope expansion could bypass first-class service review. “Under the same controls” is therefore not an enforceable contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Retain needs-triage until those decisions are recorded.

  13. itsjeremyjohnson commented on Aug 24, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command restrictions, persisted policies, and runtime read-only protection constrain that known surface. There is no Discovery-document loader or arbitrary-method dispatcher. Searches of schema, API client, policy, and runtime-readonly concepts and the supplied closed-issue and merged-PR histories found no duplicate implementation; no prior-rejection record exists.

    Dynamic provider methods do not naturally map to known command paths, semantic-read POST access is deliberately reviewed and fail-closed, generic bodies weaken command-specific validation, and scope expansion could bypass first-class service review. “Under the same controls” is therefore not yet an enforceable contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Keep this in needs-triage until those decisions are recorded.

  14. itsjeremyjohnson commented on Aug 25, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Triage Notes

    The machine-readable schema describes registered first-class commands. Exact command-path restrictions, persisted policies, and runtime read-only protection constrain that known surface. There is no Discovery-document loader or arbitrary-method dispatcher. Concept searches of schema, API client, policy, runtime-readonly, and the supplied histories found no duplicate implementation, and there is no prior-rejection record.

    Dynamic provider methods do not naturally map to known command paths, semantic-read POST access is deliberately reviewed and fail-closed, generic bodies weaken command-specific validation, and scope expansion could bypass first-class service review. “Under the same controls” is therefore not yet an enforceable contract. A maintainer must decide whether this surface is compatible with the recorded safety boundaries and define method allowlisting, scope acquisition, mutation opt-in, and schema/output behavior. Retain needs-triage until those decisions are recorded.

  15. added and removed
    needs-triageMaintainer needs to evaluate this issue
    on Sep 15, 2026
  16. itsjeremyjohnson commented on Sep 15, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    This was generated by AI during triage.

    Agent Brief

    Category: enhancement
    Summary: Power users can list/describe Discovery APIs and call methods that are not yet first-class commands, under the same account/safety controls as the rest of gog.

    Current behavior:
    Fork lacks this upstream-adapt capability (or only partial primitives exist). Prior triage notes on this issue document the current surface.

    Desired behavior:
    Power users can list/describe Discovery APIs and call methods that are not yet first-class commands, under the same account/safety controls as the rest of gog.

    Key interfaces:

    • Existing gog CLI command surface and auth/safety controls
    • Google API surface named in the issue outcome
    • Script-friendly machine-readable output consistent with sibling commands

    Acceptance criteria:

    • Outcome in the issue body is met under this fork’s architecture (adapt, do not cherry-pick upstream patches)
    • Behavior is covered by tests or documented manual verification
    • Safety/auth constraints match the rest of gog

    Out of scope:

    • Copying upstream implementation wholesale
    • Unrelated Google services

    Why not delegable

    Product priority and contract semantics are still open (what ships first, audit/lifecycle meaning, and whether this fork needs the capability at all). An agent should not invent those decisions. Once Jeremy ranks or rejects this upstream-adapt item, retarget to ready-for-agent or wontfix.

    Prior triage notes remain the technical baseline; this comment only advances state out of needs-triage.

  17. itsjeremyjohnson commented on Oct 12, 2026

    @itsjeremyjohnson
    CollaboratorAuthor

    Closing as obsolete (GitHub sweep 2026-10-12). This [upstream-adapt] request asked to port an upstream steipete/gogcli CLI feature into our gog CLI. That CLI was retired in 91336b7 (#269); main builds only gog-mcp, so the command surface this request targets no longer exists. gog-mcp's pinned API catalog (internal/googlecatalog/manifest.json) already exposes the underlying Google method(s) (1,108 pinned Google Discovery methods across 29 services; this is the discovery escape hatch) through --discovery=compact --api-catalog, subject to grants. New needs on the MCP side are filed as MCP-scoped issues (see #271, #273, #274, #278).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestready-for-humanRequires human implementationupstream-adaptFeature adapted from upstream openclaw/gogcli (rebuild our way)

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions