Datadog Integration with API Monitoring
Datadog provides a monitoring platform that tracks and scales with your dynamic cloud infrastructure. When connected with your API Monitoring account, you can create Events and Metrics to use in your Datadog dashboards and alerts.
- Integrate Your Datadog Account with API Monitoring
- Connect Datadog to Individual Tests
- Disconnect Datadog from Account or Test
Integrate Your Datadog Account with API Monitoring
Follow these steps:
- From your Datadog account, Create an API Key and copy it to your clipboard.
- Go to API Monitoring. Click the Profile & Account Settings icon and select Connected Services.
- In Connect a Service, select Connect Datadog.
A new page Connect Datadog opens. - Select your Region.
- In the API Key field, enter the generated Datadog API Key.
- (Optional) Check the box for the following options:
Send events for completed test runs.
Send metrics on all API test runs and individual test requests. - Select Connect Account.
Connect Datadog to Individual Tests
If you need different Datadog settings for individual tests (for example, send events on some test runs and metrics on others), you can go through the connection process multiple times and enable each individual connected service on a per-test or per-bucket basis.
Follow these steps:
- Select a test and click Edit Test.
- Expand the Test Settings drop-down list and scroll down to the Integrations section.
The available integrations are shown. - For Enable Integrations with 3rd party services, toggle the slider for Datadog ON.
Events
When the option to create Datadog Events is selected, a new event will be created for each test run. The event will be tagged with the bucket, team, and other test information.
Metrics
When the option to create Datadog Metrics is enabled, metrics will be created for the test run as a whole, along with each individual request step within a test.
RunscopeTestRun
- Total assertions passed/failed/defined
- Total variables passed/failed/defined
- Total scripts passed/failed/defined
- Data iterations passed/failed/defined
- Requests executed
- Total response time (ms) for all requests
- Pass/fail counter (either 1 or 0)
RunscopeTestRequest
- Assertions passed/failed/defined
- Variables passed/failed/defined
- Scripts passed/failed/defined
- Response time (ms)
- Response body size (bytes)
- Response status code
Each test run and request metric will be tagged with information about the test, environment, bucket and team. Additionally, test run metrics are tagged with the status of the run while test request metrics are tagged with the requested URL and HTTP method.
Disconnect Datadog from Account or Test
You can disconnect Datadog at any time by disconnecting the service in your team settings.
Follow these steps for disconnecting Datadog from your account:
- In API Monitoring, click the Profile & Account Settings icon on top-right.
- Select Connected Services.
- Select the Datadog connection that you want to remove and click Disconnect.
The Datadog connection is removed from the list of connected services.
To disconnect Datadog from a specific test:
- Select a test and click Edit Test.
- Expand the Test Settings drop-down list and scroll down to the Integrations section.
The available integrations are shown. - For Enable Integrations with 3rd party services, toggle the slider for Datadog OFF.