Many businesses already have valuable capabilities behind REST APIs: checking order status, retrieving availability, creating callback requests, updating CRM records, or looking up service coverage. The opportunity is to make those actions available to AI without rebuilding every integration or granting broad, uncontrolled access.
Google announced on September 24, 2026 that Google Cloud API Gateway can act as a remote Model Context Protocol server in public preview. According to the Google Developers announcement, existing OpenAPI 3.x operations can be exposed as MCP tools while retaining configured authentication, quotas, and logging.
Begin with a narrow business action
Do not expose an entire API because it exists. Start with a common customer need and a measurable outcome. Examples include checking an order, finding approved appointment windows, verifying a service ZIP code, or creating a callback request.
Document the action’s purpose, required inputs, permitted records, possible outputs, and owner. The description should explain when and why an agent may use the tool, not merely repeat the endpoint name.
Write descriptions for decisions
Tool descriptions guide selection. “Returns an order” is vague. “Use this tool when a customer asks for the current delivery status and estimated arrival of an existing order” gives the agent a clearer boundary.
Include what the tool cannot do. A read-only availability tool should not imply that it confirms a booking. A callback request should not promise an immediate transfer.
Protect tool discovery
Tool discovery can reveal names and input schemas. Google notes that production discovery should be secured, while the underlying operation still enforces its own authentication. Treat discovery, execution, and downstream record access as separate controls.
Use environment-specific credentials, least privilege, rotation, expiration, and revocation. Keep secrets out of prompts, transcripts, summaries, and CRM notes.
Validate agent-generated arguments
Every tool call should be treated as untrusted input. Validate types, formats, allowed values, record ownership, date ranges, timezones, service areas, consent, and size limits. Reject unsupported fields instead of accepting them silently.
Validate tool responses as well. “No availability” is different from a calendar outage. A CRM success followed by a calendar failure is not a confirmed appointment.
A practical ecommerce example
A local retailer wants its website assistant to answer order-status questions. The tool requires a valid order reference plus an approved identity check. It returns the current fulfillment state and public tracking information but cannot change the shipping address or issue a refund.
If the order is missing, the identifier is ambiguous, or the provider times out, the workflow offers a human path and preserves the collected context. It does not invent a delivery date.
This narrow design reduces repetitive work while keeping high-impact account changes under staff control.
Use quotas and idempotency
Agent traffic may call tools more often or in different sequences than a traditional application. Set quotas by workflow, user, tool, and time window where appropriate. Limit pagination and repeated lookups.
For actions that create or change records, use idempotency keys. A retry after a timeout should not create two appointments, two callbacks, or two CRM opportunities.
Connect tools to business states
A tool should be available only when the workflow is in an appropriate state. Availability lookup may follow qualification. Booking may require confirmed customer details, an explicit request, and a successful calendar write.
Maya uses Respond → Qualify → Act → Handoff. MCP or other API tooling can support Act and Handoff, but business-specific rules determine when an action is appropriate and what the customer should hear next.
Test failure before launch
Test expired credentials, missing fields, rate limits, invalid addresses, no results, timeouts, partial success, duplicate requests, and downstream outages. Confirm that every uncertain state produces an accurate customer message and a visible staff task.
Also test human takeover. Once an employee accepts the inquiry, stale automated actions and messages should stop unless explicitly approved.
Measure operational outcomes
Track tool selection, validation failures, permission denials, latency, quota events, duplicate suppression, downstream exceptions, and time to recovery. Connect those metrics to qualified inquiries, completed callbacks, confirmed appointments, order questions resolved, and staff acceptance of handoffs.
A technically successful tool call is not the final outcome. Success means the customer received the correct next step and the business retained a reliable record.
Implementation checklist
- Select narrow, commercially useful operations.
- Use OpenAPI 3.x where required.
- Write decision-oriented tool descriptions.
- Secure discovery and execution.
- Validate arguments, responses, and ownership.
- Add quotas, idempotency, and exception handling.
- Test the human handoff.
Manage the tool catalog
Maintain an inventory with the tool name, business purpose, owner, allowed workflow states, credential, source system, destination, quota, expected latency, and recovery path. Review the catalog whenever an API schema, tool description, permission, or customer process changes.
Remove tools that no longer support an active workflow. A smaller catalog reduces accidental selection and makes permissions easier to audit. Version descriptions and schemas so test results can be tied to the configuration that produced them.
Require evidence for consequential actions
Before a booking, account change, refund request, or other material action, preserve the minimum evidence needed to explain the decision: confirmed customer details, requested outcome, applicable business rule, tool result, timestamp, and owner. Do not store unnecessary private information.
Use human approval when the request falls outside routine limits or when an upstream result is uncertain. The approval view should summarize the proposed action and its expected effect. After approval or denial, return the workflow to a defined state and tell the customer the accurate next step.
Before production, conduct a tabletop review with the workflow owner, system administrator, and employee who receives escalations. Walk through a normal request, a customer correction, an unauthorized request, a timeout after a write, and a failed human transfer. Confirm that each participant understands the resulting state, customer wording, and recovery responsibility.
Next step
Choose one existing REST operation that answers a frequent customer question. Define its permissions, validation, states, failure messages, and owner before connecting it to an agent. DIGIMAR AI automation services and DIGIMAR web development can help build the controlled customer journey around it.