In Agent Registry, an endpoint represents a target URL, typically a REST API, that your agents access. By registering these destinations as managed resources, you can centrally govern which external services your fleet of agents can connect to.
This document explains how to explicitly register external endpoints in the registry.
Before you begin
Before you start, set up Agent Registry. You need your project ID to perform these tasks.
To use the gcloud CLI commands in this document, make sure you have set up your Google Cloud CLI environment.
Required roles
To get the permissions that
you need to register endpoints in Agent Registry,
ask your administrator to grant you the
Agent Registry API Editor (roles/agentregistry.editor)
IAM role on the project.
For more information about granting roles, see Manage access to projects, folders, and organizations.
You might also be able to get the required permissions through custom roles or other predefined roles.
Register an endpoint
Because endpoints are custom, external destinations, use manual registration to add them to Agent Registry:
Console
In the Google Cloud console, go to Agent Registry:
From the project picker, select the Google Cloud project where you set up Agent Registry.
Select the Endpoints tab.
Click Add endpoint.
In the Endpoint details panel, enter the display name, a description, the geographic region, and the destination URL. You can test your connection to the destination URL from this panel.
Click Save.
gcloud
You create a Service resource with an endpoint-spec-type of no-spec.
Register the endpoint and define its interface connection details:
gcloud alpha agent-registry services create SERVICE_NAME \
--project=PROJECT_ID \
--location=REGION \
--display-name="DISPLAY_NAME" \
--endpoint-spec-type=no-spec \
--interfaces=url=ENDPOINT_URL,protocolBinding=PROTOCOL
Replace the following:
SERVICE_NAME: The name you want to give to your resource, for example,my-external-api.PROJECT_ID: The project ID.REGION: The registry region.DISPLAY_NAME: The human-readable name of the endpoint.ENDPOINT_URL: The target URL, for example,https://api.example.com/v1/data.PROTOCOL: The protocol binding for the interface. Valid values areHTTP_JSON,GRPC, orJSONRPC.
After the Service resource is created, Agent Registry automatically
generates a read-only Endpoint resource on the consumer side that agents and
orchestrators can discover and use.