# Monitor every layer of your AI infrastructure.

From MCP servers to inference providers, APIContext monitors the full AI stack — so you can see which providers are performing, catch schema drift before agents fail, and align every model with the right resilience and data protection boundary.

- MCP server monitoring
- Inference provider APIs
- Tool contract checks
- Multi-step workflows

**125+** global monitoring locations  
**24/7** continuous AI infrastructure monitoring  
**OTEL** native spans on every call  
**<5m** to start monitoring your AI stack

## End-to-End AI Infrastructure Monitoring

APIContext monitors both MCP server tool calls and inference provider APIs — validating schema, latency, availability, and contract correctness at every layer of your AI stack.

| Tool                | Response Time | Status                |
|---------------------|---------------|-----------------------|
| tools/list          | **24ms**     | _3 tools registered_   |
| search_docs(q='refunds') | **412ms**    | _schema passed_        |
| query_db(sql='SELECT…') | **188ms**    | _14 rows_             |
| send_email(to='x@y') | **2.1s**     | _over SLO threshold_   |

```json
{
  "content": [{
    "type": "text",
    "text": "Refund policy...",
    "source": "docs/refunds.md"
  }],
  "isError": false
}
```

## Inference provider monitoring

APIContext monitors inference provider APIs — OpenAI, Anthropic, Azure OpenAI, Google Gemini, and others — from the same global locations as your users. See latency, availability, and throughput side by side so you route to the provider that earns it.

### Latency and availability across major inference providers

- p50, p95, and p99 per model and endpoint
- Instant alerts when a provider degrades

Coverage: **125+ data centers · all major clouds**

## Full payloads

APIContext runs full MCP sessions with realistic argument distributions. This is not a synthetic ping against a health check. See how your MCP servers work in production.

- Replay captured sessions from real agents
- Fuzz tool arguments within schema bounds
- Verify tools/list stability across deploys

### Example Code

```typescript
// simulate an AI client using your MCP server
import { mcpSession, assert } from '@apicontext/mcp';

export default mcpSession({
  server: 'https://mcp.acme.com',
  transport: 'sse',
  auth: oauth({ scope: 'mcp:read' }),
}, async (s) => {
  const tools = await s.listTools();
  assert.count(tools, 3);
  const r = await s.call('search_docs', { q: 'refunds' });
  assert.schema(r, 'ToolResult.v1');
  assert.contains(r.content[0].text, 'policy');
});
```

## Provider alignment

Not every workload has the same availability requirement or data sensitivity. APIContext gives you the performance evidence to route high-stakes workloads to proven providers, keep sensitive prompts within compliant boundaries, and test failover paths before you need them.

- SLO verification per provider and model
- Data residency and boundary checks
- Failover readiness testing across provider pairs

| Service        | Availability Target | Live Availability | Burn Rate |
|----------------|---------------------|------------------|-----------|
| Payments API   | 99.95%              | 99.97%           | 0.4×      |
| Accounts API   | 99.9%               | 99.94%           | 0.3×      |
| Plaid (supplier) | 99.5%            | 99.21%           | 4.1×      |
| Stripe (supplier) | 99.95%          | 99.96%           | 0.5×      |
| Auth (OAuth)   | Error rate          | 0.1%             | 0.04%     |

## Works across multi-step journeys

Connect synthetic journeys across internal and external MCP servers, HTTP endpoints, third parties, and APIs to verify end-to-end resilience.

- Monitor both internal and external MCP servers in one flow
- OAuth 2.1, PAT, mTLS, signed HMAC
- Run from global POPs or VPC collectors

### Key Features

- **Safety checks**: Flag tools that are unexpected and resources that are out of specification.
- **Latency SLOs**: Separate SLOs for tools/list, individual tool calls, and inference provider endpoints — p50, p95, and p99.
- **Instant alerting**: Ping Slack, PagerDuty, Incident.io, ServiceNow, and more when contracts break or providers degrade.
- **Per-tool uptime**: Tool-level availability rather than just server-level availability.
- **Provider comparison**: Side-by-side latency and availability across inference providers — so you always know who's performing.
- **OTEL native**: Every MCP call and inference request emits OpenTelemetry spans — route signal to any compatible backend.

## Start monitoring your AI infrastructure in 3 minutes.

Point APIContext at your MCP server or inference provider. We connect, enumerate, and start running synthetic sessions in under five minutes.
