Synthetic monitor executions API v2 - GET HTTP monitor
Gets the result of the most recent execution of the specified HTTP monitor.
The request produces an application/json
payload.
GET | ManagedDynatrace for Government | https://{your-domain}/e/{your-environment-id}/api/v2/synthetic/execution/{monitorId}/{resultType} |
SaaS | https://{your-environment-id}.live.dynatrace.com/api/v2/synthetic/execution/{monitorId}/{resultType} | |
Environment ActiveGate | https://{your-activegate-domain}/e/{your-environment-id}/api/v2/synthetic/execution/{monitorId}/{resultType} |
Authentication
To execute this request, you need an access token with one of the following scopes:
DataExport
ExternalSyntheticIntegration
ReadSyntheticData
To learn how to obtain and use it, see Tokens and authentication.
Parameters
Parameter | Type | Description | In | Required |
---|---|---|---|---|
monitorId | string | Identifier of the HTTP monitor for which last execution result is returned. | path | required |
resultType | string | Defines the result type of the last HTTP monitor's execution. | path | required |
locationId | string | Filters the results to those executed by specified Synthetic location. Specify the ID of the location. | query | optional |
Response
Response codes
Code | Type | Description |
---|---|---|
200 | Monitor | Success. The response contains detailed data. |
Response body objects
The MonitorExecutionResults
object
Results of the execution of all HTTP monitor's requests.
Element | Type | Description |
---|---|---|
monitorId | string | Monitor id. |
locationsExecutionResults | Location | The list with the results of the requests executed on assigned locations. |
The LocationExecutionResults
object
Results of the execution HTTP monitor's requests at a given location
Element | Type | Description |
---|---|---|
locationId | string | Location id. |
executionId | string | Execution id. |
requestResults | Monitor | The list of the monitor's request results executed on this location. |
The MonitorRequestExecutionResult
object
A result of the execution HTTP monitor's request.
The object doesn't provide any parameters.
The ExecutionStep
object
Contains detailed information about the monitor's step execution.
Element | Type | Description |
---|---|---|
monitorType | string | Defines the actual set of fields depending on the value. See one of the following objects:
|
The MonitorRequestHeader
object
A header of the Http request
Element | Type | Description |
---|---|---|
name | string | Header's name. |
value | string | Header's value. |
The CustomLogLine
object
A custom script log line
Element | Type | Description |
---|---|---|
timestamp | integer | A timestamp of this log message |
logLevel | string | Log level of the message |
message | string | The message |
Response body JSON model
{
"monitorId": "HTTP_CHECK-12B428F6D37A9197",
"locationsExecutionResults": [
{
"locationId": "7804738439930364165",
"executionId": "6136172183050046113",
"requestResults": [
{
"requestId": "HTTP_CHECK_STEP-53071FC3C4F72E28",
"requestName": "Request name",
"sequenceNumber": 1,
"startTimestamp": 1615806570884,
"engineId": 338502283,
"publicLocation": false,
"url": "https://www.examplePage.com",
"method": "GET",
"requestBody": "",
"requestHeaders": [
{
"name": "User-Agent",
"value": "DynatraceSynthetic/1.215.1"
},
{
"name": "X-Dynatrace-Visit",
"value": "6136172183050046113"
},
{
"name": "X-Dynatrace-Test",
"value": "HTTP_CHECK-12B428F6D37A9197"
}
],
"responseStatusCode": 200,
"responseBody": "<html><head>Title</head><body>Main Page</body></html>",
"responseSize": 1112,
"responseBodySizeLimitExceeded": false,
"responseHeaders": [
{
"name": "Date",
"value": "Mon, 15 Mar 2021 11:09:30 GMT"
},
{
"name": "Content-Language",
"value": "en"
}
],
"resolvedIps": [
"80.252.0.145"
],
"errorCode": 0,
"responseMessage": "OK",
"peerCertificateExpiryDate": 1647302399000,
"peerCertificateDetails": "[Certificate details]",
"totalTime": 238,
"hostNameResolutionTime": 26,
"tcpConnectTime": 15,
"tlsHandshakeTime": 8,
"timeToFirstByte": 96,
"redirectionTime": 70,
"waitingTime": 47,
"redirectsCount": 1,
"failureMessage": ""
}
]
}
]
}