Wondering what’s next for npm?Check out our public roadmap! »

    @datadog/datadog-api-client
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.0-beta.3 • Public • Published

    Node.js Datadog API Client

    License

    This repository contains a Node.js API client for the Datadog API. The code is generated using openapi-generator and apigentools.

    How to install

    The package is under @datadog/datadog-api-client and can be installed through NPM or Yarn:

    # NPM
    npm install @datadog/datadog-api-client
    
    # Yarn
    yarn add @datadog/datadog-api-client

    Getting Started

    Here's an example getting a monitor:

    import { v1 } from 'datadog-api-client';
    import * as fs from 'fs';
    
    const configuration = v1.createConfiguration();
    const apiInstance = new v1.MonitorsApi(configuration);
    
    let params:v1.MonitorsApiGetMonitorRequest = {
      // number | The ID of the monitor
      monitorId: 1,
      // string | When specified, shows additional information about the group states. Choose one or more from `all`, `alert`, `warn`, and `no data`. (optional)
      groupStates: "group_states_example",
    };
    
    apiInstance.getMonitor(params).then((data:any) => {
      console.log('API called successfully. Returned data: ' + data);
    }).catch((error:any) => console.error(error));

    Documentation

    Documentation for API endpoints can be found under the docs subdirectories, in v1 and v2.

    Contributing

    As most of the code in this repository is generated, we will only accept PRs for files that are not modified by our code-generation machinery (changes to the generated files would get overwritten). We happily accept contributions to files that are not autogenerated, such as tests and development tooling.

    Author

    support@datadoghq.com

    License

    Apache License, v2.0

    Install

    npm i @datadog/datadog-api-client

    DownloadsWeekly Downloads

    110

    Version

    1.0.0-beta.3

    License

    Apache-2.0

    Unpacked Size

    10.6 MB

    Total Files

    2987

    Last publish

    Collaborators

    • avatar