pipelines
Update Pipeline
Update pipeline steps. This is the auto-save path.
PUT
/
api
/
v1
/
pipelines
/
{pipeline_id}
Update Pipeline
import requests
url = "https://www.datalab.to/api/v1/pipelines/{pipeline_id}"
payload = { "steps": [
{
"settings": {},
"custom_processor_id": "<string>",
"eval_rubric_id": 123,
"pending_check_url": "<string>",
"pending_name": "<string>"
}
] }
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)curl --request PUT \
--url https://www.datalab.to/api/v1/pipelines/{pipeline_id} \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"steps": [
{
"settings": {},
"custom_processor_id": "<string>",
"eval_rubric_id": 123,
"pending_check_url": "<string>",
"pending_name": "<string>"
}
]
}
'const options = {
method: 'PUT',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
steps: [
{
settings: {},
custom_processor_id: '<string>',
eval_rubric_id: 123,
pending_check_url: '<string>',
pending_name: '<string>'
}
]
})
};
fetch('https://www.datalab.to/api/v1/pipelines/{pipeline_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://www.datalab.to/api/v1/pipelines/{pipeline_id}"
payload := strings.NewReader("{\n \"steps\": [\n {\n \"settings\": {},\n \"custom_processor_id\": \"<string>\",\n \"eval_rubric_id\": 123,\n \"pending_check_url\": \"<string>\",\n \"pending_name\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"id": 123,
"pipeline_id": "<string>",
"name": "<string>",
"steps": [
"<unknown>"
],
"is_saved": true,
"archived": true,
"active_version": 123,
"created": "2023-11-07T05:31:56Z",
"updated": "2023-11-07T05:31:56Z",
"reused": false
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Path Parameters
Body
application/json
Ordered list of pipeline steps
Minimum array length:
1Show child attributes
Show child attributes
Response
Successful Response
Was this page helpful?
⌘I
Update Pipeline
import requests
url = "https://www.datalab.to/api/v1/pipelines/{pipeline_id}"
payload = { "steps": [
{
"settings": {},
"custom_processor_id": "<string>",
"eval_rubric_id": 123,
"pending_check_url": "<string>",
"pending_name": "<string>"
}
] }
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)curl --request PUT \
--url https://www.datalab.to/api/v1/pipelines/{pipeline_id} \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"steps": [
{
"settings": {},
"custom_processor_id": "<string>",
"eval_rubric_id": 123,
"pending_check_url": "<string>",
"pending_name": "<string>"
}
]
}
'const options = {
method: 'PUT',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
steps: [
{
settings: {},
custom_processor_id: '<string>',
eval_rubric_id: 123,
pending_check_url: '<string>',
pending_name: '<string>'
}
]
})
};
fetch('https://www.datalab.to/api/v1/pipelines/{pipeline_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://www.datalab.to/api/v1/pipelines/{pipeline_id}"
payload := strings.NewReader("{\n \"steps\": [\n {\n \"settings\": {},\n \"custom_processor_id\": \"<string>\",\n \"eval_rubric_id\": 123,\n \"pending_check_url\": \"<string>\",\n \"pending_name\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"id": 123,
"pipeline_id": "<string>",
"name": "<string>",
"steps": [
"<unknown>"
],
"is_saved": true,
"archived": true,
"active_version": 123,
"created": "2023-11-07T05:31:56Z",
"updated": "2023-11-07T05:31:56Z",
"reused": false
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}