Skip to content

On-premise users: click in-app to access the full platform documentation for your version of DataRobot.

Observability Service Health

This page outlines the operations, endpoints, parameters, and example requests and responses for the Observability Service Health.

GET /api/v2/deployments/{deploymentId}/batchServiceStats/

Retrieve all deployment service health metrics over a set of batches.

Code samples

curl -X GET https://app.datarobot.com/api/v2/deployments/{deploymentId}/batchServiceStats/ \
  -H "Accept: application/json" \
  -H "Authorization: Bearer {access-token}"

Parameters

Name In Type Required Description
executionTimeQuantile query number false Quantile for executionTime metric.
responseTimeQuantile query number false Quantile for responseTime metric.
slowRequestsThreshold query integer false Threshold for slowRequests metric.
segmentAttribute query string false The name of a segment attribute used for segment analysis.
segmentValue query string,null false The value of the segmentAttribute to segment on.
batchId query any false The id of the batch for which metrics are being retrieved.
modelId query string false The id of the model for which metrics are being retrieved.
deploymentId path string true Unique identifier of the deployment.

Enumerated Values

Parameter Value
segmentAttribute [DataRobot-Consumer, DataRobot-Remote-IP, DataRobot-Host-IP]

Example responses

200 Response

{
  "batches": [
    {
      "earliestPredictionTimestamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "latestPredictionTimestamp": "2019-08-24T14:15:22Z",
      "name": "string"
    }
  ],
  "metrics": {
    "cacheHitRatio": 0,
    "executionTime": 0,
    "numConsumers": 0,
    "responseTime": 0,
    "serverErrorRate": 0,
    "slowRequests": 0,
    "totalPredictions": 0,
    "totalRequests": 0,
    "userErrorRate": 0
  },
  "segmentAttribute": "string",
  "segmentValue": ""
}

Responses

Status Meaning Description Schema
200 OK Service health metric data retrieved. ServiceStatsForBatchRetrieveResponse

To perform this operation, you must be authenticated by means of one of the following methods:

BearerAuth

GET /api/v2/deployments/{deploymentId}/serviceStats/

Retrieve all deployment service health metrics over a single period of time.

Code samples

curl -X GET https://app.datarobot.com/api/v2/deployments/{deploymentId}/serviceStats/ \
  -H "Accept: application/json" \
  -H "Authorization: Bearer {access-token}"

Parameters

Name In Type Required Description
start query string,null(date-time) false Start of the period to retrieve monitoring data, defaults to 7 days ago from the end of the period. Note: this field only accepts top of the hour RFC3339 datetime strings, for example: 2019-08-01T00:00:00Z.
end query string,null(date-time) false End of the period to retrieve monitoring data, defaults to the next top of the hour. Note: this field only accepts top of the hour RFC3339 datetime strings, for example: 2019-08-01T00:00:00Z.
executionTimeQuantile query number false Quantile for executionTime metric.
responseTimeQuantile query number false Quantile for responseTime metric.
slowRequestsThreshold query integer false Threshold for slowRequests metric.
segmentAttribute query string false The name of a segment attribute used for segment analysis.
segmentValue query string,null false The value of the segmentAttribute to segment on.
modelId query string false The id of the model for which metrics are being retrieved.
deploymentId path string true Unique identifier of the deployment.

Enumerated Values

Parameter Value
segmentAttribute [DataRobot-Consumer, DataRobot-Remote-IP, DataRobot-Host-IP]

Example responses

200 Response

{
  "metrics": {
    "cacheHitRatio": 0,
    "executionTime": 0,
    "medianLoad": 0,
    "numConsumers": 0,
    "peakLoad": 0,
    "responseTime": 0,
    "serverErrorRate": 0,
    "slowRequests": 0,
    "totalPredictions": 0,
    "totalRequests": 0,
    "userErrorRate": 0
  },
  "modelId": "string",
  "period": {
    "end": "2019-08-24T14:15:22Z",
    "start": "2019-08-24T14:15:22Z"
  },
  "segmentAttribute": "string",
  "segmentValue": ""
}

Responses

Status Meaning Description Schema
200 OK Service health metric data retrieved. ServiceStatsForTimeRangeResponse

