Endpoint Service

Get endpoint analytics

GET
/projects/{projectId}/endpoints/{id}/analytics

Returns aggregated request, token, latency, throughput, error, and resource-utilization metrics for an endpoint over a time range. Optionally includes time-series buckets and a per-deployment breakdown.

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

projectId*string

Project identifier.

id*string

Endpoint identifier.

Query Parameters

deploymentId?string

Restrict to a single deployment under this endpoint.

startTime?string

Inclusive start of the time range. Defaults to 24 hours ago if unset.

Formatdate-time
endTime?string

Exclusive end of the time range. Defaults to now if unset.

Formatdate-time
includeTimeSeries?boolean

When true, include per-bucket time series in the response.

granularity?string

Time-series bucket duration, such as 1m, 1h, or 1d. Defaults to 1d.

Response Body

application/json

application/json

curl -X GET "https://example.com/projects/string/endpoints/string/analytics"
{  "endpointId": "string",  "timeRange": {    "startTime": "2019-08-24T14:15:22Z",    "endTime": "2019-08-24T14:15:22Z"  },  "metrics": {    "endpointId": "string",    "timeRange": {      "startTime": "2019-08-24T14:15:22Z",      "endTime": "2019-08-24T14:15:22Z"    },    "requestMetrics": {      "totalRequests": "string",      "successfulRequests": "string",      "failedRequests": "string",      "requestsPerSecond": 0,      "requestsByStatusCode": {        "property1": "string",        "property2": "string"      }    },    "latencyMetrics": {      "ttftP50Ms": 0,      "ttftP90Ms": 0,      "ttftP99Ms": 0,      "latencyP50Ms": 0,      "latencyP90Ms": 0,      "latencyP99Ms": 0,      "itlP50Ms": 0,      "itlP90Ms": 0,      "itlP99Ms": 0    },    "throughputMetrics": {      "tokensPerSecond": 0,      "requestsPerSecond": 0,      "avgBatchSize": 0,      "avgBatchDepth": 0    },    "errorMetrics": {      "errorRate": 0,      "errorsByType": {        "property1": "string",        "property2": "string"      }    },    "resourceUtilization": {      "cpuUtilization": 0,      "gpuUtilization": 0,      "memoryUtilization": 0,      "gpuMemoryUtilization": 0,      "networkBandwidthMbps": 0    },    "tokenMetrics": {      "totalInputTokens": "string",      "totalOutputTokens": "string",      "avgInputTokens": 0,      "avgOutputTokens": 0    },    "deploymentMetrics": [      {        "deploymentId": "string",        "endpointId": "string",        "timeRange": {          "startTime": "2019-08-24T14:15:22Z",          "endTime": "2019-08-24T14:15:22Z"        },        "requestMetrics": {          "totalRequests": "string",          "successfulRequests": "string",          "failedRequests": "string",          "requestsPerSecond": 0,          "requestsByStatusCode": {            "property1": "string",            "property2": "string"          }        },        "latencyMetrics": {          "ttftP50Ms": 0,          "ttftP90Ms": 0,          "ttftP99Ms": 0,          "latencyP50Ms": 0,          "latencyP90Ms": 0,          "latencyP99Ms": 0,          "itlP50Ms": 0,          "itlP90Ms": 0,          "itlP99Ms": 0        },        "throughputMetrics": {          "tokensPerSecond": 0,          "requestsPerSecond": 0,          "avgBatchSize": 0,          "avgBatchDepth": 0        },        "errorMetrics": {          "errorRate": 0,          "errorsByType": {            "property1": "string",            "property2": "string"          }        },        "resourceUtilization": {          "cpuUtilization": 0,          "gpuUtilization": 0,          "memoryUtilization": 0,          "gpuMemoryUtilization": 0,          "networkBandwidthMbps": 0        },        "tokenMetrics": {          "totalInputTokens": "string",          "totalOutputTokens": "string",          "avgInputTokens": 0,          "avgOutputTokens": 0        }      }    ]  },  "timeSeries": [    {      "timestamp": "2019-08-24T14:15:22Z",      "values": {        "property1": 0,        "property2": 0      }    }  ],  "deploymentAnalytics": [    {      "deploymentId": "string",      "endpointId": "string",      "timeRange": {        "startTime": "2019-08-24T14:15:22Z",        "endTime": "2019-08-24T14:15:22Z"      },      "metrics": {        "deploymentId": "string",        "endpointId": "string",        "timeRange": {          "startTime": "2019-08-24T14:15:22Z",          "endTime": "2019-08-24T14:15:22Z"        },        "requestMetrics": {          "totalRequests": "string",          "successfulRequests": "string",          "failedRequests": "string",          "requestsPerSecond": 0,          "requestsByStatusCode": {            "property1": "string",            "property2": "string"          }        },        "latencyMetrics": {          "ttftP50Ms": 0,          "ttftP90Ms": 0,          "ttftP99Ms": 0,          "latencyP50Ms": 0,          "latencyP90Ms": 0,          "latencyP99Ms": 0,          "itlP50Ms": 0,          "itlP90Ms": 0,          "itlP99Ms": 0        },        "throughputMetrics": {          "tokensPerSecond": 0,          "requestsPerSecond": 0,          "avgBatchSize": 0,          "avgBatchDepth": 0        },        "errorMetrics": {          "errorRate": 0,          "errorsByType": {            "property1": "string",            "property2": "string"          }        },        "resourceUtilization": {          "cpuUtilization": 0,          "gpuUtilization": 0,          "memoryUtilization": 0,          "gpuMemoryUtilization": 0,          "networkBandwidthMbps": 0        },        "tokenMetrics": {          "totalInputTokens": "string",          "totalOutputTokens": "string",          "avgInputTokens": 0,          "avgOutputTokens": 0        }      },      "timeSeries": [        {          "timestamp": "2019-08-24T14:15:22Z",          "values": {            "property1": 0,            "property2": 0          }        }      ]    }  ]}