---
schema_version: "1"
id: bae2ec1f71f81b5155223df0f142e0ac116da1a9d2a75d214478a3fcbc6f5847
title: Metrics Methods - Retired
collection: tableau
version: current
locale: en-us
portal_url: https://docs.salesforce.com/tableau/current/en-us/api/rest_api/REST/rest_api_ref_metrics.md
canonical_url: https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_ref_metrics.htm
source_site: help.tableau.com
content_type: documentation
content_hash: 27c7c7fb070329eac1911306e8fcf8a12f7fdbb8f06a8ec403bdc7ec1ccb6b34
description: Retired in API 3
---
[Skip to main content](#main-content)

# Metrics Methods - Retired

**Retired in API 3.22 (Cloud February 2024 / Server 2024.2)**

Tableau's legacy metrics feature was retired in Tableau Cloud in February 2024 and in Tableau Server version 2024.2. In October 2023, Tableau retired the ability to embed legacy metrics in Tableau Cloud and in Tableau Server version 2023.3. With Tableau Pulse, we've developed an improved experience to track metrics and ask questions of your data. For more information, see [Create Metrics with Tableau Pulse](https://help.tableau.com/current/online/en-us/pulse_create_metrics.htm) to learn about the new experience and [Create and Troubleshoot Metrics (Retired)](https://help.tableau.com/current/online/en-us/metrics_create.htm) for the retired feature.

Using the metrics methods of the Tableau REST API you can:

- List all metrics configured for a site
- Get the details of a specific metric
- Get the data of a specific metric as CSV
- Update the name, containing project, suspended status, and owner of a specific metric
- Delete a specific metric

This functionality relates to the UI elements and concepts described at: [Create and Troubleshoot Metrics](https://help.tableau.com/current/server/en-us/metrics_create.htm).

## Use Postman

Our Postman collection of requests enables you to construct, send, and examine HTTP requests to the Tableau Server or Tableau Cloud API without writing initial code. Postman is a free online app used by many developers for prototyping API calls, investigating issues, and generating request code in a variety of languages.

[Postman: Metrics - Retired in API 3.22](https://www.postman.com/salesforce-developers/salesforce-developers/folder/tlutrsb/metrics-retired-in-api-3-22)

## Delete Metric - Retired in API 3.22

**Retired in API 3.22 (Cloud February 2024 / Server 2024.2)**

Tableau's legacy metrics feature was retired in Tableau Cloud in February 2024 and in Tableau Server version 2024.2. In October 2023, Tableau retired the ability to embed legacy metrics in Tableau Cloud and in Tableau Server version 2023.3. With Tableau Pulse, we've developed an improved experience to track metrics and ask questions of your data. For more information, see [Create Metrics with Tableau Pulse](https://help.tableau.com/current/online/en-us/pulse_create_metrics.htm) to learn about the new experience and [Create and Troubleshoot Metrics (Retired)](https://help.tableau.com/current/online/en-us/metrics_create.htm) for the retired feature.

Deletes a specified metric from a site.

#### URI

DELETE /api/api-version/sites/site-id/metrics/metric-luid

#### Parameter Values

<table class="api-parameters-table"><colgroup><col class="api-parameters-table-col-1-wide"> <col></colgroup><tbody><tr><td><span class="api-placeholder">api-version</span></td><td>The version of the API to use, such as <code><span class="mc-variable Variables.REST-API-Version variable">3.29</span></code>. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm" class="xref">REST API and Resource Versions</a>.</td></tr><tr><td><span class="api-placeholder">site-id</span></td><td>The ID of the site that contains the metric.</td></tr><tr><td><span class="api-placeholder">metric-luid</span></td><td>The unique ID of the metric to remove.</td></tr></tbody></table>

#### Request Body

None

#### Permissions

Users who are not administrators can delete a metric for which they have explicit or implicit Read (view) and Delete permission.

#### Required scope for JWT authorization

Introduced in Tableau Cloud June 2022 (API 3.16) and Tableau Server 2022.3 (API 3.17).

```
tableau:metrics:delete
```

For more information, see [Access scopes for UATs](https://help.tableau.com/current/api/cloud-manager/en-us/docs/unified_access_tokens.html#scopes) (Cloud) and access scopes for connected apps: [Cloud](https://help.tableau.com/current/online/en-us/connected_apps_scopes.htm), [Server-Windows](https://help.tableau.com/current/server/en-us/connected_apps_scopes.htm), or [Server-Linux](https://help.tableau.com/current/server-linux/en-us/connected_apps_scopes.htm).

#### Response Code

204

#### Response Body

None

#### Version

Version 3.9 and later. For more information, see [REST API and Resource Versions](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm).

#### Errors

<table class="api-error-table"><colgroup><col class="api-error-table-col-1"> <col class="api-error-table-col-2"> <col class="api-error-table-col-3"> <col></colgroup><tbody><tr><th>HTTP status</th><th><code>error</code> Code</th><th>Condition</th><th>Details</th></tr><tr><td>404</td><td>404000</td><td>Site not found</td><td>The site ID in the URI doesn't correspond to an existing site.</td></tr><tr><td>404</td><td>404006</td><td>Metric not found</td><td>The metric ID in the URI doesn't correspond to an existing metric.</td></tr><tr><td>405</td><td>405000</td><td>Invalid request method</td><td>Request type was not <span class="api-command-ref">DELETE</span>.</td></tr></tbody></table>

For more information, see [Handling Errors](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_errors.htm).

#### Example

`curl "http://MY-SERVER/api/3.9/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/metrics/6561daa3-20e8-407f-ba09-709b178c0b4a" -X DELETE -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"`

The response contains no body (data) for a successful delete operation. The HTTP response code is 204 if the delete operation succeeded.

## Get Metric - Retired in API 3.22

**Retired in API 3.22 (Cloud February 2024 / Server 2024.2)**

Tableau's legacy metrics feature was retired in Tableau Cloud in February 2024 and in Tableau Server version 2024.2. In October 2023, Tableau retired the ability to embed legacy metrics in Tableau Cloud and in Tableau Server version 2023.3. With Tableau Pulse, we've developed an improved experience to track metrics and ask questions of your data. For more information, see [Create Metrics with Tableau Pulse](https://help.tableau.com/current/online/en-us/pulse_create_metrics.htm) to learn about the new experience and [Create and Troubleshoot Metrics (Retired)](https://help.tableau.com/current/online/en-us/metrics_create.htm) for the retired feature.

Returns the details of the specified metric.

#### URI

GET /api/api-version/sites/site-id/metrics/metric-luid;

#### Parameter Values

<table class="api-parameters-table"><colgroup><col class="api-parameters-table-col-1-wide"> <col></colgroup><tbody><tr><td><span class="api-placeholder">api-version</span></td><td>The version of the API to use, such as <code><span class="mc-variable Variables.REST-API-Version variable">3.29</span></code>. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm" class="xref">REST API and Resource Versions</a>.</td></tr><tr><td><span class="api-placeholder">site-id</span></td><td>The unique ID of the site that contains the metric.&gt;</td></tr><tr><td><span class="api-placeholder">metric-luid</span></td><td>The unique ID of the metric.</td></tr></tbody></table>

#### Request Body

None

#### Permissions

This method can be called by any user, but those without administrator permissions will only be able to view responses for metrics they own.

#### Required scope for JWT authorization

Introduced in Tableau Cloud June 2022 (API 3.16) and Tableau Server 2022.3 (API 3.17).

```
tableau:content:read
```

For more information, see [Access scopes for UATs](https://help.tableau.com/current/api/cloud-manager/en-us/docs/unified_access_tokens.html#scopes) (Cloud) and access scopes for connected apps: [Cloud](https://help.tableau.com/current/online/en-us/connected_apps_scopes.htm), [Server-Windows](https://help.tableau.com/current/server/en-us/connected_apps_scopes.htm), or [Server-Linux](https://help.tableau.com/current/server-linux/en-us/connected_apps_scopes.htm).

#### Response Code

200

#### Response Body

                `<tsResponse>   <metric id="metric-id" 	name="metric-name" 	description="metric-description" 	webpageUrl="metric-content-url" 	createdAt="datetime-created" 	updatedAt="datetime-updated" 	suspended="suspended-flag">   	  <project id="project-id" 	    name="project-name"/> 	  <owner id="metric-owner-id"/> 	  <tags> 	    <tag label="tag"/> 	    <!-- ... additional tags ... --> 	  </tags> 	  <underlyingView id="view-id"/>   </metric> </tsResponse>`
      

#### Version

Version 3.9 and later. For more information, see [REST API and Resource Versions](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm).

#### Errors

<table class="api-error-table"><colgroup><col class="api-error-table-col-1"> <col class="api-error-table-col-2"> <col class="api-error-table-col-3"> <col></colgroup><tbody><tr><th>HTTP status</th><th><code>error</code> Code</th><th>Condition</th><th>Details</th></tr><tr><td>400</td><td>400000</td><td>Bad request</td><td>The content of the request body is missing or incomplete, or contains malformed XML.</td></tr><tr><td>403</td><td>403004</td><td>Permissions issue</td><td>The user does not have permissions to read the specified metric.</td></tr><tr><td>404</td><td>404000</td><td>Site not found</td><td>The site ID in the URI doesn't correspond to an existing site.</td></tr><tr><td>404</td><td>404004</td><td>Metric not found</td><td>The metric ID in the URI doesn't correspond to an existing metric.</td></tr></tbody></table>

#### Example

`curl "http://MY-SERVER/api/3.9/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/metrics/6561daa3-20e8-407f-ba09-709b178c0b4a" -X GET -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"`

**Response Body**

                    `<tsResponse>   <metric id="6561daa3-20e8-407f-ba09-709b178c0b4a"     name="my metric name"     description="Description of my metric."     webpageUrl="https://MY-SERVER/#/site/site-name/metrics/site-num"     createdAt="2020-01-02T01:02:03Zd"     updatedAt="2020-01-02T01:02:03Z"     suspended="true">       <project id="32e79edb-6cfd-47dc-ad79-e8ec2fbb1d33"         name="my project name"/>       <owner id="32e79edb-6cfd-47dc-ad79-e8ec2fbb1d33"/>       <tags/>       <underlyingView id="29dae0cd-1862-4a20-a638-e2c2dfa682d4"/>   </metric> </tsResponse>`
        

## Get Metric Data - Retired in API 3.22

**Retired in API 3.22 (Cloud February 2024 / Server 2024.2)**

Tableau's legacy metrics feature was retired in Tableau Cloud in February 2024 and in Tableau Server version 2024.2. In October 2023, Tableau retired the ability to embed legacy metrics in Tableau Cloud and in Tableau Server version 2023.3. With Tableau Pulse, we've developed an improved experience to track metrics and ask questions of your data. For more information, see [Create Metrics with Tableau Pulse](https://help.tableau.com/current/online/en-us/pulse_create_metrics.htm) to learn about the new experience and [Create and Troubleshoot Metrics (Retired)](https://help.tableau.com/current/online/en-us/metrics_create.htm) for the retired feature.

Returns the data for the specified metric as comma separated (CSV) format. The maximum number of rows returned is 10,000.

#### URI

GET /api/api-version/sites/site-luid/metrics/metric-luid/data

#### Parameter Values

<table class="api-parameters-table"><colgroup><col class="api-parameters-table-col-1-wide"> <col></colgroup><tbody><tr><td><span class="api-placeholder">api-version</span></td><td>The version of the API to use, such as <code><span class="mc-variable Variables.REST-API-Version variable">3.29</span></code>. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm" class="xref">REST API and Resource Versions</a>.</td></tr><tr><td><span class="api-placeholder">site-luid</span></td><td>The LUID of the site that contains the data source to get revisions for.</td></tr><tr><td><span class="api-placeholder">metric-luid</span></td><td>The LUID of the metric whose data should be returned.</td></tr></tbody></table>

#### Request Body

None

#### Permissions

Tableau administrators, and non-administrator and users with Read capability for a metric, will be able to get its data.

#### Required scope for JWT authorization

Introduced in Tableau Cloud June 2022 (API 3.16) and Tableau Server 2022.3 (API 3.17).

```
tableau:metrics:download
```

For more information, see [Access scopes for UATs](https://help.tableau.com/current/api/cloud-manager/en-us/docs/unified_access_tokens.html#scopes) (Cloud) and access scopes for connected apps: [Cloud](https://help.tableau.com/current/online/en-us/connected_apps_scopes.htm), [Server-Windows](https://help.tableau.com/current/server/en-us/connected_apps_scopes.htm), or [Server-Linux](https://help.tableau.com/current/server-linux/en-us/connected_apps_scopes.htm).

#### Response Code

200

#### Response Body

```
your_timestamp_column_name,your_measure_column_nametimestamp_1,measure_1timestamp_2,measure_1
```

#### Version

Introduced Tableau Cloud June 2022 (API 3.16). Not currently available for Tableau Server. For more information, see [REST API and Resource Versions](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm).

#### Errors

<table class="api-error-table"><colgroup><col class="api-error-table-col-1"> <col class="api-error-table-col-2"> <col class="api-error-table-col-3"> <col></colgroup><tbody><tr><th>HTTP status</th><th><code>error</code> Code</th><th>Condition</th><th>Details</th></tr><tr><td>400</td><td>40000</td><td>Bad request</td><td>The LUID of the site or metric was malformed.</td></tr><tr><td>401</td><td>40100</td><td>Not authorized</td><td>The authentication token provided in the request header was invalid or has expired.</td></tr><tr><td>403</td><td>403054</td><td>Not authorized</td><td>A non-administrator user attempted to get metric data, but does not have sufficient permissions.</td></tr><tr><td>404</td><td>404000</td><td>Site not found</td><td>The site LUIID in the URI doesn't correspond to an existing site.</td></tr><tr><td>404</td><td></td><td>Metric not found</td><td>The metric LUID in the URI doesn't correspond to an existing data source.</td></tr><tr><td>405</td><td>405000</td><td>Invalid request method</td><td>Request type was not <span class="api-command-ref">GET</span>.</td></tr><tr><td>429</td><td>405000</td><td>Too many requests</td><td>The concurrent request limit for the site was exceeded. Retry after a pause.</td></tr></tbody></table>

For more information, see [Handling Errors](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_errors.htm).

#### Example

Request command line:

`curl "http://MY-SERVER/api/3.16/sites/1edc53ac-e247-4870-9fd3-6fad0ce5f84d/metrics/2474164d-8d37-4a4c-abc7-c2070fd25fd5/data" -X GET -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"`

Response:

```
Timestamp,Measure
2021-12-31:11:59:57-0800,3
2021-12-31:11:59:58-0800,2
2021-12-31:11:59:59-0800,1
```

## List Metrics for Site - Retired in API 3.22

**Retired in API 3.22 (Cloud February 2024 / Server 2024.2)**

Tableau's legacy metrics feature was retired in Tableau Cloud in February 2024 and in Tableau Server version 2024.2. In October 2023, Tableau retired the ability to embed legacy metrics in Tableau Cloud and in Tableau Server version 2023.3. With Tableau Pulse, we've developed an improved experience to track metrics and ask questions of your data. For more information, see [Create Metrics with Tableau Pulse](https://help.tableau.com/current/online/en-us/pulse_create_metrics.htm) to learn about the new experience and [Create and Troubleshoot Metrics (Retired)](https://help.tableau.com/current/online/en-us/metrics_create.htm) for the retired feature.

Returns the metrics configured for a site.

If the user is not an administrator, the method returns just the metrics for which the user has permissions.

#### URI

GET /api/api-version/sites/site-id/metrics

GET /api/api-version/sites/site-id/metrics?filter=filter-expression

GET /api/api-version/sites/site-id/metrics?sort=sort-expression

GET /api/api-version/sites/site-id/metrics?pageSize=page-size&pageNumber=page-number

GET /api/api-version/sites/site-id/metrics?fields=field-expression

#### Parameter Values

<table class="api-parameters-table"><colgroup><col class="api-parameters-table-col-1-wide"> <col></colgroup><tbody><tr><td><span class="api-placeholder">api-version</span></td><td>The version of the API to use, such as <code><span class="mc-variable Variables.REST-API-Version variable">3.29</span></code>. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm" class="xref">REST API and Resource Versions</a>.</td></tr><tr><td><span class="api-placeholder">site-id</span></td><td>The ID of the site that contains the metrics.</td></tr><tr><td><span class="api-placeholder">filter-expression</span></td><td>(Optional) An expression that lets you specify a subset of metrics to return. You can filter on predefined fields such as metric <code>name</code>, or attributes of the associated <code>owner</code> or <code>project</code>. You can include multiple filter expressions. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_filtering_and_sorting.htm">Filtering and Sorting</a>.</td></tr><tr><td><span class="api-placeholder">sort-expression</span></td><td>(Optional) An expression that lets you specify the order in which metric information is returned. If you do not specify a sort expression, the sort order of the information that's returned is undefined. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_filtering_and_sorting.htm">Filtering and Sorting</a>.</td></tr><tr><td><span class="api-placeholder">page-size</span></td><td>(Optional) The number of items to return in one response. The minimum is 1. The maximum is 1000. The default is 100. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_paging.htm">Paginating Results</a>.</td></tr><tr><td><span class="api-placeholder">page-number</span></td><td>(Optional) The offset for paging. The default is 1. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_paging.htm">Paginating Results</a>.</td></tr><tr><td><span class="api-placeholder">field-expression</span></td><td>(Optional) An expression that lets you specify the set of available fields to return. You can qualify the return values based upon predefined keywords such as <code>_all_</code> or <code>_default_</code>, and you can specify individual fields for the metrics or other supported resources. You can include multiple field expressions in a request. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_fields.htm">Using Fields in the REST API</a>.</td></tr></tbody></table>

**Note**: The filter and sort parameters can be combined with each other and with paging parameters and fields parameters using an ampersand (**`&`**).

#### Request Body

None

#### Permissions

Users who are not administrators can get only the metrics for which they have implicit or explicit Read (view) permissions.

#### Required scope for JWT authorization

Introduced in Tableau Cloud June 2022 (API 3.16) and Tableau Server 2022.3 (API 3.17).

                `tableau:content:read`
            

For more information, see [Access scopes for UATs](https://help.tableau.com/current/api/cloud-manager/en-us/docs/unified_access_tokens.html#scopes) (Cloud) and access scopes for connected apps: [Cloud](https://help.tableau.com/current/online/en-us/connected_apps_scopes.htm), [Server-Windows](https://help.tableau.com/current/server/en-us/connected_apps_scopes.htm), or [Server-Linux](https://help.tableau.com/current/server-linux/en-us/connected_apps_scopes.htm).

#### Response Code

200

#### Response Body

                    `<tsResponse>   <pagination pageNumber="page-number"      pageSize="page-size"      totalAvailable="total-available" />   <metrics>     <metric id="metric-id" 		name="name" 		description="metric-description" 		webpageurl="metric-webpageurl"         createdAt="datetime-created" 	    updatedAt="datetime-updated" 	    suspended="suspended-flag" > 	      <project id="project-id" name="project-name" /> 	      <owner id="user-id" /> 	      <tags> 	        <tag label="tag"/> 	        ... additional tags ... 	     </tags> 	<underlyingView" id="view-id" />    </metric>    ... additional metrics ...   </metrics> </tsResponse>`
        

The datetime-created and datetime-updated attribute values are returned in UTC format (YYYY-MM-DDTHH:MM:SSZ).

#### Version

Version 3.9 and later. For more information, see [REST API and Resource Versions](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm).

#### Errors

<table class="api-error-table"><colgroup><col class="api-error-table-col-1"> <col class="api-error-table-col-2"> <col class="api-error-table-col-3"> <col></colgroup><tbody><tr><th>HTTP status</th><th><code>error</code> Code</th><th>Condition</th><th>Details</th></tr><tr><td>400</td><td>400006</td><td>Invalid page number</td><td>The page number is not an integer, is less than one, or is greater than the final page number for users at the requested page size.</td></tr><tr><td>400</td><td>400007</td><td>Invalid page size</td><td>The page size parameter is not an integer, or is less than one.</td></tr><tr><td>403</td><td>403014</td><td>Page size exceeds upper limit</td><td>The page size parameter exceeds the system-wide upper limit of 1000.</td></tr><tr><td>403</td><td>403018</td><td>Read forbidden</td><td>A non-administrator user attempted to query metrics for the site, but the caller doesn't have <span class="api-command-ref">Read</span> permission.</td></tr><tr><td>404</td><td>404000</td><td>Site not found</td><td>The site ID in the URI doesn't correspond to an existing site.</td></tr><tr><td>404</td><td>404004</td><td>Metrics not found</td><td>No metrics are configured for this site.</td></tr><tr><td>405</td><td>405000</td><td>Invalid request method</td><td>Request type was not <span class="api-command-ref">GET</span>.</td></tr></tbody></table>

For more information, see [Handling Errors](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_errors.htm).

#### Example

`curl "http://MY-SERVER/api/3.29/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/metrics" -X GET -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"`

**Example response body:**

                    `<tsResponse version-and-namespace-settings>   <pagination pageNumber="1" pageSize="100" totalAvailable="27"/>   <metrics>     <metric id="1a1b1c1d-2e2f-2a2b-3c3d-3e3f4a4b4c4d" 		name="my first metric"         description="Description of my_first_metric." 		webpageUrl="https://MY-SERVER/#/site/site-name/metrics/site-num" 		createdAt="2013-03-30T22:32:35Z" updatedAt="2016-01-13T01:00:02Z" 		suspended="false" > 	      <project id="1f2f3e4e-5d6d-7c8c-9b0b-1a2a3f4f5e6e" name="Tableau Samples"/> 	      <owner id="9f9e9d9c-8b8a-8f8e-7d7c-7b7a6f6d6e6d"/> 	      <tags/> 		underlyingView="29dae0cd-1862-4a20-a638-e2c2dfa682d4"     </metric>     <metric id="29dae0cd-1862-4a20-a638-e2c2dfa682d4a" name="my_second_metric" 		description="Description of my second metric." 		webpageUrl="https://MY-SERVER/#/site/site-name/metrics/site-num"         createdAt="2014-02-19T10:19:23Z" updatedAt="2015-12-29T013:23:45Z" 		suspended="false" > 		  <project id="08a7b6b5-b4ba-be3a-4d2d-1e9e59a8a7b6" name="default"/> 	      <owner id="9f9e9d9c-8b8a-8f8e-7d7c-7b7a6f6d6e6d"/> 	      <tags>           <tag label="training" ></tags>     </metric> 	<!-- ...more metrics ... --:>   </metrics>   </tsResponse>`
        

## Update Metric - Retired in API 3.22

**Retired in API 3.22 (Cloud February 2024 / Server 2024.2)**

Tableau's legacy metrics feature was retired in Tableau Cloud in February 2024 and in Tableau Server version 2024.2. In October 2023, Tableau retired the ability to embed legacy metrics in Tableau Cloud and in Tableau Server version 2023.3. With Tableau Pulse, we've developed an improved experience to track metrics and ask questions of your data. For more information, see [Create Metrics with Tableau Pulse](https://help.tableau.com/current/online/en-us/pulse_create_metrics.htm) to learn about the new experience and [Create and Troubleshoot Metrics (Retired)](https://help.tableau.com/current/online/en-us/metrics_create.htm) for the retired feature.

Updates the owner, project, suspended status, or name of the specified metric.

#### URI

PUT /api/api-version/sites/site-id/metrics/metric-luid

#### Parameter Values

<table class="api-parameters-table"><colgroup><col class="api-parameters-table-col-1-wide"> <col></colgroup><tbody><tr><td><span class="api-placeholder">api-version</span></td><td>The version of the API to use, such as <code><span class="mc-variable Variables.REST-API-Version variable">3.29</span></code>. For more information, see <a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm" class="xref">REST API and Resource Versions</a>.</td></tr><tr><td><span class="api-placeholder">site-id</span></td><td>The ID of the site that contains the data source.</td></tr><tr><td><span class="api-placeholder">metric-luid</span></td><td>The unique ID of the data source to update.</td></tr></tbody></table>

#### Request Body

                    `<tsRequest>   <metric 	description="updated-metric-description"     name="updated-name" 	suspended="updated-suspended-flag" >       <project id="updated-project-id"/>       <owner id="updated-owner-id"/>   </metric> </tsRequest>`
        

#### Attribute Values

<table class="api-parameters-table"><colgroup><col class="api-parameters-table-col-1-wide"> <col></colgroup><tbody><tr><td><span class="api-placeholder">updated-metric-description</span></td><td>(Optional) The description to use for the updated metric.</td></tr><tr><td><span class="api-placeholder">updated-metric-name</span></td><td>(Optional) The name to use for the updated metric.</td></tr><tr><td><span class="api-placeholder">updated-suspended-flag</span></td><td>(Optional) Boolean. If <code>true</code> the metric is suspended. The default is <code>false</code>.</td></tr><tr><td><span class="api-placeholder">updated-project-id</span></td><td>(Optional) The ID of a project to add the metric to.</td></tr><tr><td><span class="api-placeholder">updated-owner-id</span></td><td>(Optional) The ID of a user to assign the metric to as owner.</td></tr></tbody></table>

Any combination of the attributes inside the <metric> element is valid. Only the attributes and child elements that are included result in updates to the data source. If no attributes or nested elements are included, no update is made.

If the <project> element is included, the id attribute must be included, and any other attributes of the <project> element are ignored.

If the <owner> element is included, the id attribute must be included, and any other attributes of the owner are ignored.

#### Permissions

Tableau users who are server or site administrators can change the owner for a metric. Users who are not administrators can move a metric from one project to another if they have permissions to the metric. The user must also have permissions to the current (source) project or are a project leader for the current project, and have Write permission for the destination project.

```
tableau:metrics:update
```

#### Access Scope

Scope added in API 3.27 (Tableau Cloud December 2025 / Server 2025.3).

```
tableau:metrics:update
```

For more information, see [Access scopes for UATs](https://help.tableau.com/current/api/cloud-manager/en-us/docs/unified_access_tokens.html#scopes) (Cloud) and access scopes for connected apps: [Cloud](https://help.tableau.com/current/online/en-us/connected_apps_scopes.htm), [Server-Windows](https://help.tableau.com/current/server/en-us/connected_apps_scopes.htm), or [Server-Linux](https://help.tableau.com/current/server-linux/en-us/connected_apps_scopes.htm).

#### Response Code

200

#### Response Body

                    `<tsResponse>   <metric id="metric-id" 	name="metric-name" 	description="metric-description" 	webpageUrl="webpageUrl-url" 	createdAt="datetime-created" 	updatedAt="datetime-updated" 	suspended="suspended-flag""> 	  <project id="new-project-id" /> 	  <owner id="new-owner-id" /> 	  <tags> 	    <tag label="tag"/> 	    <!--  ... additional tags ... --> 	  </tags> 	</metric> </tsResponse>`
        

The datetime-created and datetime-updated attribute values are returned in UTC format (YYYY-MM-DDTHH:MM:SSZ).

#### Version

Version 2.0 and later. For more information, see [REST API and Resource Versions](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_versions.htm).

#### Errors

<table class="api-error-table"><colgroup><col class="api-error-table-col-1"> <col class="api-error-table-col-2"> <col class="api-error-table-col-3"> <col></colgroup><tbody><tr><th>HTTP status</th><th><code>error</code> Code</th><th>Condition</th><th>Details</th></tr><tr><td>400</td><td>400000</td><td>Bad request</td><td>The content of the request body is missing or incomplete, or contains malformed XML.</td></tr><tr><td>400</td><td>400123</td><td>Unkown error</td><td>The metric could not be updated for an unknown reason.</td></tr><tr><td>403</td><td>403119</td><td>Owner update forbidden</td><td>The user does not have administrator permissions to change the owner for the metric.</td></tr><tr><td>403</td><td>403120</td><td>Project update forbidden</td><td>The user doesn't have <span class="api-command-ref">Write</span> permission for the project they are trying to move the metric to.</td></tr><tr><td>403</td><td>403118</td><td>Name update forbidden</td><td>The user does not have administrator permissions to change the name for the metric.</td></tr><tr><td>404</td><td>404000</td><td>Site not found</td><td>The site ID in the URI doesn't correspond to an existing site.</td></tr><tr><td>404</td><td>404002</td><td>Owner not found</td><td>The owner ID in the request body doesn't correspond to an existing owner.</td></tr><tr><td>404</td><td>404004</td><td>Metric not found</td><td>The metrice ID in the URI doesn't correspond to an existing metric.</td></tr><tr><td>404</td><td>404005</td><td>Project not found</td><td>The project ID in the request body doesn't correspond to an existing project.</td></tr><tr><td>405</td><td>405000</td><td>Invalid request method</td><td>Request type was not <span class="api-command-ref">PUT</span>.</td></tr><tr><td>409</td><td>409015</td><td>Metric name conflict</td><td>The metric name in the request already belongs to the specified site. For the purpose of uniqueness checks, metric names are case-insensitive.</td></tr></tbody></table>

For more information, see [Handling Errors](https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_errors.htm).

#### Example

`curl "http://MY-SERVER/api/3.29/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/metrics/6561daa3-20e8-407f-ba09-709b178c0b4a" -X PUT -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @update-metric.xml`

**Content of update-metric.xml**

                        `<tsRequest>    <metric     name="New Name"     description="New Description"     suspended="true"> 	  <project id="49b4cce3-771f-4ee3-a932-5d42fa8c0e9d"/> 	 <owner id="f1539d08-114c-4de9-a830-c9a0674ec026"/>   </metric> </tsRequest>`
          

**Example response body:**

                    `<tsResponse >   <metric id="1a1b1c1d-2e2f-2a2b-3c3d-3e3f4a4b4c4d"     name="my first metric"     description="Description of my_first_metric."     webpageUrl="https://MY-SERVER/#/site/site-name/metrics/site-num"     createdAt="2013-03-30T22:32:35Z" updatedAt="2016-01-13T01:00:02Z"     suspended="false" >  	    <project id="1f2f3e4e-5d6d-7c8c-9b0b-1a2a3f4f5e6e" name="Tableau Samples"/>     	<owner id="9f9e9d9c-8b8a-8f8e-7d7c-7b7a6f6d6e6d"/>    	  <tags/>       underlyingView="29dae0cd-1862-4a20-a638-e2c2dfa682d4"   </metric> </tsResponse>`