To perform this operation, you must be authenticated by means of one of the following methods:

BearerAuth

GET /api/v2/deployments/{deploymentId}/serviceStatsOverBatch/

Retrieve values for one single deployment service health metric over batch.

Code samples

curl -X GET https://app.datarobot.com/api/v2/deployments/{deploymentId}/serviceStatsOverBatch/ \
  -H "Accept: application/json" \
  -H "Authorization: Bearer {access-token}"

Parameters

Name In Type Required Description
segmentAttribute query string false The name of a segment attribute used for segment analysis.
segmentValue query string,null false The value of the segmentAttribute to segment on.
batchId query any false The id of the batch for which metrics are being retrieved.
modelId query string false The id of the model for which metrics are being retrieved.
metric query string false A service health metric.
quantile query number false Quantile for executionTime and responseTime metrics
threshold query integer false Threshold for slowQueries metric.
deploymentId path string true Unique identifier of the deployment.

Enumerated Values

Parameter Value
segmentAttribute [DataRobot-Consumer, DataRobot-Remote-IP, DataRobot-Host-IP]
metric [totalPredictions, totalRequests, slowRequests, executionTime, responseTime, userErrorRate, serverErrorRate, numConsumers, cacheHitRatio]

Example responses

200 Response

{
  "buckets": [
    {
      "batch": {
        "earliestPredictionTimestamp": "2019-08-24T14:15:22Z",
        "id": "string",
        "latestPredictionTimestamp": "2019-08-24T14:15:22Z",
        "name": "string"
      },
      "value": 0
    }
  ],
  "metric": "string",
  "segmentAttribute": "string",
  "segmentValue": ""
}

Responses

Status Meaning Description Schema
200 OK Service health metric data retrieved. ServiceStatsOverBatchResponse

To perform this operation, you must be authenticated by means of one of the following methods:

BearerAuth

GET /api/v2/deployments/{deploymentId}/serviceStatsOverTime/

Retrieve values for one single deployment service health metric over time.

Code samples

curl -X GET https://app.datarobot.com/api/v2/deployments/{deploymentId}/serviceStatsOverTime/ \
  -H "Accept: application/json" \
  -H "Authorization: Bearer {access-token}"

Parameters

Name In Type Required Description
start query string,null(date-time) false Start of the period to retrieve monitoring data, defaults to 7 days ago from the end of the period. Note: this field only accepts top of the hour RFC3339 datetime strings, for example: 2019-08-01T00:00:00Z.
end query string,null(date-time) false End of the period to retrieve monitoring data, defaults to the next top of the hour. Note: this field only accepts top of the hour RFC3339 datetime strings, for example: 2019-08-01T00:00:00Z.
bucketSize query string(duration) false The time duration of a bucket. Needs to be multiple of one hour. Can not be longer than the total length of the period. If not set, a default value will be calculated based on the start and end time.
metric query string false Name of the metric. See below for a list of supported metrics.
quantile query number false A quantile for resulting data, used if metric is executionTime or responseTime, defaults to 0.5.
threshold query integer false A threshold for filtering results, used if metric is slowQueries, defaults to 1000.
segmentAttribute query string false The name of a segment attribute used for segment analysis.
segmentValue query string,null false The value of the segmentAttribute to segment on.
modelId query string false The id of the model for which metrics are being retrieved.
deploymentId path string true Unique identifier of the deployment.

Enumerated Values

Parameter Value
metric [totalPredictions, totalRequests, slowRequests, executionTime, responseTime, userErrorRate, serverErrorRate, numConsumers, cacheHitRatio, medianLoad, peakLoad]
segmentAttribute [DataRobot-Consumer, DataRobot-Remote-IP, DataRobot-Host-IP]

Example responses

200 Response

{
  "buckets": [
    {
      "period": {
        "end": "2019-08-24T14:15:22Z",
        "start": "2019-08-24T14:15:22Z"
      },
      "value": 0
    }
  ],
  "metric": "string",
  "modelId": "string",
  "segmentAttribute": "string",
  "segmentValue": "",
  "summary": {
    "period": {
      "end": "2019-08-24T14:15:22Z",
      "start": "2019-08-24T14:15:22Z"
    },
    "value": 0
  }
}

