[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6990BKNXJHGRWDGDGP0EG5F":3,"skill-same:01M6990BKNXJHGRWDGDGP0EG5F":82},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":26,"publishedAt":46,"linkOnly":47,"markdownContent":48,"markdownBody":49,"frontMatter":50,"refName":58,"commitSha":59,"skillDirectory":60,"forksCount":61,"repositoryHtmlUrl":62,"repositoryHomepageUrl":63,"ownerHtmlUrl":64,"ownerBlogUrl":65,"ownerDescription":66,"updatedAt":67,"install":68,"resources":81},"01M6990BKNXJHGRWDGDGP0EG5F","google-agents-cli-publish",null,"This skill should be used when the user wants to \"publish an agent\", \"publish my ADK agent\", \"register an agent with Gemini\", \"publish to Gemini\" (formerly Gemini Enterprise), or needs guidance on the agents-cli publish gemini command. Also use when the user wants to \"manage agents in Agent Registry\", \"list\u002Fupdate\u002Fdelete registered agents\", or \"register an MCP server\". Covers ADK vs A2A registration modes, programmatic and interactive usage, flag reference, auto-detection from deployment metadata, Agent Registry fleet management, and troubleshooting. Part of the agents-cli skills suite. Do NOT use for deployment (use google-agents-cli-deploy).","google\u002Fagents-cli","google","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F1342004?v=4","01M698VYEFDM0VJBZDYYJ2T83S","Google","01M698ZVGDEBGAXVZGNKKKCRBQ",6349,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli\u002Fblob\u002Fmain\u002Fskills\u002Fgoogle-agents-cli-publish\u002FSKILL.md",[18,23],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000011","运维与部署","SCENARIO","使用场景",{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发",[27,28,9,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45],"cli","google agents cli publish","publish","registry","fleet","suite","install","update","command","apache","delete","server","agent registry","mcp server","auto","uv","programmatic","MCP","adk","2026-11-10 10:12:30",false,"---\nname: google-agents-cli-publish\ndescription: >\n  This skill should be used when the user wants to \"publish an agent\",\n  \"publish my ADK agent\", \"register an agent with Gemini\",\n  \"publish to Gemini\" (formerly Gemini Enterprise), or needs guidance on\n  the agents-cli publish gemini command.\n  Also use when the user wants to \"manage agents in Agent Registry\",\n  \"list\u002Fupdate\u002Fdelete registered agents\", or \"register an MCP server\".\n  Covers ADK vs A2A registration modes, programmatic and interactive usage,\n  flag reference, auto-detection from deployment metadata, Agent Registry\n  fleet management, and troubleshooting.\n  Part of the agents-cli skills suite.\n  Do NOT use for deployment (use google-agents-cli-deploy).\nmetadata:\n  author: Google\n  license: Apache-2.0\n  version: 1.14.0\n  requires:\n    bins:\n      - agents-cli\n    install: \"uv tool install google-agents-cli\"\n---\n\n# Gemini Registration\n\n> **Requires:** A deployed agent. For Agent Runtime in Gemini platform, `deployment_metadata.json` (created by `agents-cli deploy`) enables auto-detection. For Cloud Run or GKE, provide the agent card URL and flags directly.\n\n## Prerequisites\n\n1. **Agent must be deployed** — the agent must be running and reachable\n2. **Gemini app must exist** — Create one in the Google Cloud console before registering\n3. **`deployment_metadata.json`** (Agent Runtime only) — Created automatically by `agents-cli deploy`; contains the Agent Runtime ID, deployment target, the A2A flag, and the agent directory\n4. **Text-based agent** — Live\u002Fvoice (bidi) agents are **not supported** by the Gemini app, which has no `\u002Frun_live` transport. Register a text-based agent instead.\n\n## Required Permissions for A2A on Cloud Run\n\n- **`roles\u002Frun.servicesInvoker`** granted to the Discovery Engine service account (`service-\u003CPROJECT_NUMBER>@gcp-sa-discoveryengine.iam.gserviceaccount.com`) on the Cloud Run service.\n\n---\n\n## Registration Modes\n\n### A2A Registration\n\nEvery scaffolded agent serves the Agent-to-Agent protocol. A2A is the default — and only — registration type on **Cloud Run** and **GKE** (no reasoning engine to invoke natively). It also works on **Agent Runtime** via `--registration-type a2a`. For an ADK agent there the CLI warns against it, because the Gemini app can invoke Agent Runtime natively via `:streamQuery` — prefer ADK registration in that case. For an agent built on another framework there is no ADK app to invoke natively, so A2A is the right mode on every target and the warning is expected. Pass the agent card URL and the command fetches the card and registers it; display name and description default to the card's `name`\u002F`description`.\n\n```bash\n# A2A on Cloud Run \u002F GKE. The card path depends on the project's language:\n#   Python -> \u002Fa2a\u002F{app_name}\u002F.well-known\u002Fagent-card.json\n#   Go     -> \u002F.well-known\u002Fagent-card.json\nagents-cli publish gemini \\\n  --agent-card-url https:\u002F\u002Fmy-service-abc123.us-east1.run.app\u002Fa2a\u002Fapp\u002F.well-known\u002Fagent-card.json \\\n  --gemini-app-id projects\u002F123456\u002Flocations\u002Fglobal\u002Fcollections\u002Fdefault_collection\u002Fengines\u002Fmy-app\n```\n\nPass `--display-name` \u002F `--description` to override the card defaults. On Agent Runtime, the card URL auto-builds from `deployment_metadata.json` if you omit `--agent-card-url`.\n\n### ADK Registration (default on Agent Runtime)\n\n> **ADK projects only.** The agent must be deployed to Agent Runtime as an ADK app, since\n> registration invokes it through `:streamQuery`. An agent on another framework registers over\n> A2A, so deploy it to Cloud Run or GKE and publish from there.\n\nThis is the **default and recommended registration for ADK agents on Agent Runtime**: the Gemini app invokes the agent natively via `:streamQuery` on its reasoning engine resource, authenticating end-to-end. Under the hood, `:streamQuery` dispatches to the `AdkApp`'s `streaming_agent_run_with_events` method — when debugging an ADK invocation, search the runtime's `reasoning_engine_stderr` logs for that method name to trace the failure. It's also the path to use when the agent needs an OAuth authorization (`--authorization-id`). The agent is registered directly via its reasoning engine resource name; no agent card URL is needed.\n\n```bash\nagents-cli publish gemini \\\n  --registration-type adk \\\n  --agent-runtime-id projects\u002F123456\u002Flocations\u002Fus-east1\u002FreasoningEngines\u002F789 \\\n  --gemini-app-id projects\u002F123456\u002Flocations\u002Fglobal\u002Fcollections\u002Fdefault_collection\u002Fengines\u002Fmy-app \\\n  --display-name \"My Agent\" \\\n  --description \"Handles customer queries\" \\\n  --tool-description \"Answers questions about products\"\n```\n\n---\n\n## Programmatic Mode (CI\u002FCD)\n\nThe command is non-interactive by default — pass all required values via flags or environment variables. This makes it safe for CI\u002FCD pipelines.\n\n### Via flags\n\n```bash\nagents-cli publish gemini \\\n  --agent-runtime-id \"$AGENT_RUNTIME_ID\" \\\n  --gemini-app-id \"$GEMINI_APP_ID\" \\\n  --display-name \"Production Agent\" \\\n  --registration-type adk\n```\n\n### Via environment variables\n\nMost flags have an env var alternative (`--metadata-file`, `--interactive`, and `--list` do not):\n\n```bash\nexport AGENT_RUNTIME_ID=\"projects\u002F123456\u002Flocations\u002Fus-east1\u002FreasoningEngines\u002F789\"\nexport GEMINI_APP_ID=\"projects\u002F123456\u002Flocations\u002Fglobal\u002Fcollections\u002Fdefault_collection\u002Fengines\u002Fmy-app\"\nexport GEMINI_DISPLAY_NAME=\"Production Agent\"\nexport GEMINI_DESCRIPTION=\"Handles customer queries\"\n\nagents-cli publish gemini\n```\n\n---\n\n## Interactive Mode (`--interactive`)\n\nPass `--interactive` (or `-i`) to be guided through any missing values with interactive prompts. The command will list available Gemini apps, offer to auto-detect the Agent Runtime ID from metadata, and prompt for display name and description.\n\n```bash\nagents-cli publish gemini --interactive\n```\n\n---\n\n## Complete Flag Reference\n\n| Flag | Env Var | Description |\n|------|---------|-------------|\n| `--agent-runtime-id` | `AGENT_RUNTIME_ID` | Agent Runtime resource name (auto-detected from `deployment_metadata.json`) |\n| `--gemini-app-id` | `GEMINI_APP_ID` | Gemini app full resource name |\n| `--display-name` | `GEMINI_DISPLAY_NAME` | Display name in Gemini |\n| `--description` | `GEMINI_DESCRIPTION` | Agent description |\n| `--tool-description` | `GEMINI_TOOL_DESCRIPTION` | Tool description (ADK mode only, defaults to description) |\n| `--registration-type` | `REGISTRATION_TYPE` | `adk` or `a2a` (defaults to `adk` for an ADK agent on Agent Runtime, `a2a` everywhere else, including any non-ADK framework) |\n| `--agent-card-url` | `AGENT_CARD_URL` | Agent card URL for A2A registration |\n| `--deployment-target` | `DEPLOYMENT_TARGET` | `agent_runtime`, `cloud_run`, or `gke` (sets the default registration type — ADK on Agent Runtime, A2A on Cloud Run \u002F GKE — and the A2A auth method) |\n| `--project-id` | `GOOGLE_CLOUD_PROJECT` | GCP project ID for billing |\n| `--project-number` | `PROJECT_NUMBER` | GCP project number (used for Gemini app lookup) |\n| `--authorization-id` | `GEMINI_AUTHORIZATION_ID` | OAuth authorization resource name |\n| `--metadata-file` | — | Path to deployment metadata (default: `deployment_metadata.json`) |\n| `--interactive` \u002F `-i` | — | Enable interactive prompts |\n| `--list` | — | List Gemini apps in the current project and exit |\n\nThe old names still work as hidden aliases: `publish gemini-enterprise`, `--gemini-enterprise-app-id`, and the `ID` \u002F `GEMINI_ENTERPRISE_APP_ID` env vars. Projects generated by earlier versions call `publish gemini-enterprise` from `make publish-gemini-enterprise`; newer Go and Java projects keep that target and add `make publish-gemini` as an alias.\n\n---\n\n## Auto-Detection from Metadata\n\nWhen `deployment_metadata.json` exists, the command automatically:\n\n- Reads the **Agent Runtime ID** (`remote_agent_runtime_id`)\n- Determines the **registration type**: defaults to **ADK** (native `:streamQuery`) on **Agent Runtime**, and **A2A** on **Cloud Run \u002F GKE** (which have no reasoning engine). A project scaffolded with another framework serves no ADK app, so it defaults to **A2A** on every target. Override with `--registration-type`.\n- Determines the **deployment target** for authentication\n\nThis means that for the simplest case (an ADK agent on Agent Runtime, registered as ADK), you only need to provide the Gemini app ID:\n\n```bash\nagents-cli publish gemini \\\n  --gemini-app-id projects\u002F123456\u002Flocations\u002Fglobal\u002Fcollections\u002Fdefault_collection\u002Fengines\u002Fmy-app\n```\n\n---\n\n## Agent Registry (agents and MCP servers)\n\nAgent Registry (Preview) is the Google Cloud fleet-wide catalog of **agents and MCP servers**, separate from a Gemini app.\nAgents deployed to a managed runtime (Agent Runtime in Gemini\nplatform) are **auto-registered** — no extra step after `agents-cli deploy`.\nFor A2A projects, `agents-cli deploy` also stores the served agent card on the\nengine, so the entry is listed as an A2A agent with the card's skills.\nManage them with `gcloud` (requires `roles\u002Fagentregistry.editor`):\n\n```bash\n# List \u002F inspect agents\ngcloud agent-registry agents list --project PROJECT --location LOCATION\ngcloud agent-registry agents describe AGENT_NAME\n\n# Update endpoint\u002Fmetadata — edit the Service resource, not the Agent\ngcloud agent-registry services update AGENT_NAME \\\n  --display-name \"...\" --description \"...\" \\\n  --interfaces \"url=ENDPOINT_URL,protocolBinding=http-json\"\n\n# Register an external MCP server: not auto-introspected, so upload a\n# toolspec.json (its tools\u002Flist response, max 10 KB). No us\u002Feu multi-region.\ngcloud agent-registry services create SERVER_NAME --location=LOCATION \\\n  --mcp-server-spec-type=tool-spec --mcp-server-spec-content=toolspec.json \\\n  --interfaces=\"url=SERVER_URL,protocolBinding=jsonrpc\"  # or http-json, grpc\n\n# Remove: delete the underlying runtime agent (auto-registered) OR, for\n# manually registered agents\u002Fservers, delete the Service resource\ngcloud agent-registry services delete NAME\n```\n\nTerraform: `google_agent_registry_service` with an `mcp_server_spec` block.\n\nDocs: https:\u002F\u002Fdocs.cloud.google.com\u002Fagent-registry\u002Fmanage-agents · https:\u002F\u002Fdocs.cloud.google.com\u002Fagent-registry\u002Fregister-mcp-servers\n\n---\n\n## Troubleshooting\n\n| Issue | Solution |\n|-------|----------|\n| \"Session not found\" after registration | Python projects on `google-cloud-aiplatform` \u003C= 1.128.0 hit a known SDK bug — upgrade it, redeploy, then re-register |\n| `--registration-type is required` | Non-interactive mode needs `--registration-type` when no `deployment_metadata.json` exists |\n| \"Gemini app ID is required\" | Provide `--gemini-app-id` or set the `GEMINI_APP_ID` env var |\n| Re-publishing the same agent | Registration is idempotent — re-running updates the existing registration in place instead of creating a duplicate |\n| HTTP 403 on registration | Check that your account has Discovery Engine Editor permissions on the project that hosts the Gemini app |\n| Debugging ADK invocation failures on Agent Runtime | The Gemini app calls the agent via the `AdkApp`'s `streaming_agent_run_with_events` method (the native `:streamQuery` contract). Grep the runtime's `reasoning_engine_stderr` logs for `streaming_agent_run_with_events` to find the underlying error |\n| \"Could not fetch agent card\" | Verify the agent is running and the URL is correct; for Cloud Run, ensure `gcloud auth login` is done. A Live\u002Fvoice agent drops its A2A card and cannot be published — the Gemini app does not support Live agents |\n\n---\n\n## Related Skills\n\n- `\u002Fgoogle-agents-cli-deploy` — Deployment targets, CI\u002FCD pipelines, and production workflows (also covers Agent Gateway governed ingress\u002Fegress and Semantic Governance awareness)\n- `\u002Fgoogle-agents-cli-workflow` — Development workflow, coding guidelines, and operational rules\n- `\u002Fgoogle-agents-cli-scaffold` — Project creation and enhancement with `agents-cli scaffold create` \u002F `scaffold enhance`\n","# Gemini Registration\n\n> **Requires:** A deployed agent. For Agent Runtime in Gemini platform, `deployment_metadata.json` (created by `agents-cli deploy`) enables auto-detection. For Cloud Run or GKE, provide the agent card URL and flags directly.\n\n## Prerequisites\n\n1. **Agent must be deployed** — the agent must be running and reachable\n2. **Gemini app must exist** — Create one in the Google Cloud console before registering\n3. **`deployment_metadata.json`** (Agent Runtime only) — Created automatically by `agents-cli deploy`; contains the Agent Runtime ID, deployment target, the A2A flag, and the agent directory\n4. **Text-based agent** — Live\u002Fvoice (bidi) agents are **not supported** by the Gemini app, which has no `\u002Frun_live` transport. Register a text-based agent instead.\n\n## Required Permissions for A2A on Cloud Run\n\n- **`roles\u002Frun.servicesInvoker`** granted to the Discovery Engine service account (`service-\u003CPROJECT_NUMBER>@gcp-sa-discoveryengine.iam.gserviceaccount.com`) on the Cloud Run service.\n\n---\n\n## Registration Modes\n\n### A2A Registration\n\nEvery scaffolded agent serves the Agent-to-Agent protocol. A2A is the default — and only — registration type on **Cloud Run** and **GKE** (no reasoning engine to invoke natively). It also works on **Agent Runtime** via `--registration-type a2a`. For an ADK agent there the CLI warns against it, because the Gemini app can invoke Agent Runtime natively via `:streamQuery` — prefer ADK registration in that case. For an agent built on another framework there is no ADK app to invoke natively, so A2A is the right mode on every target and the warning is expected. Pass the agent card URL and the command fetches the card and registers it; display name and description default to the card's `name`\u002F`description`.\n\n```bash\n# A2A on Cloud Run \u002F GKE. The card path depends on the project's language:\n#   Python -> \u002Fa2a\u002F{app_name}\u002F.well-known\u002Fagent-card.json\n#   Go     -> \u002F.well-known\u002Fagent-card.json\nagents-cli publish gemini \\\n  --agent-card-url https:\u002F\u002Fmy-service-abc123.us-east1.run.app\u002Fa2a\u002Fapp\u002F.well-known\u002Fagent-card.json \\\n  --gemini-app-id projects\u002F123456\u002Flocations\u002Fglobal\u002Fcollections\u002Fdefault_collection\u002Fengines\u002Fmy-app\n```\n\nPass `--display-name` \u002F `--description` to override the card defaults. On Agent Runtime, the card URL auto-builds from `deployment_metadata.json` if you omit `--agent-card-url`.\n\n### ADK Registration (default on Agent Runtime)\n\n> **ADK projects only.** The agent must be deployed to Agent Runtime as an ADK app, since\n> registration invokes it through `:streamQuery`. An agent on another framework registers over\n> A2A, so deploy it to Cloud Run or GKE and publish from there.\n\nThis is the **default and recommended registration for ADK agents on Agent Runtime**: the Gemini app invokes the agent natively via `:streamQuery` on its reasoning engine resource, authenticating end-to-end. Under the hood, `:streamQuery` dispatches to the `AdkApp`'s `streaming_agent_run_with_events` method — when debugging an ADK invocation, search the runtime's `reasoning_engine_stderr` logs for that method name to trace the failure. It's also the path to use when the agent needs an OAuth authorization (`--authorization-id`). The agent is registered directly via its reasoning engine resource name; no agent card URL is needed.\n\n```bash\nagents-cli publish gemini \\\n  --registration-type adk \\\n  --agent-runtime-id projects\u002F123456\u002Flocations\u002Fus-east1\u002FreasoningEngines\u002F789 \\\n  --gemini-app-id projects\u002F123456\u002Flocations\u002Fglobal\u002Fcollections\u002Fdefault_collection\u002Fengines\u002Fmy-app \\\n  --display-name \"My Agent\" \\\n  --description \"Handles customer queries\" \\\n  --tool-description \"Answers questions about products\"\n```\n\n---\n\n## Programmatic Mode (CI\u002FCD)\n\nThe command is non-interactive by default — pass all required values via flags or environment variables. This makes it safe for CI\u002FCD pipelines.\n\n### Via flags\n\n```bash\nagents-cli publish gemini \\\n  --agent-runtime-id \"$AGENT_RUNTIME_ID\" \\\n  --gemini-app-id \"$GEMINI_APP_ID\" \\\n  --display-name \"Production Agent\" \\\n  --registration-type adk\n```\n\n### Via environment variables\n\nMost flags have an env var alternative (`--metadata-file`, `--interactive`, and `--list` do not):\n\n```bash\nexport AGENT_RUNTIME_ID=\"projects\u002F123456\u002Flocations\u002Fus-east1\u002FreasoningEngines\u002F789\"\nexport GEMINI_APP_ID=\"projects\u002F123456\u002Flocations\u002Fglobal\u002Fcollections\u002Fdefault_collection\u002Fengines\u002Fmy-app\"\nexport GEMINI_DISPLAY_NAME=\"Production Agent\"\nexport GEMINI_DESCRIPTION=\"Handles customer queries\"\n\nagents-cli publish gemini\n```\n\n---\n\n## Interactive Mode (`--interactive`)\n\nPass `--interactive` (or `-i`) to be guided through any missing values with interactive prompts. The command will list available Gemini apps, offer to auto-detect the Agent Runtime ID from metadata, and prompt for display name and description.\n\n```bash\nagents-cli publish gemini --interactive\n```\n\n---\n\n## Complete Flag Reference\n\n| Flag | Env Var | Description |\n|------|---------|-------------|\n| `--agent-runtime-id` | `AGENT_RUNTIME_ID` | Agent Runtime resource name (auto-detected from `deployment_metadata.json`) |\n| `--gemini-app-id` | `GEMINI_APP_ID` | Gemini app full resource name |\n| `--display-name` | `GEMINI_DISPLAY_NAME` | Display name in Gemini |\n| `--description` | `GEMINI_DESCRIPTION` | Agent description |\n| `--tool-description` | `GEMINI_TOOL_DESCRIPTION` | Tool description (ADK mode only, defaults to description) |\n| `--registration-type` | `REGISTRATION_TYPE` | `adk` or `a2a` (defaults to `adk` for an ADK agent on Agent Runtime, `a2a` everywhere else, including any non-ADK framework) |\n| `--agent-card-url` | `AGENT_CARD_URL` | Agent card URL for A2A registration |\n| `--deployment-target` | `DEPLOYMENT_TARGET` | `agent_runtime`, `cloud_run`, or `gke` (sets the default registration type — ADK on Agent Runtime, A2A on Cloud Run \u002F GKE — and the A2A auth method) |\n| `--project-id` | `GOOGLE_CLOUD_PROJECT` | GCP project ID for billing |\n| `--project-number` | `PROJECT_NUMBER` | GCP project number (used for Gemini app lookup) |\n| `--authorization-id` | `GEMINI_AUTHORIZATION_ID` | OAuth authorization resource name |\n| `--metadata-file` | — | Path to deployment metadata (default: `deployment_metadata.json`) |\n| `--interactive` \u002F `-i` | — | Enable interactive prompts |\n| `--list` | — | List Gemini apps in the current project and exit |\n\nThe old names still work as hidden aliases: `publish gemini-enterprise`, `--gemini-enterprise-app-id`, and the `ID` \u002F `GEMINI_ENTERPRISE_APP_ID` env vars. Projects generated by earlier versions call `publish gemini-enterprise` from `make publish-gemini-enterprise`; newer Go and Java projects keep that target and add `make publish-gemini` as an alias.\n\n---\n\n## Auto-Detection from Metadata\n\nWhen `deployment_metadata.json` exists, the command automatically:\n\n- Reads the **Agent Runtime ID** (`remote_agent_runtime_id`)\n- Determines the **registration type**: defaults to **ADK** (native `:streamQuery`) on **Agent Runtime**, and **A2A** on **Cloud Run \u002F GKE** (which have no reasoning engine). A project scaffolded with another framework serves no ADK app, so it defaults to **A2A** on every target. Override with `--registration-type`.\n- Determines the **deployment target** for authentication\n\nThis means that for the simplest case (an ADK agent on Agent Runtime, registered as ADK), you only need to provide the Gemini app ID:\n\n```bash\nagents-cli publish gemini \\\n  --gemini-app-id projects\u002F123456\u002Flocations\u002Fglobal\u002Fcollections\u002Fdefault_collection\u002Fengines\u002Fmy-app\n```\n\n---\n\n## Agent Registry (agents and MCP servers)\n\nAgent Registry (Preview) is the Google Cloud fleet-wide catalog of **agents and MCP servers**, separate from a Gemini app.\nAgents deployed to a managed runtime (Agent Runtime in Gemini\nplatform) are **auto-registered** — no extra step after `agents-cli deploy`.\nFor A2A projects, `agents-cli deploy` also stores the served agent card on the\nengine, so the entry is listed as an A2A agent with the card's skills.\nManage them with `gcloud` (requires `roles\u002Fagentregistry.editor`):\n\n```bash\n# List \u002F inspect agents\ngcloud agent-registry agents list --project PROJECT --location LOCATION\ngcloud agent-registry agents describe AGENT_NAME\n\n# Update endpoint\u002Fmetadata — edit the Service resource, not the Agent\ngcloud agent-registry services update AGENT_NAME \\\n  --display-name \"...\" --description \"...\" \\\n  --interfaces \"url=ENDPOINT_URL,protocolBinding=http-json\"\n\n# Register an external MCP server: not auto-introspected, so upload a\n# toolspec.json (its tools\u002Flist response, max 10 KB). No us\u002Feu multi-region.\ngcloud agent-registry services create SERVER_NAME --location=LOCATION \\\n  --mcp-server-spec-type=tool-spec --mcp-server-spec-content=toolspec.json \\\n  --interfaces=\"url=SERVER_URL,protocolBinding=jsonrpc\"  # or http-json, grpc\n\n# Remove: delete the underlying runtime agent (auto-registered) OR, for\n# manually registered agents\u002Fservers, delete the Service resource\ngcloud agent-registry services delete NAME\n```\n\nTerraform: `google_agent_registry_service` with an `mcp_server_spec` block.\n\nDocs: https:\u002F\u002Fdocs.cloud.google.com\u002Fagent-registry\u002Fmanage-agents · https:\u002F\u002Fdocs.cloud.google.com\u002Fagent-registry\u002Fregister-mcp-servers\n\n---\n\n## Troubleshooting\n\n| Issue | Solution |\n|-------|----------|\n| \"Session not found\" after registration | Python projects on `google-cloud-aiplatform` \u003C= 1.128.0 hit a known SDK bug — upgrade it, redeploy, then re-register |\n| `--registration-type is required` | Non-interactive mode needs `--registration-type` when no `deployment_metadata.json` exists |\n| \"Gemini app ID is required\" | Provide `--gemini-app-id` or set the `GEMINI_APP_ID` env var |\n| Re-publishing the same agent | Registration is idempotent — re-running updates the existing registration in place instead of creating a duplicate |\n| HTTP 403 on registration | Check that your account has Discovery Engine Editor permissions on the project that hosts the Gemini app |\n| Debugging ADK invocation failures on Agent Runtime | The Gemini app calls the agent via the `AdkApp`'s `streaming_agent_run_with_events` method (the native `:streamQuery` contract). Grep the runtime's `reasoning_engine_stderr` logs for `streaming_agent_run_with_events` to find the underlying error |\n| \"Could not fetch agent card\" | Verify the agent is running and the URL is correct; for Cloud Run, ensure `gcloud auth login` is done. A Live\u002Fvoice agent drops its A2A card and cannot be published — the Gemini app does not support Live agents |\n\n---\n\n## Related Skills\n\n- `\u002Fgoogle-agents-cli-deploy` — Deployment targets, CI\u002FCD pipelines, and production workflows (also covers Agent Gateway governed ingress\u002Fegress and Semantic Governance awareness)\n- `\u002Fgoogle-agents-cli-workflow` — Development workflow, coding guidelines, and operational rules\n- `\u002Fgoogle-agents-cli-scaffold` — Project creation and enhancement with `agents-cli scaffold create` \u002F `scaffold enhance`\n",{"name":5,"metadata":51,"description":57},{"author":12,"license":15,"version":52,"requires":53},"1.14.0",{"bins":54,"install":56},[55],"agents-cli","uv tool install google-agents-cli","This skill should be used when the user wants to \"publish an agent\", \"publish my ADK agent\", \"register an agent with Gemini\", \"publish to Gemini\" (formerly Gemini Enterprise), or needs guidance on the agents-cli publish gemini command. Also use when the user wants to \"manage agents in Agent Registry\", \"list\u002Fupdate\u002Fdelete registered agents\", or \"register an MCP server\". Covers ADK vs A2A registration modes, programmatic and interactive usage, flag reference, auto-detection from deployment metadata, Agent Registry fleet management, and troubleshooting. Part of the agents-cli skills suite. Do NOT use for deployment (use google-agents-cli-deploy).\n","main","6eedbdc2f44c388cbfc5f305eb83b9924cfefebb","skills\u002Fgoogle-agents-cli-publish",731,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli","https:\u002F\u002Fgoogle.github.io\u002Fagents-cli\u002F","https:\u002F\u002Fgithub.com\u002Fgoogle","https:\u002F\u002Fopensource.google\u002F","Google ❤️ Open Source","2026-11-12 23:04:58",{"source":8,"skillName":5,"commands":69,"prompt":79,"zipAvailable":80},[70,73,76],{"tool":71,"command":72},"npx","npx skills add google\u002Fagents-cli --skill google-agents-cli-publish",{"tool":74,"command":75},"bunx","bunx skills add google\u002Fagents-cli --skill google-agents-cli-publish",{"tool":77,"command":78},"pnpm","pnpm dlx skills add google\u002Fagents-cli --skill google-agents-cli-publish","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli\u002Fblob\u002Fmain\u002Fskills\u002Fgoogle-agents-cli-publish\u002FSKILL.md",true,[],[83,111,133,140,165,184],{"skillNo":84,"name":85,"nameZh":6,"description":86,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":87,"categories":88,"keywords":96,"publishedAt":46},"01M6990ZGJV6CHR6CZK81S58CN","google-agents-cli-workflow","This skill should be used when the user wants to \"develop an agent\", \"build an agent using ADK\", \"run the agent locally\", \"debug agent code\", \"test an agent\", \"deploy an agent\", \"publish an agent\", \"monitor an agent\", or needs the ADK (Agent Development Kit) development lifecycle and coding guidelines. Entrypoint for building ADK agents. Always active — provides the full workflow (scaffold, build, evaluate, deploy, publish, observe), code preservation rules, model selection guidance, and troubleshooting steps for ADK or any agent development.","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli\u002Fblob\u002Fmain\u002Fsrc\u002Fgoogle\u002Fagents\u002Fcli\u002Fskills\u002Fdata\u002Fgoogle-agents-cli-workflow\u002FSKILL.md",[89,90,91],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":92,"categoryName":93,"taxonomyType":94,"taxonomyTypeDesc":95},"01JBSEEDCAT000000000000030","开发工程师","PROFESSION","适用职业",[9,97,27,98,45,99,100,101,102,103,104,105,106,42,107,108,29,36,109,110],"google agents cli workflow","workflow","agent development kit","agent development","development lifecycle","model","observe","selection","model selection","kit","code","debug agent","active","run",{"skillNo":112,"name":113,"nameZh":6,"description":114,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":115,"categories":116,"keywords":119,"publishedAt":46},"01M6990XH0S4MNS7YTDAMNAAEW","google-agents-cli-scaffold","This skill should be used when the user wants to \"create an agent project\", \"start a new ADK project\", \"build me a new agent\", \"add CI\u002FCD to my project\", \"add deployment\", \"enhance my project\", or \"upgrade my project\". Part of the agents-cli skills suite. Covers `agents-cli scaffold create`, `scaffold enhance`, and `scaffold upgrade` commands, template options, deployment targets, and the prototype-first workflow. Do NOT use for writing agent code (ADK projects: use google-agents-cli-adk-code) or deployment operations (use google-agents-cli-deploy).","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli\u002Fblob\u002Fmain\u002Fsrc\u002Fgoogle\u002Fagents\u002Fcli\u002Fskills\u002Fdata\u002Fgoogle-agents-cli-scaffold\u002FSKILL.md",[117,118],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},[120,9,27,121,45,122,123,124,125,126,42,127,98,107,128,129,36,130,131,132],"google agents cli scaffold","scaffold","writing","projects","new agent","project","ci","upgrade","create","me","options","template","CI\u002FCD",{"skillNo":134,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":135,"categories":136,"keywords":139,"publishedAt":46},"01M6990VP634A9G6052KQCZNYJ","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli\u002Fblob\u002Fmain\u002Fsrc\u002Fgoogle\u002Fagents\u002Fcli\u002Fskills\u002Fdata\u002Fgoogle-agents-cli-publish\u002FSKILL.md",[137,138],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},[9,27,28,29,45,44,43,42,41,40,39,38,37,36,35,34,33,32,31,30],{"skillNo":141,"name":142,"nameZh":6,"description":143,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":144,"categories":145,"keywords":154,"publishedAt":46},"01M6990SFDY0JKXYP921BKRJYE","google-agents-cli-observability","This skill should be used when the user wants to \"set up tracing\", \"monitor my agent\", \"configure logging\", \"add observability\", \"debug production traffic\", or needs guidance on monitoring deployed agents, including ADK (Agent Development Kit) agents. Covers Cloud Trace, prompt-response logging, BigQuery Agent Analytics, third-party integrations (AgentOps, Phoenix, MLflow, etc.), and troubleshooting. Part of the agents-cli skills suite. Do NOT use for deployment setup (use google-agents-cli-deploy) or API code patterns (use google-agents-cli-adk-code).","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli\u002Fblob\u002Fmain\u002Fsrc\u002Fgoogle\u002Fagents\u002Fcli\u002Fskills\u002Fdata\u002Fgoogle-agents-cli-observability\u002FSKILL.md",[146,149,150,151],{"categoryNo":147,"categoryName":148,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000013","分析与可视化",{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":92,"categoryName":93,"taxonomyType":94,"taxonomyTypeDesc":95},{"categoryNo":152,"categoryName":153,"taxonomyType":94,"taxonomyTypeDesc":95},"01JBSEEDCAT000000000000033","数据分析师",[9,27,155,156,45,99,100,157,158,106,42,159,160,161,107,162,163,36,33,164],"google agents cli observability","observability","SET","up","traffic","configure","code patterns","api","monitoring","mlflow",{"skillNo":166,"name":167,"nameZh":6,"description":168,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":169,"categories":170,"keywords":173,"publishedAt":46},"01M6990PXZ0S6NHYV8PGGVFT6E","google-agents-cli-eval","This skill should be used when the user wants to \"run an evaluation\", \"evaluate my agent\", \"evaluate my ADK agent\", \"write an eval dataset\", \"analyze eval failures\", \"compare eval results\", \"optimize agent\", or needs guidance on the Gemini platform eval methodology and the Quality Flywheel. Covers eval metrics, dataset schema, LLM-as-judge scoring, and common failure causes. Applies to any agents-cli project, whatever framework the agent is written in. Do NOT use for agent API code patterns (ADK: use google-agents-cli-adk-code), deployment (use google-agents-cli-deploy), or project scaffolding (use google-agents-cli-scaffold).","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli\u002Fblob\u002Fmain\u002Fsrc\u002Fgoogle\u002Fagents\u002Fcli\u002Fskills\u002Fdata\u002Fgoogle-agents-cli-eval\u002FSKILL.md",[171,172],{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":92,"categoryName":93,"taxonomyType":94,"taxonomyTypeDesc":95},[9,27,174,175,45,176,125,177,42,178,161,107,179,162,180,181,182,36,110,183],"google agents cli eval","eval","project scaffolding","scaffolding","dataset","scoring","common","analyze","optimize","write",{"skillNo":185,"name":186,"nameZh":6,"description":187,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":188,"categories":189,"keywords":196,"publishedAt":46},"01M6990MAHH0X6XCNVB74Q67P6","google-agents-cli-deploy","This skill should be used when the user wants to \"deploy an agent\", \"deploy my ADK agent\", \"set up CI\u002FCD\", \"configure secrets\", \"troubleshoot a deployment\", or needs guidance on Agent Runtime, Cloud Run, or GKE deployment targets, or binding an agent to an Agent Gateway. Covers deployment workflows, service accounts, rollback, and production infrastructure. Applies to any framework agents-cli deploys (ADK, LangChain, ...). Part of the agents-cli skills suite. Do NOT use for agent API code patterns (ADK: use google-agents-cli-adk-code), evaluation (use google-agents-cli-eval), or project scaffolding (use google-agents-cli-scaffold).","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fagents-cli\u002Fblob\u002Fmain\u002Fsrc\u002Fgoogle\u002Fagents\u002Fcli\u002Fskills\u002Fdata\u002Fgoogle-agents-cli-deploy\u002FSKILL.md",[190,193,194,195],{"categoryNo":191,"categoryName":192,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000010","后端与接口",{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":92,"categoryName":93,"taxonomyType":94,"taxonomyTypeDesc":95},[9,197,27,198,45,125,126,175,42,199,161,200,110,201,202,203,204,205,206,207],"google agents cli deploy","deploy","workflows","gke","Evaluation","langchain","infrastructure","do","cloud run","for","deployment"]