For AI agents: A markdown version of this page is available at https://dnd37xeb23o8n.cloudfront.net/jen.gilbert/astro-base/ko/api/latest/logs-pipelines/update-a-pipeline.md. A documentation index is available at /llms.txt.
Language
Datadog site

파이프라인 업데이트하기

PUThttps://api.datadoghq.com/api/v1/logs/config/pipelines/{pipeline_id}https://api.us3.datadoghq.com/api/v1/logs/config/pipelines/{pipeline_id}https://api.us5.datadoghq.com/api/v1/logs/config/pipelines/{pipeline_id}https://api.datadoghq.eu/api/v1/logs/config/pipelines/{pipeline_id}https://api.ap1.datadoghq.com/api/v1/logs/config/pipelines/{pipeline_id}https://api.ap2.datadoghq.com/api/v1/logs/config/pipelines/{pipeline_id}https://api.uk1.datadoghq.com/api/v1/logs/config/pipelines/{pipeline_id}https://api.ddog-gov.com/api/v1/logs/config/pipelines/{pipeline_id}https://api.us2.ddog-gov.com/api/v1/logs/config/pipelines/{pipeline_id}

개요

지정된 파이프라인 구성을 업데이트하여 프로세서나 해당 순서를 변경합니다.

참고: 이 메서드를 사용하면 현재 구성을 Datadog 조직에 전송된 새 구성으로 대체하여 파이프라인 구성을 업데이트합니다.

This endpoint requires the logs_write_pipelines permission.

인수

경로 파라미터

이름
유형
설명
pipeline_id [required]
string

ID of the pipeline to delete.

요청

Body Data (required)

파이프라인의 새로운 정의입니다.

항목
유형
설명
description
string

파이프라인과 프로세서는 수신 로그에서 작동하며, 더 쉽게 쿼리할 수 있도록 로그를 구문 분석하고 구조화된 속성으로 변환합니다.

참고: 이 엔드포인트는 관리자 사용자만 사용할 수 있습니다. 관리자가 생성한 애플리케이션 키를 사용해야 합니다.

filter
object

Filter for logs.

is_enabled
boolean

Whether or not the pipeline is enabled.

name [required]
string

Name of the pipeline.

processors
[<oneOf>]

Ordered list of processors in this pipeline.

tags
[string]

A list of tags associated with the pipeline.

응답

OK

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

Note: These endpoints are only available for admin users. Make sure to use an application key created by an admin.

항목
유형
설명
description
string

A description of the pipeline.

filter
object

Filter for logs.

id
string

ID of the pipeline.

is_enabled
boolean

Whether or not the pipeline is enabled.

is_read_only
boolean

Whether or not the pipeline can be edited.

name [required]
string

Name of the pipeline.

processors
[<oneOf>]

Ordered list of processors in this pipeline.

tags
[string]

A list of tags associated with the pipeline.

type
string

Type of pipeline.

코드 예시

파이프라인 업데이트하기
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="us3.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="us5.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="datadoghq.eu"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="ap1.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="ap2.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="uk1.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="ddog-gov.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF
# Path parameters
export pipeline_id="CHANGE_ME"

# Set your Datadog site and credentials
export DD_SITE="us2.ddog-gov.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X PUT "https://api.${DD_SITE}/api/v1/logs/config/pipelines/${pipeline_id}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "filter": {
    "query": "source:python"
  },
  "is_enabled": true,
  "name": "My Pipeline",
  "processors": []
}
EOF