Responses

Status Meaning Description Schema
200 OK Service health metric data retrieved. ServiceStatsOverTimeResponse

To perform this operation, you must be authenticated by means of one of the following methods:

BearerAuth

Schemas

Batch

{
  "earliestPredictionTimestamp": "2019-08-24T14:15:22Z",
  "id": "string",
  "latestPredictionTimestamp": "2019-08-24T14:15:22Z",
  "name": "string"
}

Batch info.

Properties

Name Type Required Restrictions Description
earliestPredictionTimestamp string(date-time) true Earliest prediction timestamp of a batch.
id string true Batch ID.
latestPredictionTimestamp string,null(date-time) true Latest prediction timestamp of a batch.
name string true Batch name.

ServiceStatsForBatchRetrieveResponse

{
  "batches": [
    {
      "earliestPredictionTimestamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "latestPredictionTimestamp": "2019-08-24T14:15:22Z",
      "name": "string"
    }
  ],
  "metrics": {
    "cacheHitRatio": 0,
    "executionTime": 0,
    "numConsumers": 0,
    "responseTime": 0,
    "serverErrorRate": 0,
    "slowRequests": 0,
    "totalPredictions": 0,
    "totalRequests": 0,
    "userErrorRate": 0
  },
  "segmentAttribute": "string",
  "segmentValue": ""
}

Properties

Name Type Required Restrictions Description
batches [Batch] true Info of the batches the metric is aggregated on.
metrics ServiceStatsMetricsForBatch true Service health metrics of the deployment
segmentAttribute string,null false The name of the segment on which segment analysis is being performed.
segmentValue string,null false The value of the segmentAttribute to segment on.

ServiceStatsForTimeRangeResponse

{
  "metrics": {
    "cacheHitRatio": 0,
    "executionTime": 0,
    "medianLoad": 0,
    "numConsumers": 0,
    "peakLoad": 0,
    "responseTime": 0,
    "serverErrorRate": 0,
    "slowRequests": 0,
    "totalPredictions": 0,
    "totalRequests": 0,
    "userErrorRate": 0
  },
  "modelId": "string",
  "period": {
    "end": "2019-08-24T14:15:22Z",
    "start": "2019-08-24T14:15:22Z"
  },
  "segmentAttribute": "string",
  "segmentValue": ""
}

Properties

Name Type Required Restrictions Description
metrics ServiceStatsMetricsForTimeRange true Service health metrics of the deployment
modelId string false The id of the model for which metrics are being retrieved.
period TimeRange true An object with the keys "start" and "end" defining the period.
segmentAttribute string,null false The name of the segment on which segment analysis is being performed.
segmentValue string,null false The value of the segmentAttribute to segment on.

ServiceStatsMetricsForBatch

{
  "cacheHitRatio": 0,
  "executionTime": 0,
  "numConsumers": 0,
  "responseTime": 0,
  "serverErrorRate": 0,
  "slowRequests": 0,
  "totalPredictions": 0,
  "totalRequests": 0,
  "userErrorRate": 0
}

Service health metrics of the deployment

Properties

Name Type Required Restrictions Description
cacheHitRatio number,null true Number of cache hits.
executionTime number,null true Request execution time at executionTimeQuantile (in milliseconds).
numConsumers integer,null true Number of unique users performing requests.
responseTime number,null true Request response time at responseTimeQuantile (in milliseconds).
serverErrorRate number,null true Ratio of server errors to the total number of requests.
slowRequests integer,null true Number of requests with response time greater than slowRequestsThreshold
totalPredictions integer,null true Total number of prediction rows.
totalRequests integer,null true Total number of prediction requests performed.
userErrorRate number,null true Ratio of user errors to the total number of requests.

ServiceStatsMetricsForTimeRange

{
  "cacheHitRatio": 0,
  "executionTime": 0,
  "medianLoad": 0,
  "numConsumers": 0,
  "peakLoad": 0,
  "responseTime": 0,
  "serverErrorRate": 0,
  "slowRequests": 0,
  "totalPredictions": 0,
  "totalRequests": 0,
  "userErrorRate": 0
}

