ADK for TypeScript: API Reference
    Preparing search index...

    Class AgentRegistry

    Client for interacting with the Google Cloud Agent Registry service.

    Unlike a standard REST client library, this class provides higher-level abstractions for ADK integration. It surfaces the agent registry service methods along with helper methods like getMcpToolset and getRemoteA2AAgent that automatically resolve connection details, manage OAuth authentication schemes, and handle GCP credentials to produce ready-to-use ADK components.

    Constructors

    Properties

    location: string
    projectId: string

    Methods

    • Resolves default Google Cloud credentials and returns standard headers. Automatically caches, fetches, and handles refreshing expired OAuth tokens. Injects the billing/quota project identifier x-goog-user-project if present.

      Returns Promise<Record<string, string>>

    • Parses connection interfaces list from registry metadata and returns the first match corresponding to requested protocol types and binding options.

      Parameters

      • resourceDetails: {
            interfaces?: { protocolBinding?: string; url?: string }[];
            protocols?: {
                interfaces?: { protocolBinding?: string; url?: string }[];
                protocolVersion?: string;
                type?: ProtocolType;
            }[];
        }
      • Optionalfilters: ConnectionUriFilter

      Returns ConnectionUriResult

    • Helper function to execute HTTP GET requests against the Agent Registry API. Handles path resolution, search query params compilation, and auth headers fetching.

      Type Parameters

      • T = unknown

      Parameters

      • path: string
      • Optionalparams: Record<string, string>

      Returns Promise<T>