# Portkey MCP by usefulapi

> Portkey MCP by usefulapi is an MCP server. Read AI-gateway analytics, configs, virtual keys, workspaces and users; log request feedback. It runs as a hosted remote server, so there is nothing to install locally.

- **Kind:** MCP server
- **Website:** https://usefulapi.io/portkey/
- **Repository:** https://github.com/m190/usefulapi-mcp/tree/HEAD/servers/portkey
- **MCP Registry name:** io.usefulapi/portkey
- **Listing updated:** 2026-11-13

## About

Read AI-gateway analytics, configs, virtual keys, workspaces and users; log request feedback.

## Install

### Claude Code (Terminal)

```sh
claude mcp add --transport http portkey https://portkey.usefulapi.io/mcp
```

### Claude Desktop (Settings → Connectors → Add custom connector)

```sh
https://portkey.usefulapi.io/mcp
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "portkey": {
      "url": "https://portkey.usefulapi.io/mcp"
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "portkey": {
      "type": "http",
      "url": "https://portkey.usefulapi.io/mcp"
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "portkey": {
      "serverUrl": "https://portkey.usefulapi.io/mcp"
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "portkey": {
      "type": "http",
      "url": "https://portkey.usefulapi.io/mcp"
    }
  }
}
```

## Tools

- `portkey_get_analytics_graph`: Get a time-series analytics graph for a single metric (cost, requests, tokens, latency, error-rate, cache-hit-rate, …) over a time window. Optionally scope by virtual keys, configs, or metadata. Portkey: GET /analytics/graphs/{metric}.
- `portkey_get_analytics_group`: Get grouped analytics (aggregated by models, users, or metadata) over a time window. Portkey: GET /analytics/groups/{group}.
- `portkey_list_configs`: List gateway configs (routing/fallback/retry/cache rulesets applied to requests). Portkey: GET /configs.
- `portkey_get_config`: Get a single gateway config by slug (or id), including its routing rules. Portkey: GET /configs/{slug}.
- `portkey_list_api_keys`: List API keys in the organization/workspace (metadata only — secrets are never returned). Portkey: GET /api-keys.
- `portkey_get_api_key`: Get a single API key's metadata by id (the secret is never returned). Portkey: GET /api-keys/{id}.
- `portkey_list_virtual_keys`: List virtual keys (the aliases that map to provider credentials + budget/rate limits used in requests). Portkey: GET /virtual-keys.
- `portkey_get_virtual_key`: Get a single virtual key by slug, including its provider + limits. Portkey: GET /virtual-keys/{slug}.
- `portkey_list_workspaces`: List workspaces in the organization. Portkey: GET /workspaces.
- `portkey_get_workspace`: Get a single workspace by slug/id. Portkey: GET /workspaces/{id}.
- `portkey_list_workspace_members`: List members of a workspace (users + their roles). Portkey: GET /workspaces/{id}/members.
- `portkey_list_users`: List users in the organization. Filter by role or email. Portkey: GET /users.
- `portkey_get_user`: Get a single user by id. Portkey: GET /users/{id}.
- `portkey_list_user_invites`: List pending user invitations to the organization. Portkey: GET /user-invites.
- `portkey_list_audit_logs`: List audit log entries (admin actions across the organization). Portkey: GET /audit-logs.
- `portkey_create_feedback`: WRITES a feedback record into the Portkey account, attached to a request/trace by trace_id. Use for logging a quality score (typically -10..10) with an optional weight (0..1) and metadata. Portkey: POST /feedback.

## FAQ

### How do I add Portkey MCP by usefulapi to Claude Code?

Run this command in your terminal: claude mcp add --transport http portkey https://portkey.usefulapi.io/mcp

---
Source: https://ai-powered.com/mcp/portkey-mcp-by-usefulapi
