Skip to main content

rum_metrics

Creates, updates, deletes, gets or lists a rum_metrics resource.

Overview

Namerum_metrics
TypeResource
Iddatadog.digital_experience.rum_metrics

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringThe name of the RUM-based metric. (example: rum.sessions.webui.count)
attributesobjectThe object describing a Datadog RUM-based metric.
typestringThe type of the resource. The value should always be rum_metrics. (rum_metrics) (default: rum_metrics, example: rum_metrics)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_rum_metricselectmetric_idGet a specific RUM-based metric from your organization.
list_rum_metricsselectGet the list of configured RUM-based metrics with their definitions.
create_rum_metricinsertdataCreate a metric based on your organization's RUM data.<br />Returns the RUM-based metric object from the request body when the request is successful.
update_rum_metricupdatemetric_id, dataUpdate a specific RUM-based metric from your organization.<br />Returns the RUM-based metric object from the request body when the request is successful.
delete_rum_metricdeletemetric_idDelete a specific RUM-based metric from your organization.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
metric_idstringThe name of the RUM-based metric.
sitestringThe Datadog site (region) for your organization, for example datadoghq.com, us3.datadoghq.com, us5.datadoghq.com, ap1.datadoghq.com, ap2.datadoghq.com, datadoghq.eu, ddog-gov.com. Resolved from the DD_SITE environment variable when set. Optional: defaults to datadoghq.com, or the value of the DD_SITE environment variable when set; a WHERE value overrides both.

SELECT examples

Get a specific RUM-based metric from your organization.

SELECT
id,
attributes,
type
FROM datadog.digital_experience.rum_metrics
WHERE metric_id = '{{ metric_id }}' -- required
;

INSERT examples

Create a metric based on your organization's RUM data.<br />Returns the RUM-based metric object from the request body when the request is successful.

INSERT INTO datadog.digital_experience.rum_metrics (
data
)
SELECT
'{{ data }}' /* required */
RETURNING
data
;

UPDATE examples

Update a specific RUM-based metric from your organization.<br />Returns the RUM-based metric object from the request body when the request is successful.

UPDATE datadog.digital_experience.rum_metrics
SET
data = '{{ data }}'
WHERE
metric_id = '{{ metric_id }}' --required
AND data = '{{ data }}' --required
RETURNING
data;

DELETE examples

Delete a specific RUM-based metric from your organization.

DELETE FROM datadog.digital_experience.rum_metrics
WHERE metric_id = '{{ metric_id }}' --required
;