Skip to main content

synthetics_mobile_tests

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

Overview

Namesynthetics_mobile_tests
TypeResource
Iddatadog.monitoring.synthetics_mobile_tests

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringName of the test. (example: Example test name)
monitor_idinteger (int64)The associated monitor ID.
public_idstringThe public ID of the test. (example: 123-abc-456)
configobjectConfiguration object for a Synthetic mobile test.
device_idsarrayArray with the different device IDs used to run the test.
messagestringNotification message associated with the test. (example: Notification message)
optionsobjectObject describing the extra options for a Synthetic test.
statusstringDefine whether you want to start (live) or pause (paused) a Synthetic test. (live, paused) (example: live)
stepsarrayArray of steps for the test.
tagsarrayArray of tags attached to the test.
typestringType of the Synthetic test, mobile. (mobile) (default: mobile, example: mobile)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_mobile_testselectpublic_idGet the detailed configuration associated with<br />a Synthetic mobile test.
create_synthetics_mobile_testinsertconfig, name, options, type, messageCreate a Synthetic mobile test.
update_mobile_testreplacepublic_id, config, name, options, type, messageEdit the configuration of a Synthetic mobile test.

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
public_idstringThe public ID of the test to get details from.
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 the detailed configuration associated with<br />a Synthetic mobile test.

SELECT
name,
monitor_id,
public_id,
config,
device_ids,
message,
options,
status,
steps,
tags,
type
FROM datadog.monitoring.synthetics_mobile_tests
WHERE public_id = '{{ public_id }}' -- required
;

INSERT examples

Create a Synthetic mobile test.

INSERT INTO datadog.monitoring.synthetics_mobile_tests (
config,
device_ids,
message,
name,
options,
status,
steps,
tags,
type
)
SELECT
'{{ config }}' /* required */,
'{{ device_ids }}',
'{{ message }}' /* required */,
'{{ name }}' /* required */,
'{{ options }}' /* required */,
'{{ status }}',
'{{ steps }}',
'{{ tags }}',
'{{ type }}' /* required */
RETURNING
name,
monitor_id,
public_id,
config,
device_ids,
message,
options,
status,
steps,
tags,
type
;

REPLACE examples

Edit the configuration of a Synthetic mobile test.

REPLACE datadog.monitoring.synthetics_mobile_tests
SET
config = '{{ config }}',
device_ids = '{{ device_ids }}',
message = '{{ message }}',
name = '{{ name }}',
options = '{{ options }}',
status = '{{ status }}',
steps = '{{ steps }}',
tags = '{{ tags }}',
type = '{{ type }}'
WHERE
public_id = '{{ public_id }}' --required
AND config = '{{ config }}' --required
AND name = '{{ name }}' --required
AND options = '{{ options }}' --required
AND type = '{{ type }}' --required
AND message = '{{ message }}' --required
RETURNING
name,
monitor_id,
public_id,
config,
device_ids,
message,
options,
status,
steps,
tags,
type;