Guide

Are your MCP tools visible to everyone?

They might. In Google Cloud API Gateway’s current MCP Public Preview, `+'`tools/list`'+` is unauthenticated by default unless you configure discovery security. Tool invocation (`+'`tools/call`'+`) reuses the authentication configured for the underlying REST operation. That split means a protected write operation can still have its tool name and schema exposed to anyone who can list tools.

Treat discovery and invocation as separate surfaces

A tool catalog can reveal internal service names, workflow structure, parameter names, resource identifiers, and operational assumptions. That information may be sensitive even when the API denies unauthorized execution. Conversely, hiding discovery does not replace authorization checks on each call: a client can submit a call without first asking for the list.

Access checks for an MCP endpoint
RequestSecurity questionTest
`+'`tools/list`'+'`Who can enumerate tool names and schemas?Call without credentials and with an expired or wrong-scope credential.
`+'`tools/call`'+'`Does the caller have permission for this tool and its target resource?Call directly, alter arguments, and cross tenant boundaries.
REST backendDoes the translated request retain the same identity, quotas, and policy?Compare the MCP path with the direct REST authorization result.

Configure and verify

Google’s configuration docs support authentication for tool discovery with a JWT or API key security scheme. If discovery is protected, verify the client sends credentials in the documented header and that failures do not return a partial schema. The gateway’s documentation also describes excluding individual operations from MCP exposure; use an explicit allowlist where possible and review the generated tool inventory after changes.

  1. Decide whether tool names, schemas, and operation count are public information.
  2. Use a narrow allowlist of operations and schemas; remove administrative and destructive methods unless required.
  3. Protect discovery when its output is sensitive.
  4. Require per-call authentication and resource-level authorization regardless of discovery settings.
  5. Use least-privilege scopes and bind credentials to the intended MCP resource.
  6. Test anonymous, wrong-tenant, low-privilege, expired-token, and direct-call cases.
  7. Review logs for denied calls and verify they do not contain secrets or complete sensitive arguments.

What this does not prove

A gateway setting is not proof of end-to-end authorization. Confirm which identity reaches the backend, whether the gateway maps or replaces claims, how API keys are scoped, and whether logs preserve the relevant actor. For OAuth-based MCP services, follow the current protocol authorization rules and do not treat a valid token as valid for every resource.

For the broader choice between gateway-based tool exposure and a dedicated server, see Should your API gateway serve MCP tools?. Existing gateway controls and their evidence are covered in the compliance guide.

Common questions

Does hiding `tools/list` prevent unauthorized MCP calls?

No. A client can attempt `tools/call` directly. Enforce authorization on invocation and at the backend resource boundary.

Should every MCP server require authentication for tool discovery?

It depends on whether tool names and schemas are sensitive and on the deployment model. In enterprise environments, protecting discovery is often prudent; still authorize every call independently.

Can an API key secure MCP tool discovery?

Google Cloud API Gateway documents API-key and JWT options for `tools/list` in its current product configuration. Other servers may differ; check the product and protocol implementation in use.

Sources and editorial review dates are recorded with this guide. Catalogue-backed blocks use the dated catalogue snapshot. See our methodology.