When your AI agent calls a tool, the response includes rich data. It is crucial to parse this information to provide the best possible experience.
| Response Metadata | Description |
|---|---|
| Relevance Scores | Tells you how well each product matches the query's intent. |
| Processing Time | Includes breakdowns showing where time was spent during the search. |
| Search Method Indicator | Reveals whether results came from semantic search or a fallback to keywords. |
Errors are not just failures; they are "opportunities to provide helpful guidance" and maintain user confidence. MCIP provides detailed error information to help your agent respond appropriately.
| Error Type | How to Handle |
|---|---|
| Rate Limiting | The error will include retry-after information. Your agent can use this to intelligently schedule a retry instead of failing, perhaps telling the user, "I'm processing a lot of searches right now. Let me try again in a few seconds." |
| Validation Errors | The error provides specific information about which field was wrong and how to fix it (e.g., a filter value is out of range). Your agent can use this to guide the user toward a valid input. |
| Timeouts / Availability | MCIP may trigger internal fallbacks (e.g., using keyword search if semantic search fails). The response will indicate when a fallback was used, allowing your agent to set user expectations. |
To make the system feel faster, your agent should handle streaming responses. If MCIP is searching multiple platforms, your agent can "show results from fast platforms immediately" while slower ones are still processing. This progressive enhancement keeps users engaged.