Service health metrics of the deployment

Properties

Name Type Required Restrictions Description
cacheHitRatio number,null true Number of cache hits.
executionTime number,null true Request execution time at executionTimeQuantile (in milliseconds).
medianLoad number,null true Median of the request rate (in requests per minute).
numConsumers integer,null true Number of unique users performing requests.
peakLoad number,null true Maximum of the request rate (in requests per minute).
responseTime number,null true Request response time at responseTimeQuantile (in milliseconds).
serverErrorRate number,null true Ratio of server errors to the total number of requests.
slowRequests integer,null true Number of requests with response time greater than slowRequestsThreshold
totalPredictions integer,null true Total number of prediction rows.
totalRequests integer,null true Total number of prediction requests performed.
userErrorRate number,null true Ratio of user errors to the total number of requests.

ServiceStatsOverBatchBucket

{
  "batch": {
    "earliestPredictionTimestamp": "2019-08-24T14:15:22Z",
    "id": "string",
    "latestPredictionTimestamp": "2019-08-24T14:15:22Z",
    "name": "string"
  },
  "value": 0
}

Service health stats of the deployment over a batch.

Properties

Name Type Required Restrictions Description
batch Batch true Batch info.
value number,null true Value of the metric in the bucket.

ServiceStatsOverBatchResponse

{
  "buckets": [
    {
      "batch": {
        "earliestPredictionTimestamp": "2019-08-24T14:15:22Z",
        "id": "string",
        "latestPredictionTimestamp": "2019-08-24T14:15:22Z",
        "name": "string"
      },
      "value": 0
    }
  ],
  "metric": "string",
  "segmentAttribute": "string",
  "segmentValue": ""
}

Properties

Name Type Required Restrictions Description
buckets [ServiceStatsOverBatchBucket] true An array of buckets, representing service health stats of the deployment over selected batches.
metric string true Name of the metric requested.
segmentAttribute string,null false The name of the segment on which segment analysis is being performed.
segmentValue string,null false The value of the segmentAttribute to segment on.

ServiceStatsOverTimeBucket

{
  "period": {
    "end": "2019-08-24T14:15:22Z",
    "start": "2019-08-24T14:15:22Z"
  },
  "value": 0
}

A bucket object covering whole start/end time range

Properties

Name Type Required Restrictions Description
period TimeRange true An object with the keys "start" and "end" defining the period.
value number,null true Value of the metric in the bucket. Null if no value

ServiceStatsOverTimeResponse

{
  "buckets": [
    {
      "period": {
        "end": "2019-08-24T14:15:22Z",
        "start": "2019-08-24T14:15:22Z"
      },
      "value": 0
    }
  ],
  "metric": "string",
  "modelId": "string",
  "segmentAttribute": "string",
  "segmentValue": "",
  "summary": {
    "period": {
      "end": "2019-08-24T14:15:22Z",
      "start": "2019-08-24T14:15:22Z"
    },
    "value": 0
  }
}

Properties

Name Type Required Restrictions Description
buckets [ServiceStatsOverTimeBucket] true An array of bucket, representing service health stats of the deployment over time.
metric string true Name of the metric requested.
modelId string false The id of the model for which metrics are being retrieved.
segmentAttribute string,null false The name of the segment on which segment analysis is being performed.
segmentValue string,null false The value of the segmentAttribute to segment on.
summary ServiceStatsOverTimeBucket true A bucket object covering whole start/end time range

TimeRange

{
  "end": "2019-08-24T14:15:22Z",
  "start": "2019-08-24T14:15:22Z"
}

An object with the keys "start" and "end" defining the period.

Properties

Name Type Required Restrictions Description
end string,null(date-time) false End of the period to retrieve monitoring data, defaults to the next top of the hour. Note: this field only accepts top of the hour RFC3339 datetime strings, for example: 2019-08-01T00:00:00Z.
start string,null(date-time) false Start of the period to retrieve monitoring data, defaults to 7 days ago from the end of the period. Note: this field only accepts top of the hour RFC3339 datetime strings, for example: 2019-08-01T00:00:00Z.

Updated March 25, 2025