---
title: "Configure server metrics for a test run"
method: PATCH
path: "/test-runs/{testRunId}/server-metrics-config"
tags: ["TestRun"]
---

# Configure server metrics for a test run

`PATCH /test-runs/{testRunId}/server-metrics-config`

Configure server metrics for a test run

## Path parameters

- `testRunId` string, required

## Query parameters

- `api-version` string, required

## Response `200`

The request has succeeded.

- TestRunServerMetricsConfiguration — Test run server metrics configuration
  - `testRunId` string — Test run identifier
  - `metrics` object — Azure resource metrics collection {metric id : metrics object} (Refer : https://learn.microsoft.com/en-us/rest/api/monitor/metric-definitions/list#metricdefinition for metric id).
  - `createdDateTime` string, date-time — The creation datetime(RFC 3339 literal format).
  - `createdBy` string — The user that created.
  - `lastModifiedDateTime` string, date-time — The last Modified datetime(RFC 3339 literal format).
  - `lastModifiedBy` string — The user that last modified.

## Other responses

- `201` — The request has succeeded and a new resource has been created as a result.
- `default` — An unexpected error response.

---

[API](https://skmtc.dev/azure/apis/loadtestservice-loadtesting.md) · [All operations](https://skmtc.dev/azure/apis/loadtestservice-loadtesting/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/azure/loadtestservice-loadtesting/revisions/a39805b6167f/schema)
