Skip to content

Modify Pipeline Rule



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

Overview

Modify a Pipeline

When the type category is profiling, the rule will only take effect if the field CentralPLServiceSwitch (returned by the /workspace/get interface) in the workspace configuration is set to true.

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, 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
isForce boolean Whether to replace when default exists for specific type
Allow empty: False
asDefault int Set as the default pipeline for this type, 1 to set as default
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']
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

Additional Parameter Notes

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? ×