Skip to main content
GET
/
api
/
activity
/
mcp
/
keys
/
{keyId}
/
{startDay}
/
{startMonth}
/
{startYear}
/
{EndDay}
/
{EndMonth}
/
{EndYear}
MCP activity per API key.
curl --request GET \
  --url https://{tenant}/api/activity/mcp/keys/{keyId}/{startDay}/{startMonth}/{startYear}/{EndDay}/{EndMonth}/{EndYear} \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "error": 4,
      "hits": 26,
      "id": {
        "alias": "<string>",
        "api_id": "7364617cc7d345d9755d182635dfd46d",
        "api_name": "OAS http",
        "code": 123,
        "day": 12,
        "hour": 0,
        "iso_country": "<string>",
        "key": "<string>",
        "month": 6,
        "path": "<string>",
        "queries": {},
        "url": "<string>",
        "year": 2024
      },
      "last_hit": "2024-06-19T06:33:30Z",
      "latency": 0,
      "max_latency": 0,
      "max_upstream_latency": 0,
      "min_latency": 0,
      "min_upstream_latency": 0,
      "request_time": 190.2,
      "success": 22,
      "upstream_latency": 0
    }
  ],
  "pages": 123
}

Authorizations

Authorization
string
header
required

The Tyk Dashboard API Access Credentials

Path Parameters

keyId
string
required

API key hash.

startDay
string
required

Start day of the date range (1-31).

startMonth
string
required

Start month of the date range (1-12).

startYear
string
required

Start year of the date range.

EndDay
string
required

End day of the date range (1-31).

EndMonth
string
required

End month of the date range (1-12).

EndYear
string
required

End year of the date range.

Query Parameters

mcp_method
string

Filter by MCP JSON-RPC method name.

mcp_primitive_type
enum<string>

Filter by primitive type (tool, resource, or prompt).

Available options:
tool,
resource,
prompt
mcp_primitive_name
string

Filter by primitive name.

group_by
enum<string>

Group results by the specified field.

Available options:
mcp_primitive

Response

MCP activity data for the supplied key.

data
object[] | null
pages
integer