Skip to content

Modify Pipeline Rule



POST /api/v1/pipeline/{pl_uuid}/modify

Overview

Modify a Pipeline

When the category type is profiling, the field CentralPLServiceSwitch in space configuration (returned by the /workspace/get interface) must be true for this rule to take effect.

Route Parameters

Parameter Name Type Required Description
pl_uuid string Y ID of the Pipeline

Body Request Parameters

Parameter Name Type Required Description
name string Y Pipeline file name, which is also its source type value
Allow empty: False
Maximum length: 256
$notSearchRegExp: [^a-zA-Z0-9_\u4e00-\u9fa5-]+
type string Y Pipeline file type
Allow empty: False
Optional values: ['local', 'central']
source array Selected source list
Allow empty: False
content string Y Pipeline file content (base64 encoded)
Allow empty: False
testData string Test data (base64 encoded)
Allow empty: False
Allow empty string: True
dataType string Data type line_protocol-line protocol format; json-JSON format; message-Message
Example: line_protocol
Allow empty: False
Allow empty string: True
Optional values: ['line_protocol', 'json', 'message']
isForce boolean Whether to replace when specific types have defaults
Allow empty: False
asDefault int Whether to set this as the default pipeline for the type, 1 means set as default
Allow empty: False
enableByLogBackup int Enable Pipeline processing for forwarding data, 1 means enabled, 0 means not enabled
Allow empty: False
category string Y Category
Allow empty: False
Allow empty string: False
Optional values: ['logging', 'object', 'custom_object', 'network', 'tracing', 'rum', 'security', 'keyevent', 'metric', 'profiling', 'dialtesting', 'billing', 'keyevent']
extend json Category
Allow empty: False
extend.appID array appID
Allow empty: True
extend.measurement array Source origin
Allow empty: True
extend.loggingIndex string Log index
Allow empty: True

Supplementary Parameter Explanation

Request Example

curl 'https://openapi.guance.com/api/v1/pipeline/pl_xxxx32/modify' \
-H 'DF-API-KEY: <DF-API-KEY>' \
-H 'Content-Type: application/json;charset=UTF-8' \
--data-raw '{"name":"test_modify","category":"logging","asDefault":0,"content":"YWRkX2tleShjaXR5LCAic2hhbmdoYWkiKQ==","testData":"W10=","source":["nsqlookupd"]}' \
--compressed

Response

{
    "code": 200,
    "content": {
        "asDefault": 0,
        "category": "logging",
        "content": "YWRkX2tleShjaXR5LCAic2hhbmdoYWkiKQ==\n",
        "createAt": 1678026470,
        "creator": "xxx",
        "deleteAt": -1,
        "extend": {},
        "id": 86,
        "isSysTemplate": 0,
        "name": "test_modify",
        "source": [],
        "status": 0,
        "testData": "W10=\n",
        "updateAt": 1678026808.95266,
        "updator": "xx",
        "uuid": "pl_xxxx32",
        "workspaceUUID": "wksp_xxxx32"
    },
    "errorCode": "",
    "message": "",
    "success": true,
    "traceId": "TRACE-1EA80DD4-EB2C-4A9B-A146-D00606CC50E0"
} 

Feedback

Is this page helpful? ×