Skip to content

Latest commit

 

History

History
50 lines (38 loc) · 1.75 KB

File metadata and controls

50 lines (38 loc) · 1.75 KB

@datadog/datadog-api-client-logs-pipelines

Description

Pipelines and processors operate on incoming logs, parsing and transforming them into structured attributes for easier querying.

Notes:

Grok parsing rules may effect JSON output and require returned data to be configured before using in a request. For example, if you are using the data returned from a request for another request body, and have a parsing rule that uses a regex pattern like \s for spaces, you will need to configure all escaped spaces as %{space} to use in the body data.

Installation

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

Getting Started

import { createConfiguration } from "@datadog/datadog-api-client";
import { LogsPipelinesApiV1 } from "@datadog/datadog-api-client-logs-pipelines";
import { v1 } from "@datadog/datadog-api-client-logs-pipelines";

const configuration = createConfiguration();
const apiInstance = new LogsPipelinesApiV1(configuration);

apiInstance.getLogsPipelineOrder().then((data: v1.LogsPipelinesOrder) => {
    console.log("API called successfully. Returned data: " + JSON.stringify(data));
}).catch((error) => {
    console.error("Error calling API: " + error);
});