@itentialopensource/adapter-datadog 0.7.4 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/TAB2.md CHANGED
@@ -2,375 +2,56 @@
2
2
 
3
3
  ## Table of Contents
4
4
 
5
- - [Getting Started](#getting-started)
6
- - [Helpful Background Information](#helpful-background-information)
7
- - [Prerequisites](#prerequisites)
8
- - [How to Install](#how-to-install)
9
- - [Testing](#testing)
10
- - [Configuration](#configuration)
11
- - [Example Properties](#example-properties)
12
- - [Connection Properties](#connection-properties)
13
- - [Authentication Properties](#authentication-properties)
14
- - [Healthcheck Properties](#healthcheck-properties)
15
- - [Request Properties](#request-properties)
16
- - [SSL Properties](#ssl-properties)
17
- - [Throttle Properties](#throttle-properties)
18
- - [Proxy Properties](#proxy-properties)
19
- - [Mongo Properties](#mongo-properties)
20
- - [Device Broker Properties](#device-broker-properties)
21
- - [Using this Adapter](#using-this-adapter)
22
- - [Generic Adapter Calls](#generic-adapter-calls)
23
- - [Adapter Cache Calls](#adapter-cache-calls)
24
- - [Adapter Broker Calls](#adapter-broker-calls)
25
- - [Specific Adapter Calls](#specific-adapter-calls)
26
- - [ARGUMENTS](#arguments)
27
- - [Arguments](#arguments)
28
- - [Arguments](#arguments)
29
- - [Arguments](#arguments)
30
- - [Arguments](#arguments)
31
- - [Arguments](#arguments)
32
- - [Arguments](#arguments)
33
- - [Arguments](#arguments)
34
- - [Arguments](#arguments)
35
- - [Arguments](#arguments)
36
- - [Arguments](#arguments)
37
- - [Arguments](#arguments)
38
- - [Arguments](#arguments)
39
- - [Arguments](#arguments)
40
- - [Arguments](#arguments)
41
- - [Arguments](#arguments)
42
- - [Arguments](#arguments)
43
- - [Arguments](#arguments)
44
- - [Arguments](#arguments)
45
- - [Arguments](#arguments)
46
- - [ARGUMENTS](#arguments)
47
- - [Arguments](#arguments)
48
- - [ARGUMENTS](#arguments)
49
- - [ARGUMENTS](#arguments)
50
- - [Arguments](#arguments)
51
- - [Arguments](#arguments)
52
- - [Arguments](#arguments)
53
- - [ARGUMENTS](#arguments)
54
- - [Arguments](#arguments)
55
- - [Arguments](#arguments)
56
- - [Arguments](#arguments)
57
- - [Arguments](#arguments)
58
- - [Arguments](#arguments)
59
- - [Arguments](#arguments)
60
- - [Arguments](#arguments)
61
- - [ARGUMENTS](#arguments)
62
- - [Arguments](#arguments)
63
- - [Arguments](#arguments)
64
- - [Arguments](#arguments)
65
- - [Arguments](#arguments)
66
- - [Arguments](#arguments)
67
- - [Arguments](#arguments)
68
- - [Arguments](#arguments)
69
- - [Arguments](#arguments)
70
- - [Arguments](#arguments)
71
- - [Arguments](#arguments)
72
- - [Arguments](#arguments)
73
- - [Arguments](#arguments)
74
- - [Arguments](#arguments)
75
- - [Arguments](#arguments)
76
- - [Arguments](#arguments)
77
- - [Arguments](#arguments)
78
- - [Arguments](#arguments)
79
- - [Arguments](#arguments)
80
- - [Arguments](#arguments)
81
- - [Arguments](#arguments)
82
- - [Arguments](#arguments)
83
- - [Arguments](#arguments)
84
- - [Arguments](#arguments)
85
- - [Arguments](#arguments)
86
- - [Arguments](#arguments)
87
- - [Arguments](#arguments)
88
- - [Arguments](#arguments)
89
- - [Arguments](#arguments)
90
- - [Arguments](#arguments)
91
- - [Arguments](#arguments)
92
- - [Arguments](#arguments)
93
- - [Arguments](#arguments)
94
- - [Arguments](#arguments)
95
- - [Arguments](#arguments)
96
- - [Arguments](#arguments)
97
- - [Arguments](#arguments)
98
- - [Arguments](#arguments)
99
- - [Arguments](#arguments)
100
- - [Arguments](#arguments)
101
- - [Arguments](#arguments)
102
- - [Arguments](#arguments)
103
- - [Arguments](#arguments)
104
- - [Arguments](#arguments)
105
- - [Arguments](#arguments)
106
- - [Arguments](#arguments)
107
- - [Arguments](#arguments)
108
- - [Arguments](#arguments)
109
- - [Arguments](#arguments)
110
- - [Arguments](#arguments)
111
- - [Arguments](#arguments)
112
- - [Arguments](#arguments)
113
- - [ARGUMENTS](#arguments)
114
- - [Arguments](#arguments)
115
- - [Arguments](#arguments)
116
- - [Arguments](#arguments)
117
- - [Multipart Form-Data](#multipart-form-data)
118
- - [XML Body](#xml-body)
119
- - [Arguments](#arguments)
120
- - [Arguments](#arguments)
121
- - [Arguments](#arguments)
122
- - [Arguments](#arguments)
123
- - [Arguments](#arguments)
124
- - [Arguments](#arguments)
125
- - [Arguments](#arguments)
126
- - [Arguments](#arguments)
127
- - [Arguments](#arguments)
128
- - [Arguments](#arguments)
129
- - [Arguments](#arguments)
130
- - [Arguments](#arguments)
131
- - [Arguments](#arguments)
132
- - [Arguments](#arguments)
133
- - [Arguments](#arguments)
134
- - [Arguments](#arguments)
135
- - [Arguments](#arguments)
136
- - [Arguments](#arguments)
137
- - [Arguments](#arguments)
138
- - [Authentication](#authentication)
139
- - [Additional Information](#additional-information)
140
- - [Enhancements](#enhancements)
141
- - [Contributing](#contributing)
142
- - [Helpful Links](#helpful-links)
143
- - [Node Scripts](#node-scripts)
144
- - [Troubleshoot](#troubleshoot)
145
- - [Connectivity Issues](#connectivity-issues)
146
- - [Functional Issues](#functional-issues)
5
+ - [Specific Adapter Information](#specific-adapter-information)
6
+ - [Authentication](#authentication)
7
+ - [Sample Properties](#sample-properties)
8
+ - [Swagger](#swagger)
9
+ - [Generic Adapter Information](#generic-adapter-information)
147
10
 
148
- ## Getting Started
149
-
150
- These instructions will help you get a copy of the project on your local machine for development and testing. Reading this section is also helpful for deployments as it provides you with pertinent information on prerequisites and properties.
151
-
152
- ### Helpful Background Information
153
-
154
- There is <a href="https://docs.itential.com/opensource/docs/adapters" target="_blank">Adapter documentation available on the Itential Documentation Site</a>. This documentation includes information and examples that are helpful for:
155
-
156
- ```text
157
- Authentication
158
- IAP Service Instance Configuration
159
- Code Files
160
- Endpoint Configuration (Action & Schema)
161
- Mock Data
162
- Adapter Generic Methods
163
- Headers
164
- Security
165
- Linting and Testing
166
- Build an Adapter
167
- Troubleshooting an Adapter
168
- ```
169
-
170
- Others will be added over time.
171
- Want to build a new adapter? Use the <a href="https://adapters.itential.io" target="_blank">Itential Adapter Builder</a>
172
-
173
- ### Prerequisites
174
-
175
- The following is a list of required packages for installation on the system the adapter will run on:
176
-
177
- ```text
178
- Node.js
179
- npm
180
- Git
181
- ```
182
-
183
- The following list of packages are required for Itential opensource adapters or custom adapters that have been built utilizing the Itential Adapter Builder. You can install these packages by running npm install inside the adapter directory.
184
-
185
- <table border="1" class="bordered-table">
186
- <tr>
187
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Package</span></th>
188
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
189
- </tr>
190
- <tr>
191
- <td style="padding:15px">@itentialopensource/adapter-utils</td>
192
- <td style="padding:15px">Runtime library classes for all adapters; includes request handling, connection, authentication throttling, and translation.</td>
193
- </tr>
194
- <tr>
195
- <td style="padding:15px">ajv</td>
196
- <td style="padding:15px">Required for validation of adapter properties to integrate with Datadog.</td>
197
- </tr>
198
- <tr>
199
- <td style="padding:15px">axios</td>
200
- <td style="padding:15px">Utilized by the node scripts that are included with the adapter; helps to build and extend the functionality.</td>
201
- </tr>
202
- <tr>
203
- <td style="padding:15px">commander</td>
204
- <td style="padding:15px">Utilized by the node scripts that are included with the adapter; helps to build and extend the functionality.</td>
205
- </tr>
206
- <tr>
207
- <td style="padding:15px">dns-lookup-promise</td>
208
- <td style="padding:15px">Utilized by the node scripts that are included with the adapter; helps to build and extend the functionality.</td>
209
- </tr>
210
- <tr>
211
- <td style="padding:15px">fs-extra</td>
212
- <td style="padding:15px">Utilized by the node scripts that are included with the adapter; helps to build and extend the functionality.</td>
213
- </tr>
214
- <tr>
215
- <td style="padding:15px">mocha</td>
216
- <td style="padding:15px">Testing library that is utilized by some of the node scripts that are included with the adapter.</td>
217
- </tr>
218
- <tr>
219
- <td style="padding:15px">mocha-param</td>
220
- <td style="padding:15px">Testing library that is utilized by some of the node scripts that are included with the adapter.</td>
221
- </tr>
222
- <tr>
223
- <td style="padding:15px">mongodb</td>
224
- <td style="padding:15px">Utilized by the node scripts that are included with the adapter; helps to build and extend the functionality.</td>
225
- </tr>
226
- <tr>
227
- <td style="padding:15px">nyc</td>
228
- <td style="padding:15px">Testing coverage library that is utilized by some of the node scripts that are included with the adapter.</td>
229
- </tr>
230
- <tr>
231
- <td style="padding:15px">ping</td>
232
- <td style="padding:15px">Utilized by the node scripts that are included with the adapter; helps to build and extend the functionality.</td>
233
- </tr>
234
- <tr>
235
- <td style="padding:15px">readline-sync</td>
236
- <td style="padding:15px">Utilized by the node script that comes with the adapter; helps to test unit and integration functionality.</td>
237
- </tr>
238
- <tr>
239
- <td style="padding:15px">semver</td>
240
- <td style="padding:15px">Utilized by the node scripts that are included with the adapter; helps to build and extend the functionality.</td>
241
- </tr>
242
- <tr>
243
- <td style="padding:15px">winston</td>
244
- <td style="padding:15px">Utilized by the node scripts that are included with the adapter; helps to build and extend the functionality.</td>
245
- </tr>
246
- </table>
247
- <br>
248
-
249
- If you are developing and testing a custom adapter, or have testing capabilities on an Itential opensource adapter, you will need to install these packages as well.
250
-
251
- ```text
252
- chai
253
- eslint
254
- eslint-config-airbnb-base
255
- eslint-plugin-import
256
- eslint-plugin-json
257
- testdouble
258
- ```
259
-
260
- ### How to Install
261
-
262
- 1. Set up the name space location in your IAP node_modules.
263
-
264
- ```bash
265
- cd /opt/pronghorn/current/node_modules (* could be in a different place)
266
- if the @itentialopensource directory does not exist, create it:
267
- mkdir @itentialopensource
268
- ```
269
-
270
- 2. Clone/unzip/tar the adapter into your IAP environment.
271
-
272
- ```bash
273
- cd \@itentialopensource
274
- git clone git@gitlab.com:\@itentialopensource/adapters/adapter-datadog
275
- or
276
- unzip adapter-datadog.zip
277
- or
278
- tar -xvf adapter-datadog.tar
279
- ```
280
-
281
- 3. Run the adapter install script.
282
-
283
- ```bash
284
- cd adapter-datadog
285
- npm install
286
- npm run lint:errors
287
- npm run test
288
- ```
289
-
290
- 4. Restart IAP
291
-
292
- ```bash
293
- systemctl restart pronghorn
294
- ```
295
-
296
- 5. Create an adapter service instance configuration in IAP Admin Essentials GUI
297
-
298
- 6. Copy the properties from the sampleProperties.json and paste them into the service instance configuration in the inner/second properties field.
299
-
300
- 7. Change the adapter service instance configuration (host, port, credentials, etc) in IAP Admin Essentials GUI
301
-
302
-
303
- For an easier install of the adapter use npm run adapter:install, it will install the adapter in IAP. Please note that it can be dependent on where the adapter is installed and on the version of IAP so it is subject to fail. If using this, you can replace step 3-5 above with these:
304
-
305
- 3. Install adapter dependencies and check the adapter.
306
-
307
- ```bash
308
- cd adapter-datadog
309
- npm run adapter:install
310
- ```
311
-
312
- 4. Restart IAP
313
-
314
- ```bash
315
- systemctl restart pronghorn
316
- ```
317
-
318
- 5. Change the adapter service instance configuration (host, port, credentials, etc) in IAP Admin Essentials GUI
319
-
320
-
321
- ### Testing
322
-
323
- Mocha is generally used to test all Itential Opensource Adapters. There are unit tests as well as integration tests performed. Integration tests can generally be run as standalone using mock data and running the adapter in stub mode, or as integrated. When running integrated, every effort is made to prevent environmental failures, however there is still a possibility.
324
-
325
- #### Unit Testing
326
-
327
- Unit Testing includes testing basic adapter functionality as well as error conditions that are triggered in the adapter prior to any integration. There are two ways to run unit tests. The prefered method is to use the testRunner script; however, both methods are provided here.
328
-
329
- ```bash
330
- node utils/testRunner --unit
331
-
332
- npm run test:unit
333
- npm run test:baseunit
334
- ```
335
-
336
- To add new unit tests, edit the `test/unit/adapterTestUnit.js` file. The tests that are already in this file should provide guidance for adding additional tests.
337
-
338
- #### Integration Testing - Standalone
339
-
340
- Standalone Integration Testing requires mock data to be provided with the entities. If this data is not provided, standalone integration testing will fail. When the adapter is set to run in stub mode (setting the stub property to true), the adapter will run through its code up to the point of making the request. It will then retrieve the mock data and return that as if it had received that data as the response from Datadog. It will then translate the data so that the adapter can return the expected response to the rest of the Itential software. Standalone is the default integration test.
341
-
342
- Similar to unit testing, there are two ways to run integration tests. Using the testRunner script is better because it prevents you from having to edit the test script; it will also resets information after testing is complete so that credentials are not saved in the file.
343
-
344
- ```bash
345
- node utils/testRunner
346
- answer no at the first prompt
347
-
348
- npm run test:integration
349
- ```
350
-
351
- To add new integration tests, edit the `test/integration/adapterTestIntegration.js` file. The tests that are already in this file should provide guidance for adding additional tests.
352
-
353
- #### Integration Testing
11
+ ## Specific Adapter Information
12
+ ### Authentication
354
13
 
355
- Integration Testing requires connectivity to Datadog. By using the testRunner script it prevents you from having to edit the integration test. It also resets the integration test after the test is complete so that credentials are not saved in the file.
14
+ This document will go through the steps for authenticating the Datadog adapter with Basic Authentication. Properly configuring the properties for an adapter in IAP is critical for getting the adapter online. You can read more about adapter authentication <a href="https://www.itential.com/automation-platform/integrations/adapters-resources/authentication/" target="_blank">HERE</a>.
356
15
 
357
- > **Note**: These tests have been written as a best effort to make them work in most environments. However, the Adapter Builder often does not have the necessary information that is required to set up valid integration tests. For example, the order of the requests can be very important and data is often required for `creates` and `updates`. Hence, integration tests may have to be enhanced before they will work (integrate) with Datadog. Even after tests have been set up properly, it is possible there are environmental constraints that could result in test failures. Some examples of possible environmental issues are customizations that have been made within Datadog which change order dependencies or required data.
16
+ #### Basic Authentication
17
+ The Datadog adapter requires Basic Authentication. If you change authentication methods, you should change this section accordingly and merge it back into the adapter repository.
358
18
 
359
- ```bash
360
- node utils/testRunner
361
- answer yes at the first prompt
362
- answer all other questions on connectivity and credentials
19
+ STEPS
20
+ 1. Ensure you have access to a Datadog server and that it is running
21
+ 2. Follow the steps in the README.md to import the adapter into IAP if you have not already done so
22
+ 3. Use the properties below for the ```properties.authentication``` field
23
+ ```json
24
+ "authentication": {
25
+ "auth_method": "basic user_password",
26
+ "username": "<username>",
27
+ "password": "<password>",
28
+ "token": "",
29
+ "token_timeout": 1800000,
30
+ "token_cache": "local",
31
+ "invalid_token_error": 401,
32
+ "auth_field": "header.headers.Authorization",
33
+ "auth_field_format": "Basic {b64}{username}:{password}{/b64}",
34
+ "auth_logging": false,
35
+ "client_id": "",
36
+ "client_secret": "",
37
+ "grant_type": ""
38
+ }
363
39
  ```
40
+ 4. Restart the adapter. If your properties were set correctly, the adapter should go online.
364
41
 
365
- Test should also be written to clean up after themselves. However, it is important to understand that in some cases this may not be possible. In addition, whenever exceptions occur, test execution may be stopped, which will prevent cleanup actions from running. It is recommended that tests be utilized in dev and test labs only.
366
-
367
- > **Reminder**: Do not check in code with actual credentials to systems.
368
-
369
- ## Configuration
42
+ #### Troubleshooting
43
+ - Make sure you copied over the correct username and password.
44
+ - Turn on debug level logs for the adapter in IAP Admin Essentials.
45
+ - Turn on auth_logging for the adapter in IAP Admin Essentials (adapter properties).
46
+ - Investigate the logs - in particular:
47
+ - The FULL REQUEST log to make sure the proper headers are being sent with the request.
48
+ - The FULL BODY log to make sure the payload is accurate.
49
+ - The CALL RETURN log to see what the other system is telling us.
50
+ - Remember when you are done to turn auth_logging off as you do not want to log credentials.
370
51
 
371
- This section defines **all** the properties that are available for the adapter, including detailed information on what each property is for. If you are not using certain capabilities with this adapter, you do not need to define all of the properties. An example of how the properties for this adapter can be used with tests or IAP are provided in the sampleProperties.
52
+ ### Sample Properties
372
53
 
373
- ### Example Properties
54
+ Sample Properties can be used to help you configure the adapter in the Itential Automation Platform. You will need to update connectivity information such as the host, port, protocol and credentials.
374
55
 
375
56
  ```json
376
57
  "properties": {
@@ -486,6 +167,7 @@ This section defines **all** the properties that are available for the adapter,
486
167
  }
487
168
  },
488
169
  "devicebroker": {
170
+ "enabled": false,
489
171
  "getDevice": [
490
172
  {
491
173
  "path": "/get/devices/{id}",
@@ -620,2661 +302,7 @@ This section defines **all** the properties that are available for the adapter,
620
302
  }
621
303
  }
622
304
  ```
305
+ ### [Swagger](https://gitlab.com/itentialopensource/adapters/telemetry-analytics/adapter-datadog/-/blob/master/report/adapter-openapi.json)
623
306
 
624
- ### Connection Properties
625
-
626
- These base properties are used to connect to Datadog upon the adapter initially coming up. It is important to set these properties appropriately.
627
-
628
- <table border="1" class="bordered-table">
629
- <tr>
630
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
631
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
632
- </tr>
633
- <tr>
634
- <td style="padding:15px">host</td>
635
- <td style="padding:15px">Required. A fully qualified domain name or IP address.</td>
636
- </tr>
637
- <tr>
638
- <td style="padding:15px">port</td>
639
- <td style="padding:15px">Required. Used to connect to the server.</td>
640
- </tr>
641
- <tr>
642
- <td style="padding:15px">base_path</td>
643
- <td style="padding:15px">Optional. Used to define part of a path that is consistent for all or most endpoints. It makes the URIs easier to use and maintain but can be overridden on individual calls. An example **base_path** might be `/rest/api`. Default is ``.</td>
644
- </tr>
645
- <tr>
646
- <td style="padding:15px">version</td>
647
- <td style="padding:15px">Optional. Used to set a global version for action endpoints. This makes it faster to update the adapter when endpoints change. As with the base-path, version can be overridden on individual endpoints. Default is ``.</td>
648
- </tr>
649
- <tr>
650
- <td style="padding:15px">cache_location</td>
651
- <td style="padding:15px">Optional. Used to define where the adapter cache is located. The cache is used to maintain an entity list to improve performance. Storage locally is lost when the adapter is restarted. Storage in Redis is preserved upon adapter restart. Default is none which means no caching of the entity list.</td>
652
- </tr>
653
- <tr>
654
- <td style="padding:15px">encode_pathvars</td>
655
- <td style="padding:15px">Optional. Used to tell the adapter to encode path variables or not. The default behavior is to encode them so this property can be used to stop that behavior.</td>
656
- </tr>
657
- <tr>
658
- <td style="padding:15px">encode_queryvars</td>
659
- <td style="padding:15px">Optional. Used to tell the adapter to encode query parameters or not. The default behavior is to encode them so this property can be used to stop that behavior.</td>
660
- </tr>
661
- <tr>
662
- <td style="padding:15px">save_metric</td>
663
- <td style="padding:15px">Optional. Used to tell the adapter to save metric information (this does not impact metrics returned on calls). This allows the adapter to gather metrics over time. Metric data can be stored in a database or on the file system.</td>
664
- </tr>
665
- <tr>
666
- <td style="padding:15px">stub</td>
667
- <td style="padding:15px">Optional. Indicates whether the stub should run instead of making calls to Datadog (very useful during basic testing). Default is false (which means connect to Datadog).</td>
668
- </tr>
669
- <tr>
670
- <td style="padding:15px">protocol</td>
671
- <td style="padding:15px">Optional. Notifies the adapter whether to use HTTP or HTTPS. Default is HTTP.</td>
672
- </tr>
673
- </table>
674
- <br>
675
-
676
- A connectivity check tells IAP the adapter has loaded successfully.
677
-
678
- ### Authentication Properties
679
-
680
- The following properties are used to define the authentication process to Datadog.
681
-
682
- >**Note**: Depending on the method that is used to authenticate with Datadog, you may not need to set all of the authentication properties.
683
-
684
- <table border="1" class="bordered-table">
685
- <tr>
686
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
687
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
688
- </tr>
689
- <tr>
690
- <td style="padding:15px">auth_method</td>
691
- <td style="padding:15px">Required. Used to define the type of authentication currently supported. Authentication methods currently supported are: `basic user_password`, `static_token`, `request_token`, and `no_authentication`.</td>
692
- </tr>
693
- <tr>
694
- <td style="padding:15px">username</td>
695
- <td style="padding:15px">Used to authenticate with Datadog on every request or when pulling a token that will be used in subsequent requests.</td>
696
- </tr>
697
- <tr>
698
- <td style="padding:15px">password</td>
699
- <td style="padding:15px">Used to authenticate with Datadog on every request or when pulling a token that will be used in subsequent requests.</td>
700
- </tr>
701
- <tr>
702
- <td style="padding:15px">token</td>
703
- <td style="padding:15px">Defines a static token that can be used on all requests. Only used with `static_token` as an authentication method (auth\_method).</td>
704
- </tr>
705
- <tr>
706
- <td style="padding:15px">invalid_token_error</td>
707
- <td style="padding:15px">Defines the HTTP error that is received when the token is invalid. Notifies the adapter to pull a new token and retry the request. Default is 401.</td>
708
- </tr>
709
- <tr>
710
- <td style="padding:15px">token_timeout</td>
711
- <td style="padding:15px">Defines how long a token is valid. Measured in milliseconds. Once a dynamic token is no longer valid, the adapter has to pull a new token. If the token_timeout is set to -1, the adapter will pull a token on every request to Datadog. If the timeout_token is 0, the adapter will use the expiration from the token response to determine when the token is no longer valid.</td>
712
- </tr>
713
- <tr>
714
- <td style="padding:15px">token_cache</td>
715
- <td style="padding:15px">Used to determine where the token should be stored (local memory or in Redis).</td>
716
- </tr>
717
- <tr>
718
- <td style="padding:15px">auth_field</td>
719
- <td style="padding:15px">Defines the request field the authentication (e.g., token are basic auth credentials) needs to be placed in order for the calls to work.</td>
720
- </tr>
721
- <tr>
722
- <td style="padding:15px">auth_field_format</td>
723
- <td style="padding:15px">Defines the format of the auth\_field. See examples below. Items enclosed in {} inform the adapter to perofrm an action prior to sending the data. It may be to replace the item with a value or it may be to encode the item.</td>
724
- </tr>
725
- <tr>
726
- <td style="padding:15px">auth_logging</td>
727
- <td style="padding:15px">Setting this true will add some additional logs but this should only be done when trying to debug an issue as certain credential information may be logged out when this is true.</td>
728
- </tr>
729
- <tr>
730
- <td style="padding:15px">client_id</td>
731
- <td style="padding:15px">Provide a client id when needed, this is common on some types of OAuth.</td>
732
- </tr>
733
- <tr>
734
- <td style="padding:15px">client_secret</td>
735
- <td style="padding:15px">Provide a client secret when needed, this is common on some types of OAuth.</td>
736
- </tr>
737
- <tr>
738
- <td style="padding:15px">grant_type</td>
739
- <td style="padding:15px">Provide a grant type when needed, this is common on some types of OAuth.</td>
740
- </tr>
741
- </table>
742
- <br>
743
-
744
- #### Examples of authentication field format
745
-
746
- ```json
747
- "{token}"
748
- "Token {token}"
749
- "{username}:{password}"
750
- "Basic {b64}{username}:{password}{/b64}"
751
- ```
752
-
753
- ### Healthcheck Properties
754
-
755
- The healthcheck properties defines the API that runs the healthcheck to tell the adapter that it can reach Datadog. There are currently three types of healthchecks.
756
-
757
- - None - Not recommended. Adapter will not run a healthcheck. Consequently, unable to determine before making a request if the adapter can reach Datadog.
758
- - Startup - Adapter will check for connectivity when the adapter initially comes up, but it will not check afterwards.
759
- - Intermittent - Adapter will check connectivity to Datadog at a frequency defined in the `frequency` property.
760
-
761
- <table border="1" class="bordered-table">
762
- <tr>
763
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
764
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
765
- </tr>
766
- <tr>
767
- <td style="padding:15px">type</td>
768
- <td style="padding:15px">Required. The type of health check to run.</td>
769
- </tr>
770
- <tr>
771
- <td style="padding:15px">frequency</td>
772
- <td style="padding:15px">Required if intermittent. Defines how often the health check should run. Measured in milliseconds. Default is 300000.</td>
773
- </tr>
774
- <tr>
775
- <td style="padding:15px">query_object</td>
776
- <td style="padding:15px">Query parameters to be added to the adapter healthcheck call.</td>
777
- </tr>
778
- </table>
779
- <br>
780
-
781
- ### Request Properties
782
-
783
- The request section defines properties to help handle requests.
784
-
785
- <table border="1" class="bordered-table">
786
- <tr>
787
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
788
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
789
- </tr>
790
- <tr>
791
- <td style="padding:15px">number_redirects</td>
792
- <td style="padding:15px">Optional. Tells the adapter that the request may be redirected and gives it a maximum number of redirects to allow before returning an error. Default is 0 - no redirects.</td>
793
- </tr>
794
- <tr>
795
- <td style="padding:15px">number_retries</td>
796
- <td style="padding:15px">Tells the adapter how many times to retry a request that has either aborted or reached a limit error before giving up and returning an error.</td>
797
- </tr>
798
- <tr>
799
- <td style="padding:15px">limit_retry_error</td>
800
- <td style="padding:15px">Optional. Can be either an integer or an array. Indicates the http error status number to define that no capacity was available and, after waiting a short interval, the adapter can retry the request. If an array is provvided, the array can contain integers or strings. Strings in the array are used to define ranges (e.g. "502-506"). Default is [0].</td>
801
- </tr>
802
- <tr>
803
- <td style="padding:15px">failover_codes</td>
804
- <td style="padding:15px">An array of error codes for which the adapter will send back a failover flag to IAP so that the Platform can attempt the action in another adapter.</td>
805
- </tr>
806
- <tr>
807
- <td style="padding:15px">attempt_timeout</td>
808
- <td style="padding:15px">Optional. Tells how long the adapter should wait before aborting the attempt. On abort, the adapter will do one of two things: 1) return the error; or 2) if **healthcheck\_on\_timeout** is set to true, it will abort the request and run a Healthcheck until it re-establishes connectivity to Datadog, and then will re-attempt the request that aborted. Default is 5000 milliseconds.</td>
809
- </tr>
810
- <tr>
811
- <td style="padding:15px">global_request</td>
812
- <td style="padding:15px">Optional. This is information that the adapter can include in all requests to the other system. This is easier to define and maintain than adding this information in either the code (adapter.js) or the action files.</td>
813
- </tr>
814
- <tr>
815
- <td style="padding:15px">global_request -> payload</td>
816
- <td style="padding:15px">Optional. Defines any information that should be included on all requests sent to the other system that have a payload/body.</td>
817
- </tr>
818
- <tr>
819
- <td style="padding:15px">global_request -> uriOptions</td>
820
- <td style="padding:15px">Optional. Defines any information that should be sent as untranslated query options (e.g. page, size) on all requests to the other system.</td>
821
- </tr>
822
- <tr>
823
- <td style="padding:15px">global_request -> addlHeaders</td>
824
- <td style="padding:15px">Optioonal. Defines any headers that should be sent on all requests to the other system.</td>
825
- </tr>
826
- <tr>
827
- <td style="padding:15px">global_request -> authData</td>
828
- <td style="padding:15px">Optional. Defines any additional authentication data used to authentice with the other system. This authData needs to be consistent on every request.</td>
829
- </tr>
830
- <tr>
831
- <td style="padding:15px">healthcheck_on_timeout</td>
832
- <td style="padding:15px">Required. Defines if the adapter should run a health check on timeout. If set to true, the adapter will abort the request and run a health check until it re-establishes connectivity and then it will re-attempt the request.</td>
833
- </tr>
834
- <tr>
835
- <td style="padding:15px">return_raw</td>
836
- <td style="padding:15px">Optional. Tells the adapter whether the raw response should be returned as well as the IAP response. This is helpful when running integration tests to save mock data. It does add overhead to the response object so it is not ideal from production.</td>
837
- </tr>
838
- <tr>
839
- <td style="padding:15px">archiving</td>
840
- <td style="padding:15px">Optional flag. Default is false. It archives the request, the results and the various times (wait time, Datadog time and overall time) in the `adapterid_results` collection in MongoDB. Although archiving might be desirable, be sure to develop a strategy before enabling this capability. Consider how much to archive and what strategy to use for cleaning up the collection in the database so that it does not become too large, especially if the responses are large.</td>
841
- </tr>
842
- <tr>
843
- <td style="padding:15px">return_request</td>
844
- <td style="padding:15px">Optional flag. Default is false. Will return the actual request that is made including headers. This should only be used during debugging issues as there could be credentials in the actual request.</td>
845
- </tr>
846
- </table>
847
- <br>
848
-
849
- ### SSL Properties
850
-
851
- The SSL section defines the properties utilized for ssl authentication with Datadog. SSL can work two different ways: set the `accept\_invalid\_certs` flag to true (only recommended for lab environments), or provide a `ca\_file`.
852
-
853
- <table border="1" class="bordered-table">
854
- <tr>
855
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
856
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
857
- </tr>
858
- <tr>
859
- <td style="padding:15px">enabled</td>
860
- <td style="padding:15px">If SSL is required, set to true.</td>
861
- </tr>
862
- <tr>
863
- <td style="padding:15px">accept_invalid_certs</td>
864
- <td style="padding:15px">Defines if the adapter should accept invalid certificates (only recommended for lab environments). Required if SSL is enabled. Default is false.</td>
865
- </tr>
866
- <tr>
867
- <td style="padding:15px">ca_file</td>
868
- <td style="padding:15px">Defines the path name to the CA file used for SSL. If SSL is enabled and the accept invalid certifications is false, then ca_file is required.</td>
869
- </tr>
870
- <tr>
871
- <td style="padding:15px">key_file</td>
872
- <td style="padding:15px">Defines the path name to the Key file used for SSL. The key_file may be needed for some systems but it is not required for SSL.</td>
873
- </tr>
874
- <tr>
875
- <td style="padding:15px">cert_file</td>
876
- <td style="padding:15px">Defines the path name to the Certificate file used for SSL. The cert_file may be needed for some systems but it is not required for SSL.</td>
877
- </tr>
878
- <tr>
879
- <td style="padding:15px">secure_protocol</td>
880
- <td style="padding:15px">Defines the protocol (e.g., SSLv3_method) to use on the SSL request.</td>
881
- </tr>
882
- <tr>
883
- <td style="padding:15px">ciphers</td>
884
- <td style="padding:15px">Required if SSL enabled. Specifies a list of SSL ciphers to use.</td>
885
- </tr>
886
- <tr>
887
- <td style="padding:15px">ecdhCurve</td>
888
- <td style="padding:15px">During testing on some Node 8 environments, you need to set `ecdhCurve` to auto. If you do not, you will receive PROTO errors when attempting the calls. This is the only usage of this property and to our knowledge it only impacts Node 8 and 9.</td>
889
- </tr>
890
- </table>
891
- <br>
892
-
893
- ### Throttle Properties
894
-
895
- The throttle section is used when requests to Datadog must be queued (throttled). All of the properties in this section are optional.
896
-
897
- <table border="1" class="bordered-table">
898
- <tr>
899
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
900
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
901
- </tr>
902
- <tr>
903
- <td style="padding:15px">throttle_enabled</td>
904
- <td style="padding:15px">Default is false. Defines if the adapter should use throttling or not.</td>
905
- </tr>
906
- <tr>
907
- <td style="padding:15px">number_pronghorns</td>
908
- <td style="padding:15px">Default is 1. Defines if throttling is done in a single Itential instance or whether requests are being throttled across multiple Itential instances (minimum = 1, maximum = 20). Throttling in a single Itential instance uses an in-memory queue so there is less overhead. Throttling across multiple Itential instances requires placing the request and queue information into a shared resource (e.g. database) so that each instance can determine what is running and what is next to run. Throttling across multiple instances requires additional I/O overhead.</td>
909
- </tr>
910
- <tr>
911
- <td style="padding:15px">sync-async</td>
912
- <td style="padding:15px">This property is not used at the current time (it is for future expansion of the throttling engine).</td>
913
- </tr>
914
- <tr>
915
- <td style="padding:15px">max_in_queue</td>
916
- <td style="padding:15px">Represents the maximum number of requests the adapter should allow into the queue before rejecting requests (minimum = 1, maximum = 5000). This is not a limit on what the adapter can handle but more about timely responses to requests. The default is currently 1000.</td>
917
- </tr>
918
- <tr>
919
- <td style="padding:15px">concurrent_max</td>
920
- <td style="padding:15px">Defines the number of requests the adapter can send to Datadog at one time (minimum = 1, maximum = 1000). The default is 1 meaning each request must be sent to Datadog in a serial manner.</td>
921
- </tr>
922
- <tr>
923
- <td style="padding:15px">expire_timeout</td>
924
- <td style="padding:15px">Default is 0. Defines a graceful timeout of the request session. After a request has completed, the adapter will wait additional time prior to sending the next request. Measured in milliseconds (minimum = 0, maximum = 60000).</td>
925
- </tr>
926
- <tr>
927
- <td style="padding:15px">average_runtime</td>
928
- <td style="padding:15px">Represents the approximate average of how long it takes Datadog to handle each request. Measured in milliseconds (minimum = 50, maximum = 60000). Default is 200. This metric has performance implications. If the runtime number is set too low, it puts extra burden on the CPU and memory as the requests will continually try to run. If the runtime number is set too high, requests may wait longer than they need to before running. The number does not need to be exact but your throttling strategy depends heavily on this number being within reason. If averages range from 50 to 250 milliseconds you might pick an average run-time somewhere in the middle so that when Datadog performance is exceptional you might run a little slower than you might like, but when it is poor you still run efficiently.</td>
929
- </tr>
930
- <tr>
931
- <td style="padding:15px">priorities</td>
932
- <td style="padding:15px">An array of priorities and how to handle them in relation to the throttle queue. Array of objects that include priority value and percent of queue to put the item ex { value: 1, percent: 10 }</td>
933
- </tr>
934
- </table>
935
- <br>
936
-
937
- ### Proxy Properties
938
-
939
- The proxy section defines the properties to utilize when Datadog is behind a proxy server.
940
-
941
- <table border="1" class="bordered-table">
942
- <tr>
943
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
944
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
945
- </tr>
946
- <tr>
947
- <td style="padding:15px">enabled</td>
948
- <td style="padding:15px">Required. Default is false. If Datadog is behind a proxy server, set enabled flag to true.</td>
949
- </tr>
950
- <tr>
951
- <td style="padding:15px">host</td>
952
- <td style="padding:15px">Host information for the proxy server. Required if `enabled` is true.</td>
953
- </tr>
954
- <tr>
955
- <td style="padding:15px">port</td>
956
- <td style="padding:15px">Port information for the proxy server. Required if `enabled` is true.</td>
957
- </tr>
958
- <tr>
959
- <td style="padding:15px">protocol</td>
960
- <td style="padding:15px">The protocol (i.e., http, https, etc.) used to connect to the proxy. Default is http.</td>
961
- </tr>
962
- <tr>
963
- <td style="padding:15px">username</td>
964
- <td style="padding:15px">If there is authentication for the proxy, provide the username here.</td>
965
- </tr>
966
- <tr>
967
- <td style="padding:15px">password</td>
968
- <td style="padding:15px">If there is authentication for the proxy, provide the password here.</td>
969
- </tr>
970
- </table>
971
- <br>
972
-
973
- ### Mongo Properties
974
-
975
- The mongo section defines the properties used to connect to a Mongo database. Mongo can be used for throttling as well as to persist metric data. If not provided, metrics will be stored in the file system.
976
-
977
- <table border="1" class="bordered-table">
978
- <tr>
979
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
980
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
981
- </tr>
982
- <tr>
983
- <td style="padding:15px">host</td>
984
- <td style="padding:15px">Optional. Host information for the mongo server.</td>
985
- </tr>
986
- <tr>
987
- <td style="padding:15px">port</td>
988
- <td style="padding:15px">Optional. Port information for the mongo server.</td>
989
- </tr>
990
- <tr>
991
- <td style="padding:15px">database</td>
992
- <td style="padding:15px">Optional. The database for the adapter to use for its data.</td>
993
- </tr>
994
- <tr>
995
- <td style="padding:15px">username</td>
996
- <td style="padding:15px">Optional. If credentials are required to access mongo, this is the user to login as.</td>
997
- </tr>
998
- <tr>
999
- <td style="padding:15px">password</td>
1000
- <td style="padding:15px">Optional. If credentials are required to access mongo, this is the password to login with.</td>
1001
- </tr>
1002
- <tr>
1003
- <td style="padding:15px">replSet</td>
1004
- <td style="padding:15px">Optional. If the database is set up to use replica sets, define it here so it can be added to the database connection.</td>
1005
- </tr>
1006
- <tr>
1007
- <td style="padding:15px">db_ssl</td>
1008
- <td style="padding:15px">Optional. Contains information for SSL connectivity to the database.</td>
1009
- </tr>
1010
- <tr>
1011
- <td style="padding:15px">db_ssl -> enabled</td>
1012
- <td style="padding:15px">If SSL is required, set to true.</td>
1013
- </tr>
1014
- <tr>
1015
- <td style="padding:15px">db_ssl -> accept_invalid_cert</td>
1016
- <td style="padding:15px">Defines if the adapter should accept invalid certificates (only recommended for lab environments). Required if SSL is enabled. Default is false.</td>
1017
- </tr>
1018
- <tr>
1019
- <td style="padding:15px">db_ssl -> ca_file</td>
1020
- <td style="padding:15px">Defines the path name to the CA file used for SSL. If SSL is enabled and the accept invalid certifications is false, then ca_file is required.</td>
1021
- </tr>
1022
- <tr>
1023
- <td style="padding:15px">db_ssl -> key_file</td>
1024
- <td style="padding:15px">Defines the path name to the Key file used for SSL. The key_file may be needed for some systems but it is not required for SSL.</td>
1025
- </tr>
1026
- <tr>
1027
- <td style="padding:15px">db_ssl -> cert_file</td>
1028
- <td style="padding:15px">Defines the path name to the Certificate file used for SSL. The cert_file may be needed for some systems but it is not required for SSL.</td>
1029
- </tr>
1030
- </table>
1031
- <br>
1032
-
1033
- ### Device Broker Properties
1034
-
1035
- The device broker section defines the properties used integrate Datadog to the device broker. Each broker call is represented and has an array of calls that can be used to build the response. This describes the calls and then the fields which are available in the calls.
1036
-
1037
- <table border="1" class="bordered-table">
1038
- <tr>
1039
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Property</span></th>
1040
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
1041
- </tr>
1042
- <tr>
1043
- <td style="padding:15px">getDevice</td>
1044
- <td style="padding:15px">The array of calls used to get device details for the broker</td>
1045
- </tr>
1046
- <tr>
1047
- <td style="padding:15px">getDevicesFiltered</td>
1048
- <td style="padding:15px">The array of calls used to get devices for the broker</td>
1049
- </tr>
1050
- <tr>
1051
- <td style="padding:15px">isAlive</td>
1052
- <td style="padding:15px">The array of calls used to get device status for the broker</td>
1053
- </tr>
1054
- <tr>
1055
- <td style="padding:15px">getConfig</td>
1056
- <td style="padding:15px">The array of calls used to get device configuration for the broker</td>
1057
- </tr>
1058
- <tr>
1059
- <td style="padding:15px">getCount</td>
1060
- <td style="padding:15px">The array of calls used to get device configuration for the broker</td>
1061
- </tr>
1062
- <tr>
1063
- <td style="padding:15px">getDevice/getDevicesFiltered/isAlive/getConfig/getCount -> path</td>
1064
- <td style="padding:15px">The path, not including the base_path and version, for making this call</td>
1065
- </tr>
1066
- <tr>
1067
- <td style="padding:15px">getDevice/getDevicesFiltered/isAlive/getConfig/getCount -> method</td>
1068
- <td style="padding:15px">The rest method for making this call</td>
1069
- </tr>
1070
- <tr>
1071
- <td style="padding:15px">getDevice/getDevicesFiltered/isAlive/getConfig/getCount -> query</td>
1072
- <td style="padding:15px">Query object containing and query parameters and their values for this call</td>
1073
- </tr>
1074
- <tr>
1075
- <td style="padding:15px">getDevice/getDevicesFiltered/isAlive/getConfig/getCount -> body</td>
1076
- <td style="padding:15px">Body object containing the payload for this call</td>
1077
- </tr>
1078
- <tr>
1079
- <td style="padding:15px">getDevice/getDevicesFiltered/isAlive/getConfig/getCount -> headers</td>
1080
- <td style="padding:15px">Header object containing the headers for this call.</td>
1081
- </tr>
1082
- <tr>
1083
- <td style="padding:15px">getDevice/getDevicesFiltered/isAlive/getConfig/getCount -> handleFailure</td>
1084
- <td style="padding:15px">Tells the adapter whether to "fail" or "ignore" failures if they occur.</td>
1085
- </tr>
1086
- <tr>
1087
- <td style="padding:15px">isAlive -> statusValue</td>
1088
- <td style="padding:15px">Tells the adapter what value to look for in the status field to determine if the device is alive.</td>
1089
- </tr>
1090
- <tr>
1091
- <td style="padding:15px">getDevice/getDevicesFiltered/isAlive/getConfig -> requestFields</td>
1092
- <td style="padding:15px">Object containing fields the adapter should send on the request and where it should get the data. The where can be from a response to a getDevicesFiltered or a static value.</td>
1093
- </tr>
1094
- <tr>
1095
- <td style="padding:15px">getDevice/getDevicesFiltered/isAlive/getConfig -> responseFields</td>
1096
- <td style="padding:15px">Object containing fields the adapter should set to send back to iap and where the value should come from in the response or request data.</td>
1097
- </tr>
1098
- </table>
1099
- <br>
1100
-
1101
-
1102
- ## Using this Adapter
1103
-
1104
- The `adapter.js` file contains the calls the adapter makes available to the rest of the Itential Platform. The API detailed for these calls should be available through JSDOC. The following is a brief summary of the calls.
1105
-
1106
- ### Generic Adapter Calls
1107
-
1108
- These are adapter methods that IAP or you might use. There are some other methods not shown here that might be used for internal adapter functionality.
1109
-
1110
- <table border="1" class="bordered-table">
1111
- <tr>
1112
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Method Signature</span></th>
1113
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
1114
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Workflow?</span></th>
1115
- </tr>
1116
- <tr>
1117
- <td style="padding:15px">connect()</td>
1118
- <td style="padding:15px">This call is run when the Adapter is first loaded by he Itential Platform. It validates the properties have been provided correctly.</td>
1119
- <td style="padding:15px">No</td>
1120
- </tr>
1121
- <tr>
1122
- <td style="padding:15px">healthCheck(callback)</td>
1123
- <td style="padding:15px">This call ensures that the adapter can communicate with Adapter for Datadog. The actual call that is used is defined in the adapter properties and .system entities action.json file.</td>
1124
- <td style="padding:15px">No</td>
1125
- </tr>
1126
- <tr>
1127
- <td style="padding:15px">refreshProperties(properties)</td>
1128
- <td style="padding:15px">This call provides the adapter the ability to accept property changes without having to restart the adapter.</td>
1129
- <td style="padding:15px">No</td>
1130
- </tr>
1131
- <tr>
1132
- <td style="padding:15px">encryptProperty(property, technique, callback)</td>
1133
- <td style="padding:15px">This call will take the provided property and technique, and return the property encrypted with the technique. This allows the property to be used in the adapterProps section for the credential password so that the password does not have to be in clear text. The adapter will decrypt the property as needed for communications with Adapter for Datadog.</td>
1134
- <td style="padding:15px">No</td>
1135
- </tr>
1136
- <tr>
1137
- <td style="padding:15px">iapUpdateAdapterConfiguration(configFile, changes, entity, type, action, callback)</td>
1138
- <td style="padding:15px">This call provides the ability to update the adapter configuration from IAP - includes actions, schema, mockdata and other configurations.</td>
1139
- <td style="padding:15px">Yes</td>
1140
- </tr>
1141
- <tr>
1142
- <td style="padding:15px">iapSuspendAdapter(mode, callback)</td>
1143
- <td style="padding:15px">This call provides the ability to suspend the adapter and either have requests rejected or put into a queue to be processed after the adapter is resumed.</td>
1144
- <td style="padding:15px">Yes</td>
1145
- </tr>
1146
- <tr>
1147
- <td style="padding:15px">iapUnsuspendAdapter(callback)</td>
1148
- <td style="padding:15px">This call provides the ability to resume a suspended adapter. Any requests in queue will be processed before new requests.</td>
1149
- <td style="padding:15px">Yes</td>
1150
- </tr>
1151
- <tr>
1152
- <td style="padding:15px">iapGetAdapterQueue(callback)</td>
1153
- <td style="padding:15px">This call will return the requests that are waiting in the queue if throttling is enabled.</td>
1154
- <td style="padding:15px">Yes</td>
1155
- </tr>
1156
- <tr>
1157
- <td style="padding:15px">iapFindAdapterPath(apiPath, callback)</td>
1158
- <td style="padding:15px">This call provides the ability to see if a particular API path is supported by the adapter.</td>
1159
- <td style="padding:15px">Yes</td>
1160
- </tr>
1161
- <tr>
1162
- <td style="padding:15px">iapTroubleshootAdapter(props, persistFlag, adapter, callback)</td>
1163
- <td style="padding:15px">This call can be used to check on the performance of the adapter - it checks connectivity, healthcheck and basic get calls.</td>
1164
- <td style="padding:15px">Yes</td>
1165
- </tr>
1166
- <tr>
1167
- <td style="padding:15px">iapRunAdapterHealthcheck(adapter, callback)</td>
1168
- <td style="padding:15px">This call will return the results of a healthcheck.</td>
1169
- <td style="padding:15px">Yes</td>
1170
- </tr>
1171
- <tr>
1172
- <td style="padding:15px">iapRunAdapterConnectivity(callback)</td>
1173
- <td style="padding:15px">This call will return the results of a connectivity check.</td>
1174
- <td style="padding:15px">Yes</td>
1175
- </tr>
1176
- <tr>
1177
- <td style="padding:15px">iapRunAdapterBasicGet(callback)</td>
1178
- <td style="padding:15px">This call will return the results of running basic get API calls.</td>
1179
- <td style="padding:15px">Yes</td>
1180
- </tr>
1181
- <tr>
1182
- <td style="padding:15px">iapMoveAdapterEntitiesToDB(callback)</td>
1183
- <td style="padding:15px">This call will push the adapter configuration from the entities directory into the Adapter or IAP Database.</td>
1184
- <td style="padding:15px">Yes</td>
1185
- </tr>
1186
- <tr>
1187
- <td style="padding:15px">iapDeactivateTasks(tasks, callback)</td>
1188
- <td style="padding:15px">This call provides the ability to remove tasks from the adapter.</td>
1189
- <td style="padding:15px">Yes</td>
1190
- </tr>
1191
- <tr>
1192
- <td style="padding:15px">iapActivateTasks(tasks, callback)</td>
1193
- <td style="padding:15px">This call provides the ability to add deactivated tasks back into the adapter.</td>
1194
- <td style="padding:15px">Yes</td>
1195
- </tr>
1196
- <tr>
1197
- <td style="padding:15px">iapExpandedGenericAdapterRequest(metadata, uriPath, restMethod, pathVars, queryData, requestBody, addlHeaders, callback)</td>
1198
- <td style="padding:15px">This is an expanded Generic Call. The metadata object allows us to provide many new capabilities within the generic request.</td>
1199
- <td style="padding:15px">Yes</td>
1200
- </tr>
1201
- <tr>
1202
- <td style="padding:15px">genericAdapterRequest(uriPath, restMethod, queryData, requestBody, addlHeaders, callback)</td>
1203
- <td style="padding:15px">This call allows you to provide the path to have the adapter call. It is an easy way to incorporate paths that have not been built into the adapter yet.</td>
1204
- <td style="padding:15px">Yes</td>
1205
- </tr>
1206
- <tr>
1207
- <td style="padding:15px">genericAdapterRequestNoBasePath(uriPath, restMethod, queryData, requestBody, addlHeaders, callback)</td>
1208
- <td style="padding:15px">This call is the same as the genericAdapterRequest only it does not add a base_path or version to the call.</td>
1209
- <td style="padding:15px">Yes</td>
1210
- </tr>
1211
- <tr>
1212
- <td style="padding:15px">iapRunAdapterLint(callback)</td>
1213
- <td style="padding:15px">Runs lint on the addapter and provides the information back.</td>
1214
- <td style="padding:15px">Yes</td>
1215
- </tr>
1216
- <tr>
1217
- <td style="padding:15px">iapRunAdapterTests(callback)</td>
1218
- <td style="padding:15px">Runs baseunit and unit tests on the adapter and provides the information back.</td>
1219
- <td style="padding:15px">Yes</td>
1220
- </tr>
1221
- <tr>
1222
- <td style="padding:15px">iapGetAdapterInventory(callback)</td>
1223
- <td style="padding:15px">This call provides some inventory related information about the adapter.</td>
1224
- <td style="padding:15px">Yes</td>
1225
- </tr>
1226
- </table>
1227
- <br>
1228
-
1229
- ### Adapter Cache Calls
1230
-
1231
- These are adapter methods that are used for adapter caching. If configured, the adapter will cache based on the interval provided. However, you can force a population of the cache manually as well.
1232
-
1233
- <table border="1" class="bordered-table">
1234
- <tr>
1235
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Method Signature</span></th>
1236
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
1237
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Workflow?</span></th>
1238
- </tr>
1239
- <tr>
1240
- <td style="padding:15px">iapPopulateEntityCache(entityTypes, callback)</td>
1241
- <td style="padding:15px">This call populates the adapter cache.</td>
1242
- <td style="padding:15px">Yes</td>
1243
- </tr>
1244
- <tr>
1245
- <td style="padding:15px">iapRetrieveEntitiesCache(entityType, options, callback)</td>
1246
- <td style="padding:15px">This call retrieves the specific items from the adapter cache.</td>
1247
- <td style="padding:15px">Yes</td>
1248
- </tr>
1249
- </table>
1250
- <br>
1251
-
1252
- ### Adapter Broker Calls
1253
-
1254
- These are adapter methods that are used to integrate to IAP Brokers. This adapter currently supports the following broker calls.
1255
-
1256
- <table border="1" class="bordered-table">
1257
- <tr>
1258
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Method Signature</span></th>
1259
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
1260
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Workflow?</span></th>
1261
- </tr>
1262
- <tr>
1263
- <td style="padding:15px">hasEntities(entityType, entityList, callback)</td>
1264
- <td style="padding:15px">This call is utilized by the IAP Device Broker to determine if the adapter has a specific entity and item of the entity.</td>
1265
- <td style="padding:15px">No</td>
1266
- </tr>
1267
- <tr>
1268
- <td style="padding:15px">getDevice(deviceName, callback)</td>
1269
- <td style="padding:15px">This call returns the details of the requested device.</td>
1270
- <td style="padding:15px">No</td>
1271
- </tr>
1272
- <tr>
1273
- <td style="padding:15px">getDevicesFiltered(options, callback)</td>
1274
- <td style="padding:15px">This call returns the list of devices that match the criteria provided in the options filter.</td>
1275
- <td style="padding:15px">No</td>
1276
- </tr>
1277
- <tr>
1278
- <td style="padding:15px">isAlive(deviceName, callback)</td>
1279
- <td style="padding:15px">This call returns whether the device status is active</td>
1280
- <td style="padding:15px">No</td>
1281
- </tr>
1282
- <tr>
1283
- <td style="padding:15px">getConfig(deviceName, format, callback)</td>
1284
- <td style="padding:15px">This call returns the configuration for the selected device.</td>
1285
- <td style="padding:15px">No</td>
1286
- </tr>
1287
- <tr>
1288
- <td style="padding:15px">iapGetDeviceCount(callback)</td>
1289
- <td style="padding:15px">This call returns the count of devices.</td>
1290
- <td style="padding:15px">No</td>
1291
- </tr>
1292
- </table>
1293
- <br>
1294
-
1295
- ### Specific Adapter Calls
1296
-
1297
- Specific adapter calls are built based on the API of the Datadog. The Adapter Builder creates the proper method comments for generating JS-DOC for the adapter. This is the best way to get information on the calls.
1298
-
1299
- <table border="1" class="bordered-table">
1300
- <tr>
1301
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Method Signature</span></th>
1302
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
1303
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Path</span></th>
1304
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Workflow?</span></th>
1305
- </tr>
1306
- <tr>
1307
- <td style="padding:15px">createUser(body, apiKey, applicationKey, callback)</td>
1308
- <td style="padding:15px">### Overview
1309
-
1310
- Create a user for your organization.
1311
-
1312
- ### ARGUMENTS
1313
-
1314
- * **`handle`** [*required*]: The user handle, must be a valid email.
1315
- * **`name`** [*optional*, *default*=**None**]: The name of the user.
1316
- * **`access_role`** [*optional*, *default*=**st**]: The access role of the user. Choose from:
1317
- * **st** (standard user),
1318
- * **adm** (admin user),
1319
- * **ro** (read-only user).
1320
- *Note: users can be created with admin access role only with application keys belonging to administrators...(description truncated)</td>
1321
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1322
- <td style="padding:15px">Yes</td>
1323
- </tr>
1324
- <tr>
1325
- <td style="padding:15px">getAllUsers(apiKey, applicationKey, callback)</td>
1326
- <td style="padding:15px">### Overview
1327
-
1328
- Get all user for your organization.
1329
-
1330
- ### Arguments
1331
-
1332
- This endpoint takes no JSON argument.</td>
1333
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1334
- <td style="padding:15px">Yes</td>
1335
- </tr>
1336
- <tr>
1337
- <td style="padding:15px">getUser(apiKey, applicationKey, callback)</td>
1338
- <td style="padding:15px">### Overview
1339
-
1340
- Get a user details.
1341
-
1342
- ### Arguments
1343
-
1344
- * **`user_handle`** [*required*]: The handle of the user.</td>
1345
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1346
- <td style="padding:15px">Yes</td>
1347
- </tr>
1348
- <tr>
1349
- <td style="padding:15px">updateUser(body, apiKey, applicationKey, callback)</td>
1350
- <td style="padding:15px">### Overview
1351
-
1352
- Update a user informations,
1353
-
1354
- **Note**: It can only be used with application keys belonging to administrators.
1355
-
1356
- ##### ARGUMENTS
1357
- * **`id`** [*required*]: The handle of the user.
1358
- * **`name`** [*optional*, *default*=**None**]: The new name of the user.
1359
- * **`email`** [*optional*, *default*=**None**]: The new email of the user.
1360
- * **`disabled`** [*optional*, *default*=**None**]: The new disabled status of the user.
1361
- * **`access_role`** [*optional*, *default*=**st**]: The access role of the...(description truncated)</td>
1362
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1363
- <td style="padding:15px">Yes</td>
1364
- </tr>
1365
- <tr>
1366
- <td style="padding:15px">disableUser(apiKey, applicationKey, callback)</td>
1367
- <td style="padding:15px">### Overview
1368
-
1369
- Delete a user from an organization.
1370
-
1371
- **Note**: This endpoint can only be used with application keys belonging to administrators.
1372
-
1373
- ### Arguments
1374
-
1375
- * **`id`** [*required*]: The handle of the user.</td>
1376
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1377
- <td style="padding:15px">Yes</td>
1378
- </tr>
1379
- <tr>
1380
- <td style="padding:15px">authenticationCheck(apiKey, callback)</td>
1381
- <td style="padding:15px">All requests to Datadog's API must be authenticated. Requests that write data require *reporting access* and require an `API key`. Requests that read data require *full access* and also require an `application key`.
1382
-
1383
- [Manage your account's API and application keys](https://app.datadoghq.com/account/settings#api).
1384
-
1385
- This GET call just checks to see if an API call key is valid.</td>
1386
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1387
- <td style="padding:15px">Yes</td>
1388
- </tr>
1389
- <tr>
1390
- <td style="padding:15px">postACheckStatus(body, apiKey, applicationKey, callback)</td>
1391
- <td style="padding:15px">### Overview
1392
-
1393
- This POST call allows for you to POST check statuses for use with monitors
1394
-
1395
- ### Arguments
1396
-
1397
- * **`check`** *[required]*: The text for the message
1398
-
1399
- * **`host_name`** *[required]*: The name of the host submitting the check
1400
-
1401
- * **`status`** *[optional]*: An integer for the status of the check:
1402
- * 0 : OK
1403
- * 1 : WARNING
1404
- * 2 : CRITICAL
1405
- * 3 : UNKNOWN
1406
-
1407
-
1408
- * **`timestamp`** *[optional]*: POSIX timestamp of the event.
1409
-
1410
- * **`message`** *[optional]*: A description of why this stat...(description truncated)</td>
1411
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1412
- <td style="padding:15px">Yes</td>
1413
- </tr>
1414
- <tr>
1415
- <td style="padding:15px">replyToComment(body, apiKey, applicationKey, callback)</td>
1416
- <td style="padding:15px">### Overview
1417
-
1418
- This POST call allows for you to POST status messages to a previous post via ID.
1419
-
1420
- ### Arguments
1421
-
1422
- * **`message`** [*required*]: The comment text.
1423
-
1424
- * **`handle`** [*optional*, *default* = **application key owner**]: The handle of the user making the comment.
1425
-
1426
- * **`related_event_id`** [*optional*, *default* = **None**]: The id of another comment or event to reply to.</td>
1427
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1428
- <td style="padding:15px">Yes</td>
1429
- </tr>
1430
- <tr>
1431
- <td style="padding:15px">editAComment(body, apiKey, applicationKey, callback)</td>
1432
- <td style="padding:15px">### Overview
1433
-
1434
- This POST call allows for you to change a previously posted comment by commentId
1435
-
1436
- ### Arguments
1437
-
1438
- * **`message`** [*optional*, *default* = **original message**]: The comment text.
1439
-
1440
- * **`handle`** [*optional*, *default* = **Application key owner**]: The handle of the user making the comment.</td>
1441
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1442
- <td style="padding:15px">Yes</td>
1443
- </tr>
1444
- <tr>
1445
- <td style="padding:15px">deleteAComment(apiKey, applicationKey, callback)</td>
1446
- <td style="padding:15px">### Overview
1447
-
1448
- Thiscall allows for you to DELETE a previously posted comment by with a given .
1449
-
1450
- ### Arguments
1451
-
1452
- This endpoint takes no JSON arguments.</td>
1453
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1454
- <td style="padding:15px">Yes</td>
1455
- </tr>
1456
- <tr>
1457
- <td style="padding:15px">createADashboard(body, apiKey, applicationKey, callback)</td>
1458
- <td style="padding:15px">### Overview
1459
-
1460
- Create a Dashboard in Datadog.
1461
-
1462
- ### Arguments
1463
-
1464
- * **`title`** [*required*]: Title of the dashboard.
1465
- * **`widgets`** [*required*]: List of widgets to display on the dashboard. Widget definitions follow this form:
1466
- * **`definition`** [*required*]: [Definition of the widget.](https://docs.datadoghq.com//graphing/widgets)
1467
- * **`id`** [*optional*, *default*=**auto-generated integer**]: ID of the widget.
1468
- * **`layout_type`** [*required*]: Layout type of the dashboard. Available value...(description truncated)</td>
1469
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1470
- <td style="padding:15px">Yes</td>
1471
- </tr>
1472
- <tr>
1473
- <td style="padding:15px">updateADashboard(body, apiKey, applicationKey, callback)</td>
1474
- <td style="padding:15px">### Overview
1475
-
1476
- Update a Dashboard in Datadog.
1477
-
1478
- ### Arguments
1479
-
1480
- * **`title`** [*required*]: Title of the dashboard.
1481
- * **`widgets`** [*required*]: List of widgets to display on the dashboard. Widget definitions follow this form:
1482
- * **`definition`** [*required*]: [Definition of the widget.](https://docs.datadoghq.com/graphing/widgets)
1483
- * **`id`** [*optional*, *default*=**auto-generated integer**]: ID of the widget.
1484
- * **`layout_type`** [*required*]: Layout type of the dashboard. Available values...(description truncated)</td>
1485
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1486
- <td style="padding:15px">Yes</td>
1487
- </tr>
1488
- <tr>
1489
- <td style="padding:15px">deleteADashboard(apiKey, applicationKey, callback)</td>
1490
- <td style="padding:15px">### Overview
1491
-
1492
- Delete an existing dashboard.
1493
-
1494
- ### Arguments
1495
-
1496
- This end point takes no JSON arguments.</td>
1497
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1498
- <td style="padding:15px">Yes</td>
1499
- </tr>
1500
- <tr>
1501
- <td style="padding:15px">getADashboard(apiKey, applicationKey, callback)</td>
1502
- <td style="padding:15px">### Overview
1503
-
1504
- Fetch an existing dashboard's definition.
1505
-
1506
- ### Arguments
1507
-
1508
- This end point takes no JSON arguments.</td>
1509
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1510
- <td style="padding:15px">Yes</td>
1511
- </tr>
1512
- <tr>
1513
- <td style="padding:15px">getAllDashboards(apiKey, applicationKey, callback)</td>
1514
- <td style="padding:15px">### Overview
1515
-
1516
- Fetch all existing Dashboards.
1517
-
1518
- ### Arguments
1519
-
1520
- This end point takes no JSON arguments.</td>
1521
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1522
- <td style="padding:15px">Yes</td>
1523
- </tr>
1524
- <tr>
1525
- <td style="padding:15px">getADashboardList(apiKey, applicationKey, callback)</td>
1526
- <td style="padding:15px">### Overview
1527
-
1528
- Fetch an existing dashboard list’s definition.
1529
-
1530
- ### Arguments
1531
-
1532
- This end point takes no JSON arguments.</td>
1533
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1534
- <td style="padding:15px">Yes</td>
1535
- </tr>
1536
- <tr>
1537
- <td style="padding:15px">updateADashboardList(body, apiKey, applicationKey, callback)</td>
1538
- <td style="padding:15px">### Overview
1539
-
1540
- Update the name of a dashboard list
1541
-
1542
- ### Arguments
1543
-
1544
- * **`name`** [*required*]: The name of the dashboard list.</td>
1545
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1546
- <td style="padding:15px">Yes</td>
1547
- </tr>
1548
- <tr>
1549
- <td style="padding:15px">deleteADashboardList(apiKey, applicationKey, callback)</td>
1550
- <td style="padding:15px">### Overview
1551
-
1552
- Delete an existing dashboard list.
1553
-
1554
- ### Arguments
1555
-
1556
- This end point takes no JSON arguments.</td>
1557
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1558
- <td style="padding:15px">Yes</td>
1559
- </tr>
1560
- <tr>
1561
- <td style="padding:15px">getAllDashboardLists(apiKey, applicationKey, callback)</td>
1562
- <td style="padding:15px">### Overview
1563
-
1564
- Fetch all of your existing dashboard list definitions.
1565
-
1566
- ### Arguments
1567
-
1568
- This end point takes no JSON arguments.</td>
1569
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1570
- <td style="padding:15px">Yes</td>
1571
- </tr>
1572
- <tr>
1573
- <td style="padding:15px">createADashboardList(body, apiKey, applicationKey, callback)</td>
1574
- <td style="padding:15px">### Overview
1575
-
1576
- Create an empty dashboard list.
1577
-
1578
- ### Arguments
1579
-
1580
- * **`name`** [*required*]: The name of the dashboard list.</td>
1581
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1582
- <td style="padding:15px">Yes</td>
1583
- </tr>
1584
- <tr>
1585
- <td style="padding:15px">getItemsOfADashboardList(apiKey, applicationKey, callback)</td>
1586
- <td style="padding:15px">### Overview
1587
-
1588
- Fetch the dashboard list’s dashboard definitions.
1589
-
1590
- ### Arguments
1591
-
1592
- This end point takes no JSON arguments.</td>
1593
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1594
- <td style="padding:15px">Yes</td>
1595
- </tr>
1596
- <tr>
1597
- <td style="padding:15px">addItemsToDashboardList(body, apiKey, applicationKey, callback)</td>
1598
- <td style="padding:15px">### Overview
1599
-
1600
- Add dashboards to an existing dashboard list.
1601
-
1602
- ### Arguments
1603
-
1604
- * **`dashboards`** [*required*]: A list of dashboards to add to the list. Dashboard definitions follow this form:
1605
- * **`type`** [*required*]: The type of the dashboard. The type must be one of:
1606
- * `"custom_timeboard"`
1607
- * `"custom_screenboard"`
1608
- * `"integration_screenboard"`
1609
- * `"integration_timeboard"`
1610
- * `"host_timeboard"`
1611
- * **`id`** [*required*]: The id of the dashboard.</td>
1612
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1613
- <td style="padding:15px">Yes</td>
1614
- </tr>
1615
- <tr>
1616
- <td style="padding:15px">updateItemsOfADashboardList(body, apiKey, applicationKey, callback)</td>
1617
- <td style="padding:15px">### Overview
1618
-
1619
- Update dashboards of an existing dashboard list.
1620
-
1621
- ### ARGUMENTS
1622
-
1623
- * **`dashboards`** [*required*]: The new list of dashboards for the dashboard list. Dashboard definitions follow this form:
1624
- * **`type`** [*required*]: The type of the dashboard. The type must be one of:
1625
- * `"custom_timeboard"`
1626
- * `"custom_screenboard"`
1627
- * `"integration_screenboard"`
1628
- * `"integration_timeboard"`
1629
- * `"host_timeboard"`
1630
- * **`id`** [*required*]: The id of th...(description truncated)</td>
1631
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1632
- <td style="padding:15px">Yes</td>
1633
- </tr>
1634
- <tr>
1635
- <td style="padding:15px">deleteItemsFromADashboardList(apiKey, applicationKey, callback)</td>
1636
- <td style="padding:15px">### Overview
1637
-
1638
- Delete dashboards from an existing dashboard list.
1639
-
1640
- ### Arguments
1641
-
1642
- * **`dashboards`** [*required*]: A list of dashboards to remove from the list. Dashboard definitions follow this form:
1643
- * **`type`** [*required*]: The type of the dashboard. The type must be one of:
1644
- * `"custom_timeboard"`
1645
- * `"custom_screenboard"`
1646
- * `"integration_screenboard"`
1647
- * `"integration_timeboard"`
1648
- * `"host_timeboard"`
1649
- * **`id`** [*required*]: The id of the d...(description truncated)</td>
1650
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1651
- <td style="padding:15px">Yes</td>
1652
- </tr>
1653
- <tr>
1654
- <td style="padding:15px">scheduleMonitorDowntime(body, apiKey, applicationKey, callback)</td>
1655
- <td style="padding:15px">### Overview
1656
-
1657
- Schedule a single Downtime.
1658
-
1659
- ### ARGUMENTS
1660
-
1661
- * **`scope`** [*required*]: The scope(s) to which the downtime applies, e.g. `host:app2`. Provide multiple scopes as a comma-separated list, e.g. `env:dev,env:prod`. The resulting downtime applies to sources that matches ALL provided scopes (i.e. `env:dev` **AND** `env:prod`), NOT any of them.
1662
- * **`monitor_tags`** [*optional*, *default*=**no monitor tag filter**]: A comma-separated list of monitor tags, i.e. tags that are applied directly...(description truncated)</td>
1663
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1664
- <td style="padding:15px">Yes</td>
1665
- </tr>
1666
- <tr>
1667
- <td style="padding:15px">getAllMointorDowntimes(apiKey, applicationKey, callback)</td>
1668
- <td style="padding:15px">### Overview
1669
-
1670
- Get All Scheduled Downtimes
1671
-
1672
- ### ARGUMENTS
1673
-
1674
- * **`current_only`** [*optional*, *default* = **False**]: Only return downtimes that are activewhen the request is made.</td>
1675
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1676
- <td style="padding:15px">Yes</td>
1677
- </tr>
1678
- <tr>
1679
- <td style="padding:15px">updateMonitorDowntime(body, apiKey, applicationKey, callback)</td>
1680
- <td style="padding:15px">### Overview
1681
-
1682
- Update a single Downtime by downtime_id.
1683
-
1684
- ### Arguments
1685
-
1686
- * **`id`** [*required*]: The integer id of the downtime to be updated
1687
- * **`scope`** [*required*]: The scope to which the downtime applies, e.g. 'host:app2'. Provide multiple scopes as a comma-separated list, e.g. 'env:dev,env:prod'. The resulting downtime applies to sources that matches ALL provided scopes (i.e. env:dev AND env:prod), NOT any of them.
1688
- * **`monitor_tags`** [*optional*, *default*=**no monitor tag filter**]: A c...(description truncated)</td>
1689
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1690
- <td style="padding:15px">Yes</td>
1691
- </tr>
1692
- <tr>
1693
- <td style="padding:15px">cancelMonitorDowntime(apiKey, applicationKey, callback)</td>
1694
- <td style="padding:15px">DELETE a Downtime Detail by downtime_id</td>
1695
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1696
- <td style="padding:15px">Yes</td>
1697
- </tr>
1698
- <tr>
1699
- <td style="padding:15px">getAMonitorDowntime(apiKey, applicationKey, callback)</td>
1700
- <td style="padding:15px">### Overview
1701
-
1702
- Get Downtime Detail by downtime_id
1703
-
1704
- ### Arguments
1705
-
1706
- This endpoint takes no JSON arguments.</td>
1707
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1708
- <td style="padding:15px">Yes</td>
1709
- </tr>
1710
- <tr>
1711
- <td style="padding:15px">cancelMonitorDowntimesByScope(body, apiKey, applicationKey, callback)</td>
1712
- <td style="padding:15px">### Overview
1713
-
1714
- DELETE all Downtimes that match the scope of X
1715
-
1716
- ### Arguments
1717
-
1718
- * **`scope`** [*required*]: Cancel all downtimes with the given scope(s), e.g.: `env:prod`, `role:db,role:db-slave`</td>
1719
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1720
- <td style="padding:15px">Yes</td>
1721
- </tr>
1722
- <tr>
1723
- <td style="padding:15px">getAllEmbeddableGraphs(apiKey, applicationKey, callback)</td>
1724
- <td style="padding:15px">### Overview
1725
-
1726
- Gets a list of previously created embeddable graphs.
1727
-
1728
- Returns: A JSON list containing information on previously created embeds from both the UI and the API. Each JSON graph response is in the same format as returned by GET `api/v1/graph/embed/ `.
1729
-
1730
- ### ARGUMENTS
1731
-
1732
- This endpoint takes no JSON arguments.</td>
1733
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1734
- <td style="padding:15px">Yes</td>
1735
- </tr>
1736
- <tr>
1737
- <td style="padding:15px">createEmbedGraph(body, apiKey, applicationKey, callback)</td>
1738
- <td style="padding:15px">### Overview
1739
-
1740
- Creates a new embeddable graph.
1741
-
1742
- Returns: A JSON consisting of the same elements returned by GET `api/v1/graph/embed/ `. On failure, the return value is a JSON containing an error message {errors: [messages]}.
1743
-
1744
- Note: If an embed already exists for the exact same query in a given organization, the older embed is returned instead of creating a new embed.
1745
-
1746
- If you are interested in using template variables, see [Embeddable Graphs with Template Variables](https://docs.datadoghq.com/grap...(description truncated)</td>
1747
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1748
- <td style="padding:15px">Yes</td>
1749
- </tr>
1750
- <tr>
1751
- <td style="padding:15px">getASpecificEmbed(apiKey, applicationKey, callback)</td>
1752
- <td style="padding:15px">### Overview
1753
-
1754
- Get the HTML fragment for a previously generated embed with embed_id.
1755
-
1756
- Returns: A JSON object with 8 elements:
1757
-
1758
- * `embed_id`: Token of the embed
1759
- * `graph_title`: Tile of the graph
1760
- * `dash_name`: Name of the dashboard the graph is on (null if none)
1761
- * `dash_url`: URL of the dashboard the graph is on (null if none)
1762
- * `shared_by`: ID of the use who shared the embed
1763
- * `html`: HTML fragment for the embed (iframe)
1764
- * `revoked`: Boolean flag for whther or not the embed is revoked
1765
-
1766
- On failur...(description truncated)</td>
1767
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1768
- <td style="padding:15px">Yes</td>
1769
- </tr>
1770
- <tr>
1771
- <td style="padding:15px">enableEmbed(apiKey, applicationKey, callback)</td>
1772
- <td style="padding:15px">### Overview
1773
-
1774
- Enable a specified embed.
1775
-
1776
- Returns: A JSON containing the success message `{success: [message]}`. On failure, the return value is a JSON containing an error message `{errors: [messages]}`.
1777
-
1778
- ### Arguments
1779
-
1780
- This endpoint takes no JSON arguments.</td>
1781
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1782
- <td style="padding:15px">Yes</td>
1783
- </tr>
1784
- <tr>
1785
- <td style="padding:15px">revokeEmbed(apiKey, applicationKey, callback)</td>
1786
- <td style="padding:15px">### Overview
1787
-
1788
- Revoke a specified embed.
1789
-
1790
- Returns: A JSON containing the success message `{success: [message]}`. On failure, the return value is a JSON containing an error message `{errors: [messages]}`.
1791
-
1792
- ### Arguments
1793
-
1794
- This endpoint takes no JSON arguments.</td>
1795
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1796
- <td style="padding:15px">Yes</td>
1797
- </tr>
1798
- <tr>
1799
- <td style="padding:15px">postAnEvent(body, apiKey, applicationKey, callback)</td>
1800
- <td style="padding:15px">### Overview
1801
-
1802
- This endpoint allows you to post events to the stream. Tag them, set priority and event aggregate them with other events.
1803
-
1804
- ### Arguments
1805
-
1806
- * **`title`** [*required*]: The event title. *Limited to 100 characters.* Use `msg_title` with [the Datadog Ruby library](https://github.com/DataDog/dogapi-rb).
1807
- * **`text`** [*required*]: The body of the event. *Limited to 4000 characters.* The text supports [markdown](https://docs.datadoghq.com/graphing/event_stream/#markdown-events). Use `m...(description truncated)</td>
1808
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1809
- <td style="padding:15px">Yes</td>
1810
- </tr>
1811
- <tr>
1812
- <td style="padding:15px">queryTheEventStream(apiKey, applicationKey, callback)</td>
1813
- <td style="padding:15px">### Overview
1814
-
1815
- The [event stream](https://docs.datadoghq.com/graphing/event_stream) can be queried and filtered by time, priority, sources and tags.
1816
- Note: if the event you're querying contains markdown formatting of any kind, you may see characters such as %,\,n in your output
1817
-
1818
- ### Arguments
1819
-
1820
- * **`start`** [*required*]: POSIX timestamp.
1821
- * **`end`** [*required*]: POSIX timestamp.
1822
- * **`priority`** [*optional*, *default*=**None**]: Priority of your events: **low** or **normal**.
1823
- * **`sources`** [*op...(description truncated)</td>
1824
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1825
- <td style="padding:15px">Yes</td>
1826
- </tr>
1827
- <tr>
1828
- <td style="padding:15px">getAnEvent(apiKey, applicationKey, callback)</td>
1829
- <td style="padding:15px">### Overview
1830
-
1831
- Get event details by event_id
1832
-
1833
- ### Arguments
1834
-
1835
- This endpoint takes no JSON arguments.</td>
1836
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1837
- <td style="padding:15px">Yes</td>
1838
- </tr>
1839
- <tr>
1840
- <td style="padding:15px">deleteAnEvent(apiKey, applicationKey, callback)</td>
1841
- <td style="padding:15px">### Overview
1842
-
1843
- DELETE event details by event_id
1844
-
1845
- ### Arguments
1846
-
1847
- This endpoint takes no JSON arguments.</td>
1848
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1849
- <td style="padding:15px">Yes</td>
1850
- </tr>
1851
- <tr>
1852
- <td style="padding:15px">graphASnapshot(apiKey, applicationKey, metricQuery, start, end, title, callback)</td>
1853
- <td style="padding:15px">### Overview
1854
-
1855
- Get a Graph snapshot.
1856
-
1857
- ##### ARGUMENTS
1858
-
1859
- * **`metric_query`** [*required*]: The metric query.
1860
- * **`start`** [*required*]: The POSIX timestamp of the start of the query.
1861
- * **`end`** [*required*]: The POSIX timestamp of the end of the query.
1862
- * **`event_query`** [*optional*, *default*=**None**]: A query that adds event bands to the graph.
1863
- * **`graph_def`** [*optional*, *default*=**None**]: A JSON document defining the graph. `graph_def` can be used instead of `metric_query`. The JSON d...(description truncated)</td>
1864
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1865
- <td style="padding:15px">Yes</td>
1866
- </tr>
1867
- <tr>
1868
- <td style="padding:15px">searchHosts(apiKey, applicationKey, filter, sortField, sortDir, start, count, callback)</td>
1869
- <td style="padding:15px">### Overview
1870
-
1871
- This endpoint allows searching for hosts by name, alias, or tag. Hosts live within the past 3 hours are included. Results are paginated with a max of 100 results at a time.
1872
-
1873
- ### Arguments
1874
-
1875
- * **`filter`** [*optional*, *default*=**None**]: Query string to filter search results.
1876
- * **`sort_field`** [*optional*, *default*=**cpu**]: Sort hosts by the given field. Options: **status**, **apps**, **cpu**, **iowait**, **load**
1877
- * **`sort_dir`** [*optional*, *default*=**desc**]: Direction of s...(description truncated)</td>
1878
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1879
- <td style="padding:15px">Yes</td>
1880
- </tr>
1881
- <tr>
1882
- <td style="padding:15px">hostTotals(apiKey, applicationKey, callback)</td>
1883
- <td style="padding:15px">### Overview
1884
-
1885
- This endpoint returns the total number of active and up hosts in your Datadog account. Active means the host has reported in the past hour, and up means it has reported in the past two hours.
1886
-
1887
- ### ARGUMENTS
1888
-
1889
- This endpoint takes no JSON arguments.</td>
1890
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1891
- <td style="padding:15px">Yes</td>
1892
- </tr>
1893
- <tr>
1894
- <td style="padding:15px">muteAHost(body, apiKey, applicationKey, callback)</td>
1895
- <td style="padding:15px">### Overview
1896
-
1897
- Mute a host in order to avoid any monitor to trigger on it.
1898
-
1899
- ### Arguments
1900
-
1901
- * **`end`** [*optional*, *default*=**None**]: POSIX timestamp when the host is unmuted. If omitted, the host remains muted until explicitly unmuted.
1902
- * **`message`** [*optional*, *default*=**None**]: Message to associate with the muting of this host.
1903
- * **`override`** [*optional*, *default*=**False**]: If true and the host is already muted, replaces existing host mute settings.</td>
1904
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1905
- <td style="padding:15px">Yes</td>
1906
- </tr>
1907
- <tr>
1908
- <td style="padding:15px">unmuteAHost(body, apiKey, applicationKey, callback)</td>
1909
- <td style="padding:15px">### Overview
1910
-
1911
- Unmute a previously muted host
1912
-
1913
- ### Arguments
1914
-
1915
- This endpoint takes no JSON arguments.</td>
1916
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1917
- <td style="padding:15px">Yes</td>
1918
- </tr>
1919
- <tr>
1920
- <td style="padding:15px">listAWSAccounts(apiKey, applicationKey, callback)</td>
1921
- <td style="padding:15px">### Overview
1922
-
1923
- List all configured AWS accounts for Datadog.
1924
-
1925
- ### Arguments
1926
-
1927
- This endpoint takes no JSON argument.</td>
1928
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1929
- <td style="padding:15px">Yes</td>
1930
- </tr>
1931
- <tr>
1932
- <td style="padding:15px">createAnAWSIntegration(body, apiKey, applicationKey, callback)</td>
1933
- <td style="padding:15px">### Overview
1934
-
1935
- Create a Datadog-Amazon Web Services integration.
1936
-
1937
- **Note**: Using the `POST` method updates your integration configuration by **adding** your new configuration to the existing one in your Datadog organization.
1938
-
1939
- ### Arguments
1940
-
1941
- * **`account_id`** [*required*]:
1942
-
1943
- Your AWS Account ID without dashes.
1944
- [Consult the Datadog AWS integration to learn more][1] about your AWS account ID.
1945
-
1946
- * **`access_key_id`** [*optional*, *default*=**None**]:
1947
-
1948
- If your AWS account is a GovCloud or ...(description truncated)</td>
1949
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1950
- <td style="padding:15px">Yes</td>
1951
- </tr>
1952
- <tr>
1953
- <td style="padding:15px">deleteAnAWSIntegration(apiKey, applicationKey, callback)</td>
1954
- <td style="padding:15px">### Overview
1955
-
1956
- Delete your Datadog-AWS integration directly through Datadog API. [Read more about Datadog-AWS integration][1].
1957
-
1958
- ### Arguments
1959
-
1960
- This endpoint takes no JSON argument.
1961
-
1962
- [1]: https://docs.datadoghq.com/integrations/amazon_web_services</td>
1963
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1964
- <td style="padding:15px">Yes</td>
1965
- </tr>
1966
- <tr>
1967
- <td style="padding:15px">listAvailableNamespaceRules(apiKey, applicationKey, callback)</td>
1968
- <td style="padding:15px">### Overview
1969
-
1970
- List available namespace rules for your AWS integration
1971
-
1972
- ### Arguments
1973
-
1974
- This endpoint takes no JSON arguments</td>
1975
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1976
- <td style="padding:15px">Yes</td>
1977
- </tr>
1978
- <tr>
1979
- <td style="padding:15px">listAWSFilteringRules(apiKey, applicationKey, callback)</td>
1980
- <td style="padding:15px">### Overview
1981
-
1982
- List AWS Accounts (role-based only) in Datadog.
1983
-
1984
- ### Arguments
1985
-
1986
- This endpoint takes no JSON arguments.</td>
1987
- <td style="padding:15px">{base_path}/{version}?{query}</td>
1988
- <td style="padding:15px">Yes</td>
1989
- </tr>
1990
- <tr>
1991
- <td style="padding:15px">configureAWSFilteringRuleCopy(body, apiKey, applicationKey, callback)</td>
1992
- <td style="padding:15px">### Overview
1993
-
1994
- List AWS Accounts (role-based only) in Datadog. [Read more about Datadog-AWS integration][1].
1995
-
1996
- ### Arguments
1997
-
1998
- * **`account_id`** [*required*]: Your AWS Account ID without dashes. [Consult the Datadog AWS integration to learn more][2] about your AWS account ID.
1999
-
2000
- * **`access_key_id`** [*optional*, *default*=**None**]: If your AWS account is a GovCloud or China account, enter the corresponding Access Key ID.$
2001
-
2002
- * **`namespace`** [*required*]: The AWS namespace to apply filtering too (e...(description truncated)</td>
2003
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2004
- <td style="padding:15px">Yes</td>
2005
- </tr>
2006
- <tr>
2007
- <td style="padding:15px">deleteAWSFilteringRule(apiKey, applicationKey, callback)</td>
2008
- <td style="padding:15px">Delete a Datadog-AWS Filtering rule</td>
2009
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2010
- <td style="padding:15px">Yes</td>
2011
- </tr>
2012
- <tr>
2013
- <td style="padding:15px">generateNewExternalIDs(body, apiKey, applicationKey, callback)</td>
2014
- <td style="padding:15px">### Overview
2015
-
2016
- Generate a new AWS external id for a given AWS account id and role name pair.
2017
-
2018
- ### Arguments
2019
-
2020
-
2021
- * **`account_id`** [*required*]:
2022
-
2023
- Your AWS Account ID without dashes.
2024
- [Consult the Datadog AWS integration to learn more][1] about your AWS account ID.
2025
-
2026
- * **`role_name`** [*required*]:
2027
-
2028
- Your Datadog role delegation name.
2029
- For more information about you AWS account Role name, [see the Datadog AWS integration configuration info][2].
2030
-
2031
- [1]: /integrations/amazon_web_services/#co...(description truncated)</td>
2032
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2033
- <td style="padding:15px">Yes</td>
2034
- </tr>
2035
- <tr>
2036
- <td style="padding:15px">listAzureAccount(apiKey, applicationKey, callback)</td>
2037
- <td style="padding:15px">### Overview
2038
-
2039
- List all Datadog-Azure integrations configured for your Datadog Account.
2040
-
2041
- ### Arguments
2042
-
2043
- This endpoint takes no JSON argument.</td>
2044
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2045
- <td style="padding:15px">Yes</td>
2046
- </tr>
2047
- <tr>
2048
- <td style="padding:15px">updateAzureAccountSHostFilters(body, apiKey, applicationKey, callback)</td>
2049
- <td style="padding:15px">### Overview
2050
-
2051
- Update Datadog-Azure host filtering.
2052
-
2053
- ### Arguments
2054
-
2055
- Refer to the [Datadog-Azure integration installation instructions][1] to see how to obtain the following field values for your organization.
2056
-
2057
- * **`tenant_name`** [*required*]: Your Azure Active Directory ID.
2058
-
2059
- * **`client_id`** [*required*]: Your Azure web application ID.
2060
-
2061
- * **`client_secret`** [*required*]: Your Azure web application secret key.
2062
-
2063
- * **`host_filters`** [*optional*, *default*=**None**]: Limit the Azure instances th...(description truncated)</td>
2064
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2065
- <td style="padding:15px">Yes</td>
2066
- </tr>
2067
- <tr>
2068
- <td style="padding:15px">deleteAnAzureAccount(apiKey, applicationKey, callback)</td>
2069
- <td style="padding:15px">### Overview
2070
-
2071
- Delete a Datadog-Azure integration.
2072
-
2073
- ### Arguments
2074
-
2075
- This endpoint takes no JSON argument.</td>
2076
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2077
- <td style="padding:15px">Yes</td>
2078
- </tr>
2079
- <tr>
2080
- <td style="padding:15px">listGCPAccounts(apiKey, applicationKey, callback)</td>
2081
- <td style="padding:15px">### Overview
2082
-
2083
- List all Datadog-GCP integrations configured for your Datadog Account.
2084
-
2085
- ### Arguments
2086
-
2087
- This endpoint takes no JSON argument.</td>
2088
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2089
- <td style="padding:15px">Yes</td>
2090
- </tr>
2091
- <tr>
2092
- <td style="padding:15px">createGCPAccount(body, apiKey, applicationKey, callback)</td>
2093
- <td style="padding:15px">### Overview
2094
-
2095
- Configure your Datadog-Google Cloud Platform integration directly through the Datadog API.
2096
- [Read more about Datadog-Google Cloud Platform integration][1].
2097
-
2098
- **Note**: Using the `POST` method updates your integration configuration by **adding** your new configuration to the existing one in your Datadog organization.
2099
-
2100
- ### Arguments
2101
-
2102
- All of the following fields' values are provided by the JSON service account key file created in the [GCP Console for service accounts][2]; Refer to t...(description truncated)</td>
2103
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2104
- <td style="padding:15px">Yes</td>
2105
- </tr>
2106
- <tr>
2107
- <td style="padding:15px">updateAGCPServiceAccountSAutomuteOption(body, apiKey, applicationKey, callback)</td>
2108
- <td style="padding:15px">### Overview
2109
-
2110
- Update your Datadog-Google Cloud Platform integration Automute options.
2111
- [Read more about Datadog-Google Cloud Platform integration][1].
2112
-
2113
- ### Arguments
2114
-
2115
- * **`project_id`** [*required*]: Your Google Cloud project ID found in your JSON service account key.
2116
-
2117
- * **`client_email`** [*required*]: Your email found in your JSON service account key.
2118
-
2119
- * **`automute`** [*optional*, *default*=**false**]: Silence monitors for expected GCE instance shutdowns.
2120
-
2121
- [1]: https://docs.datadoghq.com/integ...(description truncated)</td>
2122
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2123
- <td style="padding:15px">Yes</td>
2124
- </tr>
2125
- <tr>
2126
- <td style="padding:15px">deleteAGCPServiceAccount(apiKey, applicationKey, callback)</td>
2127
- <td style="padding:15px">### Overview
2128
-
2129
- Delete the Datadog-Google Cloud Platform integration. [Read more about Datadog-Google Cloud Platform integration][1].
2130
-
2131
- ### Arguments
2132
-
2133
- This endpoint takes no JSON argument.
2134
-
2135
- [1]: https://docs.datadoghq.com/integrations/google_cloud_platform</td>
2136
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2137
- <td style="padding:15px">Yes</td>
2138
- </tr>
2139
- <tr>
2140
- <td style="padding:15px">getPagerDutyConfiguration(apiKey, applicationKey, callback)</td>
2141
- <td style="padding:15px">### Overview
2142
-
2143
- List all Datadog-PagerDuty integrations configured for your Datadog Account.
2144
-
2145
- ### Arguments
2146
-
2147
- This endpoint takes no JSON argument.</td>
2148
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2149
- <td style="padding:15px">Yes</td>
2150
- </tr>
2151
- <tr>
2152
- <td style="padding:15px">addNewServicesAndSchedules(body, apiKey, applicationKey, callback)</td>
2153
- <td style="padding:15px">### Overview
2154
-
2155
- Add new services and schedules to your Datadog-PagerDuty integration. [Read more about Datadog-PagerDuty integration][1].
2156
-
2157
- ### Arguments
2158
-
2159
- * **`services`** : Array of PagerDuty service objects. [Learn how to configure you Datadog service with PagerDuty documentation][2]. A PagerDuty service object is composed by:
2160
- * **`service_name`** [*required*]: Your Service name in PagerDuty.
2161
- * **`service_key`** [*required*]: Your Service name associated service key in Pagerduty.
2162
- * **`schedu...(description truncated)</td>
2163
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2164
- <td style="padding:15px">Yes</td>
2165
- </tr>
2166
- <tr>
2167
- <td style="padding:15px">deletePagerDutyConfiguration(apiKey, applicationKey, callback)</td>
2168
- <td style="padding:15px">### Overview
2169
-
2170
- Delete a Datadog-PagerDuty integration configured in your Datadog Account. [Read more about Datadog-PagerDuty integration][1].
2171
-
2172
- ### Arguments
2173
-
2174
- This endpoint takes no JSON arguments
2175
-
2176
-
2177
- [1]: https://docs.datadoghq.com/integrations/pagerduty</td>
2178
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2179
- <td style="padding:15px">Yes</td>
2180
- </tr>
2181
- <tr>
2182
- <td style="padding:15px">getSlackConfigurationDetails(apiKey, applicationKey, callback)</td>
2183
- <td style="padding:15px">### Overview
2184
-
2185
- List all Datadog-Slack integrations configured for your Datadog Account.
2186
-
2187
- ### Arguments
2188
-
2189
- This endpoint takes no JSON argument.</td>
2190
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2191
- <td style="padding:15px">Yes</td>
2192
- </tr>
2193
- <tr>
2194
- <td style="padding:15px">addChannelsToExistingConfiguration(body, apiKey, applicationKey, callback)</td>
2195
- <td style="padding:15px">### Overview
2196
-
2197
- Add channels to your existing Datadog-Slack integration directly through Datadog API. [Read more about Datadog-Slack integration][1].
2198
-
2199
- ### Arguments
2200
-
2201
- * **`channels`** [*required*]: Array of slack channel objects to post to. A slack channel object is composed by:
2202
-
2203
- * **`channel_name`** [*required*]: Your channel name e.g: `#general`, `#private`
2204
-
2205
- * **`transfer_all_user_comments`** [*optional*, *default*=**False**]: To be notified for every comment on a graph, set it to `true`....(description truncated)</td>
2206
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2207
- <td style="padding:15px">Yes</td>
2208
- </tr>
2209
- <tr>
2210
- <td style="padding:15px">deleteSlackConfigurationDetails(apiKey, applicationKey, callback)</td>
2211
- <td style="padding:15px">### Overview
2212
-
2213
- Delete a Datadog-Slack integration configured in your Datadog Account. [Read more about Datadog-Slack integration][1].
2214
-
2215
- ### Arguments
2216
-
2217
- This endpoint takes no JSON arguments
2218
-
2219
-
2220
- [1]: https://docs.datadoghq.com/integrations/slack</td>
2221
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2222
- <td style="padding:15px">Yes</td>
2223
- </tr>
2224
- <tr>
2225
- <td style="padding:15px">getAllWebhookConfigurations(apiKey, applicationKey, callback)</td>
2226
- <td style="padding:15px"></td>
2227
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2228
- <td style="padding:15px">Yes</td>
2229
- </tr>
2230
- <tr>
2231
- <td style="padding:15px">addToCurrentConfiguration(body, apiKey, applicationKey, callback)</td>
2232
- <td style="padding:15px">ARGUMENTS</td>
2233
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2234
- <td style="padding:15px">Yes</td>
2235
- </tr>
2236
- <tr>
2237
- <td style="padding:15px">deleteWebhookConfigurations(apiKey, applicationKey, callback)</td>
2238
- <td style="padding:15px"></td>
2239
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2240
- <td style="padding:15px">Yes</td>
2241
- </tr>
2242
- <tr>
2243
- <td style="padding:15px">replaceCurrentConfiguration(body, apiKey, applicationKey, callback)</td>
2244
- <td style="padding:15px">ARGUMENTS</td>
2245
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2246
- <td style="padding:15px">Yes</td>
2247
- </tr>
2248
- <tr>
2249
- <td style="padding:15px">getAllAPIKey(apiKey, applicationKey, callback)</td>
2250
- <td style="padding:15px">### Overview
2251
-
2252
- Get all API keys available for your account.
2253
-
2254
- ### Arguments
2255
-
2256
- This endpoint takes no JSON arguments.</td>
2257
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2258
- <td style="padding:15px">Yes</td>
2259
- </tr>
2260
- <tr>
2261
- <td style="padding:15px">createANewAPIKey(body, apiKey, applicationKey, callback)</td>
2262
- <td style="padding:15px">### Overview
2263
-
2264
- Create an API key with a given name.
2265
-
2266
- ### Arguments
2267
-
2268
- * **`name`** [*required*]: Name of your API key.</td>
2269
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2270
- <td style="padding:15px">Yes</td>
2271
- </tr>
2272
- <tr>
2273
- <td style="padding:15px">getAGivenAPIKey(apiKey, applicationKey, callback)</td>
2274
- <td style="padding:15px">### Overview
2275
-
2276
- Get a given API key.
2277
-
2278
- ### Arguments
2279
-
2280
- This endpoint takes no JSON arguments.</td>
2281
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2282
- <td style="padding:15px">Yes</td>
2283
- </tr>
2284
- <tr>
2285
- <td style="padding:15px">editAGivenAPIKey(body, apiKey, applicationKey, callback)</td>
2286
- <td style="padding:15px">### Overview
2287
-
2288
- Edit an API key name.
2289
-
2290
- ### Arguments
2291
-
2292
- * **`name`** [*required*]: Name of your API key.</td>
2293
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2294
- <td style="padding:15px">Yes</td>
2295
- </tr>
2296
- <tr>
2297
- <td style="padding:15px">deleteAnAPIKey(apiKey, applicationKey, callback)</td>
2298
- <td style="padding:15px">### Overview
2299
-
2300
- Delete a given API key.
2301
-
2302
- ### Arguments
2303
-
2304
- This endpoint takes no JSON arguments.</td>
2305
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2306
- <td style="padding:15px">Yes</td>
2307
- </tr>
2308
- <tr>
2309
- <td style="padding:15px">getAllApplicationKey(apiKey, applicationKey, callback)</td>
2310
- <td style="padding:15px">### Overview
2311
-
2312
- Get all application keys available for your account.
2313
-
2314
- ### Arguments
2315
-
2316
- This endpoint takes no JSON arguments.</td>
2317
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2318
- <td style="padding:15px">Yes</td>
2319
- </tr>
2320
- <tr>
2321
- <td style="padding:15px">createANewApplicationKey(body, apiKey, applicationKey, callback)</td>
2322
- <td style="padding:15px">### Overview
2323
-
2324
- Create an application key with a given name.
2325
-
2326
- ### Arguments
2327
-
2328
- * **`name`** [*required*]: Name of your application key.</td>
2329
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2330
- <td style="padding:15px">Yes</td>
2331
- </tr>
2332
- <tr>
2333
- <td style="padding:15px">getAGivenApplicationKey(apiKey, applicationKey, callback)</td>
2334
- <td style="padding:15px">### Overview
2335
-
2336
- Get a given application key.
2337
-
2338
- ### Arguments
2339
-
2340
- This endpoint takes no JSON arguments.</td>
2341
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2342
- <td style="padding:15px">Yes</td>
2343
- </tr>
2344
- <tr>
2345
- <td style="padding:15px">editAGivenApplicationKey(body, apiKey, applicationKey, callback)</td>
2346
- <td style="padding:15px">### Overview
2347
-
2348
- Edit an application key name.
2349
-
2350
- ### Arguments
2351
-
2352
- * **`name`** [*required*]: Name of your application key.</td>
2353
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2354
- <td style="padding:15px">Yes</td>
2355
- </tr>
2356
- <tr>
2357
- <td style="padding:15px">deleteAnApplicationKey(apiKey, applicationKey, callback)</td>
2358
- <td style="padding:15px">### Overview
2359
-
2360
- Delete a given application key.
2361
-
2362
- ### Arguments
2363
-
2364
- This endpoint takes no JSON arguments.</td>
2365
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2366
- <td style="padding:15px">Yes</td>
2367
- </tr>
2368
- <tr>
2369
- <td style="padding:15px">sendLogsOverHTTP(body, ddsource, service, hostname, datadogApiKey, callback)</td>
2370
- <td style="padding:15px">### Overview
2371
-
2372
- Send your logs to your Datadog platform over HTTP. Limits per HTTP request are:
2373
-
2374
- * Maximum content size per payload: 2MB
2375
- * Maximum size for a single log: 256kB
2376
- * Maximum array size if sending multiple logs in an array: 50 entries
2377
-
2378
- **Note**: If you are in the Datadog EU site (`app.datadoghq.eu`), the HTTP log endpoint is: `http-intake.logs.datadoghq.eu`.
2379
-
2380
-
2381
- ### Arguments
2382
-
2383
- | Item | Description ...(description truncated)</td>
2384
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2385
- <td style="padding:15px">Yes</td>
2386
- </tr>
2387
- <tr>
2388
- <td style="padding:15px">getAListOfLogs(body, apiKey, applicationKey, callback)</td>
2389
- <td style="padding:15px">### Overview
2390
-
2391
- List endpoint returns logs that match a log search query. Results are paginated.
2392
-
2393
- ### Arguments
2394
-
2395
- * **`query`** [*required*]: The search query - following the [Log search syntax][1] .
2396
- * **`time.from`** [*required*]: Minimum timestamp for requested logs. Format can be either
2397
- - an ISO-8601 string
2398
- - a unix timestamp (number representing the elapsed millisec since epoch)
2399
- - a relative time (`now -10m`, `now - 1h`, `now - 1d`)
2400
- * **`time.to`** [*required*]: Maximum timestamp fo...(description truncated)</td>
2401
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2402
- <td style="padding:15px">Yes</td>
2403
- </tr>
2404
- <tr>
2405
- <td style="padding:15px">getAllActiveMetrics(apiKey, applicationKey, from, host, callback)</td>
2406
- <td style="padding:15px">### Overview
2407
-
2408
- Get the list of actively reporting metrics from a given time until now. This endpoint is not available in the Python and Ruby libraries.
2409
-
2410
- ### Arguments
2411
-
2412
- * **`from`** [*required*]: EPOCH timestamp from which to list metrics.
2413
- * **`host`** [*optional*]: Hostname for filtering the list of metrics returned. If set, metrics retrieved are those with the corresponding hostname tag.</td>
2414
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2415
- <td style="padding:15px">Yes</td>
2416
- </tr>
2417
- <tr>
2418
- <td style="padding:15px">sendTimeSeriesPoint(body, apiKey, applicationKey, callback)</td>
2419
- <td style="padding:15px">### Overview
2420
-
2421
- The metrics end-point allows you to post time-series data that can be graphed on Datadog's dashboards. The limit for compressed payloads is 3.2 megabytes (3200000), and 62 megabytes (62914560) for decompressed payloads.
2422
-
2423
- ### Arguments
2424
-
2425
- * **`series`** [*required*]: Pass a JSON array where each item in the array contains the following arguments:
2426
-
2427
- * **`metric`** [*required*]: The name of the timeseries
2428
- * **`type`** [*optional*, *default*=**gauge**]: [Type][1] of your metric ei...(description truncated)</td>
2429
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2430
- <td style="padding:15px">Yes</td>
2431
- </tr>
2432
- <tr>
2433
- <td style="padding:15px">queryTimeSeriesPoints(apiKey, applicationKey, from, to, query, callback)</td>
2434
- <td style="padding:15px">### Overview
2435
-
2436
- This endpoint allows you to query for metrics from any time period.
2437
-
2438
- ### Arguments
2439
-
2440
- * **`from`** [*required*]: EPOCH Timestamp from which to query metrics data.
2441
- * **`to`** [*required*]: EPOCH Timestamp until which to query metrics data.
2442
- * **`query`** [*required*]: The query string for the metric to retrieve. See [graphing documentation]() to learn how to build a metrics query.</td>
2443
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2444
- <td style="padding:15px">Yes</td>
2445
- </tr>
2446
- <tr>
2447
- <td style="padding:15px">viewMetricMetadata(apiKey, applicationKey, callback)</td>
2448
- <td style="padding:15px">### Overview
2449
-
2450
- The metrics metadata endpoint allows you to get metadata about a specific metric.
2451
-
2452
- ### Arguments
2453
-
2454
- This endpoint takes no JSON arguments.</td>
2455
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2456
- <td style="padding:15px">Yes</td>
2457
- </tr>
2458
- <tr>
2459
- <td style="padding:15px">editMetricMetadata(body, apiKey, applicationKey, callback)</td>
2460
- <td style="padding:15px">### Overview
2461
-
2462
- The metrics metadata endpoint allows you to edit fields of a metric's metadata. [Find more about supported types][1]
2463
-
2464
- ### Arguments
2465
-
2466
- * **`type`** [*required*]: [Metric type][1] such as **gauge** or **rate**
2467
- * **`description`** [*optional*, *default*=**None**]: String description of the metric" default
2468
- * **`short_name`** [*required*]: Short name string of the metric
2469
- * **`unit`** [*optional*, *default*=**None**]: Primary unit of the metric such as **byte** or **operation**. [See the ...(description truncated)</td>
2470
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2471
- <td style="padding:15px">Yes</td>
2472
- </tr>
2473
- <tr>
2474
- <td style="padding:15px">searchMetrics(q, apiKey, applicationKey, callback)</td>
2475
- <td style="padding:15px">### Overview
2476
-
2477
- This endpoint allows you to search for metrics from the last 24 hours in Datadog.
2478
-
2479
- ### Arguments
2480
-
2481
- * `q` [*required*]: The query string. Must be prefixed with `metrics:`.</td>
2482
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2483
- <td style="padding:15px">Yes</td>
2484
- </tr>
2485
- <tr>
2486
- <td style="padding:15px">createAMonitor(body, apiKey, applicationKey, callback)</td>
2487
- <td style="padding:15px">### Overview
2488
-
2489
- If you manage and deploy monitors programmatically, it's easier to define the monitor in the Datadog UI and [export its valid JSON][1].
2490
-
2491
- ### Arguments
2492
-
2493
- * **`type`** [*required*]: The [type of the monitor][2], chosen from:
2494
-
2495
- | Monitor Type | type attribute value |
2496
- | :-------- | :------- |
2497
- | anomaly | `query alert` |
2498
- | apm | `query alert` |
2499
- | composite | `composite` |
2500
- | custom | `service check` |
2501
- | event | `eve...(description truncated)</td>
2502
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2503
- <td style="padding:15px">Yes</td>
2504
- </tr>
2505
- <tr>
2506
- <td style="padding:15px">getAMonitorSDetails(apiKey, applicationKey, groupStates, callback)</td>
2507
- <td style="padding:15px">### Overview
2508
-
2509
- Get a monitor details based on its monitor ID.
2510
-
2511
- ### Arguments
2512
-
2513
- * **`group_states`** [*optional*, *default*=**None**]: If this argument is set, the returned data includes additional information (if available) regarding the specified group states, including the last notification timestamp, last resolution timestamp and details about the last time the monitor was triggered. The argument should include a string list indicating what, if any, group states to include. Choose one or more f...(description truncated)</td>
2514
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2515
- <td style="padding:15px">Yes</td>
2516
- </tr>
2517
- <tr>
2518
- <td style="padding:15px">editAMonitorSDetails(body, apiKey, applicationKey, callback)</td>
2519
- <td style="padding:15px">### Overview
2520
-
2521
- Edit a monitor details based on its monitor ID.
2522
-
2523
- ### Arguments
2524
-
2525
- * **`query`** [*required*]: The metric query to alert on.
2526
- * **`name`** [*required*]: The name of the monitor.
2527
- * **`message`** [*optional*, *default*=**dynamic, based on query**]: A message to include with notifications for this monitor. Email notifications can be sent to specific users by using the same '@username' notation as events.
2528
- * **`options`** [*optional*, *default*=**{}**]: Refer to the create monitor documenta...(description truncated)</td>
2529
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2530
- <td style="padding:15px">Yes</td>
2531
- </tr>
2532
- <tr>
2533
- <td style="padding:15px">deleteAMonitor(apiKey, applicationKey, callback)</td>
2534
- <td style="padding:15px">### Overview
2535
-
2536
- Delete a monitor based on its monitor ID.
2537
-
2538
- ### Arguments
2539
-
2540
- This endpoint takes no JSON arguments.</td>
2541
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2542
- <td style="padding:15px">Yes</td>
2543
- </tr>
2544
- <tr>
2545
- <td style="padding:15px">resolveMonitor(body, apiKey, applicationKey, callback)</td>
2546
- <td style="padding:15px">### Overview
2547
-
2548
- Resolve a monitor by monitorId & Group.
2549
-
2550
- ### Arguments
2551
-
2552
- * **`resolve`** [*required*]: Array of group(s) to resolve for a given monitor_id, e.g.: `{"monitor_id": "group_to_resolve"}`
2553
-
2554
- * It supports multiple groups per monitor, e.g.: `resolve: [{"monitor_id": "group_1"}, {"monitor_id": "group_2"}]`
2555
-
2556
- * It can also resolve all triggered groups with the pseudo-group `ALL_GROUPS`: `resolve: [{"monitor_id": "ALL_GROUPS"}]`</td>
2557
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2558
- <td style="padding:15px">Yes</td>
2559
- </tr>
2560
- <tr>
2561
- <td style="padding:15px">muteASpecificMonitor(body, apiKey, applicationKey, callback)</td>
2562
- <td style="padding:15px">### Overview
2563
-
2564
- Mute a specific monitor base on its ID.
2565
-
2566
- ### Arguments
2567
- * **`scope`** [*optional*, *default*=**None**]: The scope to apply the mute to, e.g. **role:db**. For example, if your alert is grouped by `{host}`, you might mute `host:app1`.
2568
- * **`end`** [*optional*, *default*=**None**]: A POSIX timestamp for when the mute should end.</td>
2569
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2570
- <td style="padding:15px">Yes</td>
2571
- </tr>
2572
- <tr>
2573
- <td style="padding:15px">unmuteASpecificMonitor(body, apiKey, applicationKey, callback)</td>
2574
- <td style="padding:15px">### Overview
2575
-
2576
- ### Arguments
2577
-
2578
- * **`scope`** [*optional*, *default*=**None**]: The scope to apply the mute to. For example, if your alert is grouped by {host}, you might mute 'host:app1'
2579
- * **`all_scopes`** [*optional*, *default* = **False**]: Clear muting across all scopes</td>
2580
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2581
- <td style="padding:15px">Yes</td>
2582
- </tr>
2583
- <tr>
2584
- <td style="padding:15px">muteAllMonitors(body, apiKey, applicationKey, callback)</td>
2585
- <td style="padding:15px">### Overview
2586
-
2587
- Muting prevents all monitors from notifying through email and posts to the [event stream][1]. State changes are only visible by checking the alert page.
2588
-
2589
- ### Arguments
2590
-
2591
- This endpoint takes no JSON arguments.
2592
-
2593
- [1]: https://docs.datadoghq.com/graphing/event_stream</td>
2594
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2595
- <td style="padding:15px">Yes</td>
2596
- </tr>
2597
- <tr>
2598
- <td style="padding:15px">unmuteAllMonitors(body, apiKey, applicationKey, callback)</td>
2599
- <td style="padding:15px">### Overview
2600
-
2601
- Disables muting all monitors. Throws an error if mute all was not enabled previously.
2602
-
2603
- ### Arguments
2604
-
2605
- This endpoint takes no JSON arguments.</td>
2606
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2607
- <td style="padding:15px">Yes</td>
2608
- </tr>
2609
- <tr>
2610
- <td style="padding:15px">validateAMonitorDefinitions(body, apiKey, applicationKey, callback)</td>
2611
- <td style="padding:15px">### Overview
2612
-
2613
- Validates a monitor definition.
2614
-
2615
- ### Arguments
2616
-
2617
- See [Create a monitor][1] documentation for details on constructing a monitor definition.
2618
-
2619
- [1]: https://docs.datadoghq.com/api/#create-a-monitor</td>
2620
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2621
- <td style="padding:15px">Yes</td>
2622
- </tr>
2623
- <tr>
2624
- <td style="padding:15px">monitorSearch(apiKey, applicationKey, query, page, perPage, sort, callback)</td>
2625
- <td style="padding:15px">### Overview
2626
-
2627
- Search and filter your monitors details.
2628
-
2629
- ### Arguments
2630
-
2631
- * **`query`** [*optional*]: After entering a search query in your [Manage Monitor page][1] use the query parameter value in the URL of the page as value for this parameter. Consult the dedicated [manage monitor documentation][2] page to learn more. The query can contain any number of space-separated monitor attributes, for instance `query="type:metric status:alert"`.
2632
-
2633
- * **`page`** [*optional*, *default* = **0**]: Page to star...(description truncated)</td>
2634
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2635
- <td style="padding:15px">Yes</td>
2636
- </tr>
2637
- <tr>
2638
- <td style="padding:15px">monitorGroupSearch(apiKey, applicationKey, query, page, perPage, sort, callback)</td>
2639
- <td style="padding:15px">### Overview
2640
-
2641
- Search and filter your monitor groups details.
2642
-
2643
- ### ARGUMENTS
2644
-
2645
- * **`query`** [*optional*]: After entering a search query in your [Manage Monitor page][1] use the query parameter value in the URL of the page as value for this parameter. Consult the dedicated [manage monitor documentation][2] page to learn more.
2646
-
2647
- * **`page`** [*optional*, *default* = **0**]: Page to start paginating from.
2648
-
2649
- * **`per_page`** [*optional*, *default*=**30**]: Number of monitors to return per page.
2650
-
2651
- * **`s...(description truncated)</td>
2652
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2653
- <td style="padding:15px">Yes</td>
2654
- </tr>
2655
- <tr>
2656
- <td style="padding:15px">createChildOrganization(body, apiKey, applicationKey, callback)</td>
2657
- <td style="padding:15px">### Overview
2658
-
2659
- This endpoint requires the [multi-org account][1] feature and must be enabled by [contacting support][2].
2660
-
2661
- ### Arguments
2662
-
2663
- * **`name`** [*required*]: The name of the new child-organization, limited to 32 characters.
2664
- * **`subscription`** [*required*]: A JSON array of subscription type. Types available are `trial`, `free`, and `pro`.
2665
- * **`billing`** [*required*]: A JSON array of billing type. Note that only `parent_billing` is supported.
2666
-
2667
- Once a new child-organization is created, you ...(description truncated)</td>
2668
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2669
- <td style="padding:15px">Yes</td>
2670
- </tr>
2671
- <tr>
2672
- <td style="padding:15px">getAllOrganizations(apiKey, applicationKey, callback)</td>
2673
- <td style="padding:15px">### Overview
2674
-
2675
- Get all child-organisation details for a given Master organisation.
2676
-
2677
- ### Arguments
2678
-
2679
- This endpoint takes no JSON argument.</td>
2680
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2681
- <td style="padding:15px">Yes</td>
2682
- </tr>
2683
- <tr>
2684
- <td style="padding:15px">getOrganization(apiKey, applicationKey, callback)</td>
2685
- <td style="padding:15px">### Overview
2686
- Get an organisation details based on its public ID.
2687
-
2688
- ### Arguments
2689
-
2690
- * **`public_id`** [*required*]: The public id of the organization.</td>
2691
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2692
- <td style="padding:15px">Yes</td>
2693
- </tr>
2694
- <tr>
2695
- <td style="padding:15px">updateOrganization(body, apiKey, applicationKey, callback)</td>
2696
- <td style="padding:15px">### Overview
2697
-
2698
- Update a Datadog organization information.
2699
-
2700
- ##### ARGUMENTS
2701
- * **`name`** [*optional*]: The organization name.
2702
- * **`settings`** [*optional*]: A JSON array of settings. Settings include:
2703
- * **`saml`** - Set the boolean property `enabled` to enable or disable single sign on with SAML. See the [SAML documentation][1] for more information about all SAML settings.
2704
- * **`saml_idp_initiated_login`** - has one property `enabled` (boolean).v
2705
- * **`saml_strict_mode`** - has one prope...(description truncated)</td>
2706
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2707
- <td style="padding:15px">Yes</td>
2708
- </tr>
2709
- <tr>
2710
- <td style="padding:15px">uploadIDPMetadata(body, apiKey, applicationKey, callback)</td>
2711
- <td style="padding:15px">### Overview
2712
-
2713
- There are a couple of options for updating the Identity Provider (IdP) metadata from your SAML IdP.
2714
-
2715
- * **Multipart Form-Data**: Post the IdP metadata file using a form post.
2716
- * **XML Body**: Post the IdP metadata file as the body of the request.
2717
-
2718
- ### Multipart Form-Data
2719
-
2720
- #### Headers
2721
-
2722
- * **`Content-Type: multipart/form-data`**
2723
-
2724
- #### Arguments
2725
-
2726
- * **`idp_file`** [*required*]: The path to the XML metadata file you wish to upload.
2727
-
2728
- ### XML Body
2729
-
2730
- #### Headers
2731
- * **`Content-Type: applicatio...(description truncated)</td>
2732
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2733
- <td style="padding:15px">Yes</td>
2734
- </tr>
2735
- <tr>
2736
- <td style="padding:15px">createATest(body, apiKey, applicationKey, callback)</td>
2737
- <td style="padding:15px">### Overview
2738
-
2739
- Create a Synthetics test to initiate and configure the tests you want Datadog to send to your API endpoints or to your browser app. You can configure the endpoints being tested, the number of tests, and where they are coming from. The parameters required are different for API and browser tests and they are marked accordingly—if a parameter is marked as _required_, it is required for both types of tests. Once you create a test, it shows up in the UI in your [Synthetics list][1]
2740
-
2741
- A b...(description truncated)</td>
2742
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2743
- <td style="padding:15px">Yes</td>
2744
- </tr>
2745
- <tr>
2746
- <td style="padding:15px">getAllTests(apiKey, applicationKey, callback)</td>
2747
- <td style="padding:15px">### Overview
2748
-
2749
- Get a list of all existing tests.
2750
-
2751
- ### Arguments
2752
-
2753
- *This endpoint takes no JSON arguments.*</td>
2754
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2755
- <td style="padding:15px">Yes</td>
2756
- </tr>
2757
- <tr>
2758
- <td style="padding:15px">startOrPauseATest(body, apiKey, applicationKey, callback)</td>
2759
- <td style="padding:15px">### Overview
2760
-
2761
- Start or pause an existing Synthetics test.
2762
-
2763
- ##### Arguments
2764
-
2765
- * **`new_status`** - _required_ - A key-value pair where you define whether you want to start or pause a test. Valid values are `live` and `paused`. Returns `true` if the status has been changed, and `false` if the status has stayed the same.</td>
2766
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2767
- <td style="padding:15px">Yes</td>
2768
- </tr>
2769
- <tr>
2770
- <td style="padding:15px">editATest(body, apiKey, applicationKey, callback)</td>
2771
- <td style="padding:15px">### Overview
2772
-
2773
- Use this method to update an existing Synthetics test. In order to update a test, you have to submit the same payload as creating a test.
2774
-
2775
- The parameters required are different for API and browser tests and they are marked accordingly—if a parameter is marked as _required_, it is required for both types of tests.
2776
-
2777
- A browser test is treated like a GET API test. This method gives you the ability to update the browser test, but you have to use the UI to [record your test][1].
2778
-
2779
- In orde...(description truncated)</td>
2780
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2781
- <td style="padding:15px">Yes</td>
2782
- </tr>
2783
- <tr>
2784
- <td style="padding:15px">deleteATest(body, apiKey, applicationKey, callback)</td>
2785
- <td style="padding:15px">### Overview
2786
-
2787
- Delete one or many tests.
2788
-
2789
- ### Arguments
2790
-
2791
- * **`public_ids`** - _required_ - A JSON list of the ID or IDs of the tests that you want to delete.</td>
2792
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2793
- <td style="padding:15px">Yes</td>
2794
- </tr>
2795
- <tr>
2796
- <td style="padding:15px">getAllTestResults(apiKey, applicationKey, callback)</td>
2797
- <td style="padding:15px">### Overview
2798
-
2799
- Get the most recent results for a specific test.
2800
-
2801
- ### Arguments
2802
-
2803
- *This endpoint takes no JSON arguments.*</td>
2804
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2805
- <td style="padding:15px">Yes</td>
2806
- </tr>
2807
- <tr>
2808
- <td style="padding:15px">getASpecificTestResult(apiKey, applicationKey, callback)</td>
2809
- <td style="padding:15px">### Overview
2810
-
2811
- Get a specific result for a specific test.
2812
-
2813
- ### Arguments
2814
-
2815
- *This endpoint takes no JSON arguments.*</td>
2816
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2817
- <td style="padding:15px">Yes</td>
2818
- </tr>
2819
- <tr>
2820
- <td style="padding:15px">getATest(apiKey, applicationKey, callback)</td>
2821
- <td style="padding:15px">### Overview
2822
-
2823
- Get information on a specific test.
2824
-
2825
- ### Arguments
2826
-
2827
- *This endpoint takes no JSON arguments.*</td>
2828
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2829
- <td style="padding:15px">Yes</td>
2830
- </tr>
2831
- <tr>
2832
- <td style="padding:15px">getDevicesForBrowserChecks(apiKey, applicationKey, callback)</td>
2833
- <td style="padding:15px">### Overview
2834
-
2835
- Get a list of devices for browser checks.
2836
-
2837
- ### Arguments
2838
-
2839
- *This endpoint takes no JSON arguments.*</td>
2840
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2841
- <td style="padding:15px">Yes</td>
2842
- </tr>
2843
- <tr>
2844
- <td style="padding:15px">getAvailableLocations(apiKey, applicationKey, callback)</td>
2845
- <td style="padding:15px">### Overview
2846
-
2847
- Get a list of available locations
2848
-
2849
- ### Arguments
2850
-
2851
- *This endpoint takes no JSON arguments.*</td>
2852
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2853
- <td style="padding:15px">Yes</td>
2854
- </tr>
2855
- <tr>
2856
- <td style="padding:15px">getTags(apiKey, applicationKey, callback)</td>
2857
- <td style="padding:15px">### Overview
2858
-
2859
- Return a mapping of tags to hosts for your whole infrastructure.
2860
-
2861
- ### Arguments
2862
-
2863
- *This endpoint takes no JSON arguments.*</td>
2864
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2865
- <td style="padding:15px">Yes</td>
2866
- </tr>
2867
- <tr>
2868
- <td style="padding:15px">getHostTags(apiKey, applicationKey, callback)</td>
2869
- <td style="padding:15px">### Overview
2870
-
2871
- Return the list of tags that apply to a given host.
2872
-
2873
- ### Arguments
2874
-
2875
- *This endpoint takes no JSON arguments.*</td>
2876
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2877
- <td style="padding:15px">Yes</td>
2878
- </tr>
2879
- <tr>
2880
- <td style="padding:15px">addTagsToAHost(body, apiKey, applicationKey, callback)</td>
2881
- <td style="padding:15px">### Overview
2882
-
2883
- This endpoint allows you to add new tags to a host, optionally specifying where these tags come from.
2884
-
2885
- ### Arguments
2886
-
2887
- * **`tags`** [*required*]: A list of tags to apply to the host
2888
- * **`source`** [*optional*, *default*=**users**]: The source of the tags (e.g. chef, puppet). [Complete list of source attribute values][1]
2889
-
2890
- [1]: https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value</td>
2891
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2892
- <td style="padding:15px">Yes</td>
2893
- </tr>
2894
- <tr>
2895
- <td style="padding:15px">updateHostTags(body, apiKey, applicationKey, callback)</td>
2896
- <td style="padding:15px">### Overview
2897
-
2898
- This endpoint allows you to update/replace all tags in an integration source with those supplied in the request.
2899
-
2900
- ### Arguments
2901
-
2902
- * **`tags`** [*required*]: A list of tags
2903
- * **`source`** [*optional*, *default*=**users**]: The source of the tags (e.g. chef, puppet). [Complete list of source attribute values][1]
2904
-
2905
- [1]: https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value</td>
2906
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2907
- <td style="padding:15px">Yes</td>
2908
- </tr>
2909
- <tr>
2910
- <td style="padding:15px">removeHostTags(apiKey, applicationKey, callback)</td>
2911
- <td style="padding:15px">### Overview
2912
-
2913
- Remove all tags in an integration source for a single host.
2914
-
2915
- ### Arguments
2916
-
2917
- *This endpoint takes no JSON arguments.*</td>
2918
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2919
- <td style="padding:15px">Yes</td>
2920
- </tr>
2921
- <tr>
2922
- <td style="padding:15px">sendTraces(body, callback)</td>
2923
- <td style="padding:15px">### Overview
2924
-
2925
- Datadog's APM allows you to collect performance metrics by tracing your code to determine which parts of your application are slow or inefficient.
2926
-
2927
- Tracing data is sent to the Datadog Agent via an HTTP API. We provide some [official libraries][1] that simplify sending metrics to the Datadog Agent, however you may want to interact directly with the API to instrument applications that cannot use the libraries or are written in languages that don't yet have an official Datadog Tracing...(description truncated)</td>
2928
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2929
- <td style="padding:15px">Yes</td>
2930
- </tr>
2931
- <tr>
2932
- <td style="padding:15px">sendServices(body, callback)</td>
2933
- <td style="padding:15px">https://docs.datadoghq.com/api/?lang=bash#send-traces</td>
2934
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2935
- <td style="padding:15px">Yes</td>
2936
- </tr>
2937
- <tr>
2938
- <td style="padding:15px">getHostsAndContainersHourlyUsage(apiKey, applicationKey, startHr, endHr, callback)</td>
2939
- <td style="padding:15px">### Overview
2940
-
2941
- Get Hourly Usage For Hosts and Containers.
2942
-
2943
- ### Arguments
2944
-
2945
- * **`start_hr`** [*required*]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage beginning at this hour
2946
- * **`end_hr`** [*optional*, *default*=**1d+start_hr**]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage ending BEFORE this hour
2947
-
2948
- #### Response
2949
-
2950
- * **`container_count`**: Shows the total number of containers reporting via the Docker integration during the hour.
2951
- * **`ho...(description truncated)</td>
2952
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2953
- <td style="padding:15px">Yes</td>
2954
- </tr>
2955
- <tr>
2956
- <td style="padding:15px">getLogsHourlyUsage(apiKey, applicationKey, startHr, endHr, callback)</td>
2957
- <td style="padding:15px">### Overview
2958
-
2959
- Get Hourly Usage For Logs.
2960
-
2961
- ### Arguments
2962
- * **`start_hr`** [*required*]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage beginning at this hour
2963
- * **`end_hr`** [*optional*, *default*=**1d+start_hr**]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage ending BEFORE this hour
2964
-
2965
- #### Response
2966
-
2967
- * **`ingested_events_bytes`**: Contains the number of log bytes ingested.
2968
- * **`indexed_events_count`**: Contains the number of log events in...(description truncated)</td>
2969
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2970
- <td style="padding:15px">Yes</td>
2971
- </tr>
2972
- <tr>
2973
- <td style="padding:15px">getCustomMetricsHourlyUsage(apiKey, applicationKey, startHr, endHr, callback)</td>
2974
- <td style="padding:15px">### Overview
2975
-
2976
- Get Hourly Usage For [Custom Metrics][1].
2977
-
2978
- ### Arguments
2979
-
2980
- * **`start_hr`** [*required*]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage beginning at this hour
2981
- * **`end_hr`** [*optional*, *default*=**1d+start_hr**]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage ending BEFORE this hour
2982
-
2983
- [1]: https://docs.datadoghq.com/developers/metrics/custom_metrics</td>
2984
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2985
- <td style="padding:15px">Yes</td>
2986
- </tr>
2987
- <tr>
2988
- <td style="padding:15px">getTop500CustomMetricsByHourlyAverage(apiKey, applicationKey, month, names, callback)</td>
2989
- <td style="padding:15px">### Overview
2990
-
2991
- Get Top [Custom Metrics][1] By Hourly Average.
2992
-
2993
- ### Arguments
2994
- * **`month`** [*required*]: Datetime in ISO-8601 format, UTC, precise to month: [YYYY-MM] for usage beginning at this hour.
2995
- * **`names`** [*optional*, *default*=**None**]: Comma-separated list of metric names.
2996
-
2997
- [1]: https://docs.datadoghq.com/developers/metrics/custom_metrics</td>
2998
- <td style="padding:15px">{base_path}/{version}?{query}</td>
2999
- <td style="padding:15px">Yes</td>
3000
- </tr>
3001
- <tr>
3002
- <td style="padding:15px">getMultiOrgUsageDetails(apiKey, applicationKey, startMonth, endMonth, includeOrgIds, callback)</td>
3003
- <td style="padding:15px">### Overview
3004
-
3005
- Get usage across your multi-org account
3006
-
3007
- ### Arguments
3008
-
3009
- * **`start_month`** [*required*]: Datetime in ISO-8601 format, UTC, precise to month: [YYYY-MM] for usage beginning in this month. Maximum of 15 months ago.
3010
- * **`end_month`** [*optional*, *default*=**current_month-3d**]: Datetime in ISO-8601 format, UTC, precise to month: [YYYY-MM] for usage ending this month.
3011
- * **`include_org_details`** [*optional*, *default*=**true**]: Include usage summaries for each sub-org.</td>
3012
- <td style="padding:15px">{base_path}/{version}?{query}</td>
3013
- <td style="padding:15px">Yes</td>
3014
- </tr>
3015
- <tr>
3016
- <td style="padding:15px">getTraceSearchHourlyUsage(apiKey, applicationKey, startHr, endHr, callback)</td>
3017
- <td style="padding:15px">### Overview
3018
-
3019
- Get hourly usage For Trace Search.
3020
-
3021
- ### Arguments
3022
- * **`start_hr`** [*required*]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage beginning at this hour
3023
- * **`end_hr`** [*optional*, *default*=**1d+start_hr**]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage ending BEFORE this hour
3024
-
3025
- #### Response
3026
-
3027
- * **`indexed_events_count`**: Contains the number of Trace Search events indexed.
3028
- * **`hour`**: The hour for the usage.</td>
3029
- <td style="padding:15px">{base_path}/{version}?{query}</td>
3030
- <td style="padding:15px">Yes</td>
3031
- </tr>
3032
- <tr>
3033
- <td style="padding:15px">getFargateHourlyUsage(apiKey, applicationKey, startHr, endHr, callback)</td>
3034
- <td style="padding:15px">### Overview
3035
-
3036
- Get Hourly Usage For [Fargate][1].
3037
-
3038
- ### Arguments
3039
-
3040
- * **`start_hr`** [*required*]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage beginning at this hour
3041
- * **`end_hr`** [*optional*, *default*=**1d+start_hr**]: Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage ending BEFORE this hour
3042
-
3043
- [1]: https://docs.datadoghq.com/integrations/ecs_fargate</td>
3044
- <td style="padding:15px">{base_path}/{version}?{query}</td>
3045
- <td style="padding:15px">Yes</td>
3046
- </tr>
3047
- </table>
3048
- <br>
3049
-
3050
- ### Authentication
3051
-
3052
- This document will go through the steps for authenticating the Datadog adapter with Basic Authentication. Properly configuring the properties for an adapter in IAP is critical for getting the adapter online. You can read more about adapter authentication <a href="https://www.itential.com/automation-platform/integrations/adapters-resources/authentication/" target="_blank">HERE</a>.
3053
-
3054
- #### Basic Authentication
3055
- The Datadog adapter requires Basic Authentication. If you change authentication methods, you should change this section accordingly and merge it back into the adapter repository.
3056
-
3057
- STEPS
3058
- 1. Ensure you have access to a Datadog server and that it is running
3059
- 2. Follow the steps in the README.md to import the adapter into IAP if you have not already done so
3060
- 3. Use the properties below for the ```properties.authentication``` field
3061
- ```json
3062
- "authentication": {
3063
- "auth_method": "basic user_password",
3064
- "username": "<username>",
3065
- "password": "<password>",
3066
- "token": "",
3067
- "token_timeout": 1800000,
3068
- "token_cache": "local",
3069
- "invalid_token_error": 401,
3070
- "auth_field": "header.headers.Authorization",
3071
- "auth_field_format": "Basic {b64}{username}:{password}{/b64}",
3072
- "auth_logging": false,
3073
- "client_id": "",
3074
- "client_secret": "",
3075
- "grant_type": ""
3076
- }
3077
- ```
3078
- 4. Restart the adapter. If your properties were set correctly, the adapter should go online.
3079
-
3080
- #### Troubleshooting
3081
- - Make sure you copied over the correct username and password.
3082
- - Turn on debug level logs for the adapter in IAP Admin Essentials.
3083
- - Turn on auth_logging for the adapter in IAP Admin Essentials (adapter properties).
3084
- - Investigate the logs - in particular:
3085
- - The FULL REQUEST log to make sure the proper headers are being sent with the request.
3086
- - The FULL BODY log to make sure the payload is accurate.
3087
- - The CALL RETURN log to see what the other system is telling us.
3088
- - Remember when you are done to turn auth_logging off as you do not want to log credentials.
3089
-
3090
- ## Additional Information
3091
-
3092
- ### Enhancements
3093
-
3094
- #### Adding a Second Instance of an Adapter
3095
-
3096
- You can add a second instance of this adapter without adding new code on the file system. To do this go into the IAP Admin Essentials and add a new service config for this adapter. The two instances of the adapter should have unique ids. In addition, they should point to different instances (unique host and port) of the other system.
3097
-
3098
- #### Adding Adapter Calls
3099
-
3100
- There are multiple ways to add calls to an existing adapter.
3101
-
3102
- The easiest way would be to use the Adapter Builder update process. This process takes in a Swagger or OpenAPI document, allows you to select the calls you want to add and then generates a zip file that can be used to update the adapter. Once you have the zip file simply put it in the adapter directory and execute `npm run adapter:update`.
3103
-
3104
- ```bash
3105
- mv updatePackage.zip adapter-datadog
3106
- cd adapter-datadog
3107
- npm run adapter:update
3108
- ```
3109
-
3110
- If you do not have a Swagger or OpenAPI document, you can use a Postman Collection and convert that to an OpenAPI document using APIMatic and then follow the first process.
3111
-
3112
- If you want to manually update the adapter that can also be done the key thing is to make sure you update all of the right files. Within the entities directory you will find 1 or more entities. You can create a new entity or add to an existing entity. Each entity has an action.json file, any new call will need to be put in the action.json file. It will also need to be added to the enum for the ph_request_type in the appropriate schema files. Once this configuration is complete you will need to add the call to the adapter.js file and, in order to make it available as a workflow task in IAP, it should also be added to the pronghorn.json file. You can optionally add it to the unit and integration test files. There is more information on how to work on each of these files in the <a href="https://docs.itential.com/opensource/docs/adapters" target="_blank">Adapter Technical Resources</a> on our Documentation Site.
3113
-
3114
- ```text
3115
- Files to update
3116
- * entities/<entity>/action.json: add an action
3117
- * entities/<entity>/schema.json (or the schema defined on the action): add action to the enum for ph_request_type
3118
- * adapter.js: add the new method and make sure it calls the proper entity and action
3119
- * pronghorn.json: add the new method
3120
- * test/unit/adapterTestUnit.js (optional but best practice): add unit test(s) - function is there, any required parameters error when not passed in
3121
- * test/integration/adapterTestIntegration.js (optional but best practice): add integration test
3122
- ```
3123
-
3124
- #### Adding Adapter Properties
3125
-
3126
- While changing adapter properties is done in the service instance configuration section of IAP, adding properties has to be done in the adapter. To add a property you should edit the propertiesSchema.json with the proper information for the property. In addition, you should modify the sampleProperties to have the new property in it.
3127
-
3128
- ```text
3129
- Files to update
3130
- * propertiesSchema.json: add the new property and how it is defined
3131
- * sampleProperties: add the new property with a default value
3132
- * test/unit/adapterTestUnit.js (optional but best practice): add the property to the global properties
3133
- * test/integration/adapterTestIntegration.js (optional but best practice): add the property to the global properties
3134
- ```
3135
-
3136
- #### Changing Adapter Authentication
3137
-
3138
- Often an adapter is built before knowing the authentication and authentication processes can also change over time. The adapter supports many different kinds of authentication but it does require configuration. Some forms of authentication can be defined entirely with the adapter properties but others require configuration.
3139
-
3140
- ```text
3141
- Files to update
3142
- * entities/.system/action.json: change the getToken action as needed
3143
- * entities/.system/schemaTokenReq.json: add input parameters (external name is name in other system)
3144
- * entities/.system/schemaTokenResp.json: add response parameters (external name is name in other system)
3145
- * propertiesSchema.json: add any new property and how it is defined
3146
- * sampleProperties: add any new property with a default value
3147
- * test/unit/adapterTestUnit.js (optional but best practice): add the property to the global properties
3148
- * test/integration/adapterTestIntegration.js (optional but best practice): add the property to the global properties
3149
- ```
3150
-
3151
- #### Enhancing Adapter Integration Tests
3152
-
3153
- The adapter integration tests are written to be able to test in either stub (standalone) mode or integrated to the other system. However, if integrating to the other system, you may need to provide better data than what the adapter provides by default as that data is likely to fail for create and update. To provide better data, edit the adapter integration test file. Make sure you do not remove the marker and keep custom code below the marker so you do not impact future migrations. Once the edits are complete, run the integration test as it instructs you to above. When you run integrated to the other system, you can also save mockdata for future use by changing the isSaveMockData flag to true.
3154
-
3155
- ```text
3156
- Files to update
3157
- * test/integration/adapterTestIntegration.js: add better data for the create and update calls so that they will not fail.
3158
- ```
3159
-
3160
- As mentioned previously, for most of these changes as well as other possible changes, there is more information on how to work on an adapter in the <a href="https://docs.itential.com/opensource/docs/adapters" target="_blank">Adapter Technical Resources</a> on our Documentation Site.
3161
-
3162
- ### Contributing
3163
-
3164
- First off, thanks for taking the time to contribute!
3165
-
3166
- The following is a set of rules for contributing.
3167
-
3168
- #### Code of Conduct
3169
-
3170
- This project and everyone participating in it is governed by the Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to support@itential.com.
3171
-
3172
- #### How to Contribute
3173
-
3174
- Follow the contributing guide (here)[https://gitlab.com/itentialopensource/adapters/contributing-guide]
3175
-
3176
- ### Helpful Links
3177
-
3178
- <a href="https://docs.itential.com/opensource/docs/adapters" target="_blank">Adapter Technical Resources</a>
3179
-
3180
- ### Node Scripts
3181
-
3182
- There are several node scripts that now accompany the adapter. These scripts are provided to make several activities easier. Many of these scripts can have issues with different versions of IAP as they have dependencies on IAP and Mongo. If you have issues with the scripts please report them to the Itential Adapter Team. Each of these scripts are described below.
3183
-
3184
- <table border="1" class="bordered-table">
3185
- <tr>
3186
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Run</span></th>
3187
- <th bgcolor="lightgrey" style="padding:15px"><span style="font-size:12.0pt">Description</span></th>
3188
- </tr>
3189
- <tr>
3190
- <td style="padding:15px">npm run adapter:install</td>
3191
- <td style="padding:15px">Provides an easier way to install the adapter.</td>
3192
- </tr>
3193
- <tr>
3194
- <td style="padding:15px">npm run adapter:checkMigrate</td>
3195
- <td style="padding:15px">Checks whether your adapter can and should be migrated to the latest foundation.</td>
3196
- </tr>
3197
- <tr>
3198
- <td style="padding:15px">npm run adapter:findPath</td>
3199
- <td style="padding:15px">Can be used to see if the adapter supports a particular API call.</td>
3200
- </tr>
3201
- <tr>
3202
- <td style="padding:15px">npm run adapter:migrate</td>
3203
- <td style="padding:15px">Provides an easier way to update your adapter after you download the migration zip from Itential DevSite.</td>
3204
- </tr>
3205
- <tr>
3206
- <td style="padding:15px">npm run adapter:update</td>
3207
- <td style="padding:15px">Provides an easier way to update your adapter after you download the update zip from Itential DevSite.</td>
3208
- </tr>
3209
- <tr>
3210
- <td style="padding:15px">npm run adapter:revert</td>
3211
- <td style="padding:15px">Allows you to revert after a migration or update if it resulted in issues.</td>
3212
- </tr>
3213
- <tr>
3214
- <td style="padding:15px">npm run troubleshoot</td>
3215
- <td style="padding:15px">Provides a way to troubleshoot the adapter - runs connectivity, healthcheck and basic get.</td>
3216
- </tr>
3217
- <tr>
3218
- <td style="padding:15px">npm run connectivity</td>
3219
- <td style="padding:15px">Provides a connectivity check to the Servicenow system.</td>
3220
- </tr>
3221
- <tr>
3222
- <td style="padding:15px">npm run healthcheck</td>
3223
- <td style="padding:15px">Checks whether the configured healthcheck call works to Servicenow.</td>
3224
- </tr>
3225
- <tr>
3226
- <td style="padding:15px">npm run basicget</td>
3227
- <td style="padding:15px">Checks whether the basic get calls works to Servicenow.</td>
3228
- </tr>
3229
- </table>
3230
- <br>
3231
-
3232
- ## Troubleshoot
3233
-
3234
- Run `npm run troubleshoot` to start the interactive troubleshooting process. The command allows you to verify and update connection, authentication as well as healthcheck configuration. After that it will test these properties by sending HTTP request to the endpoint. If the tests pass, it will persist these changes into IAP.
3235
-
3236
- You also have the option to run individual commands to perform specific test:
3237
-
3238
- - `npm run healthcheck` will perform a healthcheck request of with current setting.
3239
- - `npm run basicget` will perform some non-parameter GET request with current setting.
3240
- - `npm run connectivity` will perform networking diagnostics of the adatper endpoint.
3241
-
3242
- ### Connectivity Issues
3243
-
3244
- 1. You can run the adapter troubleshooting script which will check connectivity, run the healthcheck and run basic get calls.
3245
-
3246
- ```bash
3247
- npm run troubleshoot
3248
- ```
3249
-
3250
- 2. Verify the adapter properties are set up correctly.
3251
-
3252
- ```text
3253
- Go into the Itential Platform GUI and verify/update the properties
3254
- ```
3255
-
3256
- 3. Verify there is connectivity between the Itential Platform Server and Datadog Server.
3257
-
3258
- ```text
3259
- ping the ip address of Datadog server
3260
- try telnet to the ip address port of Datadog
3261
- execute a curl command to the other system
3262
- ```
3263
-
3264
- 4. Verify the credentials provided for Datadog.
3265
-
3266
- ```text
3267
- login to Datadog using the provided credentials
3268
- ```
3269
-
3270
- 5. Verify the API of the call utilized for Datadog Healthcheck.
3271
-
3272
- ```text
3273
- Go into the Itential Platform GUI and verify/update the properties
3274
- ```
3275
-
3276
- ### Functional Issues
3277
-
3278
- Adapter logs are located in `/var/log/pronghorn`. In older releases of the Itential Platform, there is a `pronghorn.log` file which contains logs for all of the Itential Platform. In newer versions, adapters can be configured to log into their own files.
3279
-
307
+ ## [Generic Adapter Information](https://gitlab.com/itentialopensource/adapters/telemetry-analytics/adapter-datadog/-/blob/master/README.md)
3280
308