List Source Runs
Lists the knowledge base’s source runs (syncs, crawl previews, and imports), including those started by a schedule or in Dify. Only runs of sources this key can read are listed.
To follow a run you started, keep its id and call Get Source Run.
For how to follow, retry, and cancel runs, see Follow Source Runs.
curl --request GET \
--url https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows \
--header 'Authorization: Bearer <token>'import requests
url = "https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"canceled_at": null,
"checkpoint": "preview-staged",
"completed_at": "2026-10-18T07:41:09Z",
"created_at": "2026-10-18T07:40:00Z",
"cursor": null,
"execution_attempts": 1,
"failure": {
"action": "configure_source",
"category": "not_found",
"code": "SOURCE_CRAWL_PAGE_NOT_FOUND",
"message": "The requested Agent Knowledge Base resource was not found.",
"parameters": null,
"retryPolicy": "never",
"stage": "preview-staged",
"traceId": "d4c3b2a1-6f5e-4d7c-8b9a-0f1e2d3c4b5a"
},
"id": "d4c3b2a1-6f5e-4d7c-8b9a-0f1e2d3c4b5a",
"kind": "crawl-import",
"knowledge_space_id": "0a9d3c2e-5b6f-4e1a-8c7d-2f3e4a5b6c7d",
"last_error_code": "SOURCE_CRAWL_PAGE_NOT_FOUND",
"max_execution_attempts": 5,
"progress_completed": 3,
"progress_failed": 0,
"progress_skipped": 0,
"progress_total": 3,
"source_id": "6f1c2b0e-3d0b-4a5e-9f4c-1c0e6a7b8d90",
"state": "failed",
"updated_at": "2026-10-18T07:41:09Z"
},
{
"canceled_at": null,
"checkpoint": "provider-read",
"completed_at": null,
"created_at": "2026-10-20T10:00:00Z",
"cursor": "ss1:eyJmaW5nZXJwcmludCI6ImNhOWE4YWUzMDljZTFiMzE5NzkyNTc3YzRmYjA4NGVhNzY1OGZiMzkzMjM1MGZlNzk2ZTdhNjEzM2Q4N2M4NzMiLCJraW5kIjoid2Vic2l0ZSIsIm9mZnNldCI6MTIsInBoYXNlIjoiaXRlbXMiLCJwcm9ncmVzc0NvbXBsZXRlZCI6MTIsInByb2dyZXNzVG90YWwiOjQ1fQ",
"execution_attempts": 1,
"failure": null,
"id": "e1f2a3b4-c5d6-4e7f-8a9b-0c1d2e3f4a5b",
"kind": "sync",
"knowledge_space_id": "0a9d3c2e-5b6f-4e1a-8c7d-2f3e4a5b6c7d",
"last_error_code": null,
"max_execution_attempts": 5,
"progress_completed": 12,
"progress_failed": 0,
"progress_skipped": 0,
"progress_total": 45,
"source_id": "6f1c2b0e-3d0b-4a5e-9f4c-1c0e6a7b8d90",
"state": "syncing",
"updated_at": "2026-10-20T10:02:40Z"
}
],
"next_cursor": null
}Authorizations
Every request authenticates with an API key: Authorization: Bearer {API_KEY}. App endpoints take an app API key; knowledge endpoints take a knowledge base API key (Get Started).
Keep keys server-side; never embed them in client code. Requests with a missing or invalid key fail with HTTP 401 (unauthorized).
Path Parameters
Knowledge base ID: the last segment of the Service API endpoint shown in the knowledge base's API Access dialog (…/knowledge-fs/spaces/<knowledge base ID>), and the segment after /datasets/new/ in the address bar.
Query Parameters
Source ID from List Sources, to list only that source's runs. Must be a UUID.
1 - 255Cursor from the previous page's next_cursor.
1 - 1000Runs per page.
1 <= x <= 100Was this page helpful?
curl --request GET \
--url https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows \
--header 'Authorization: Bearer <token>'import requests
url = "https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{api_base_url}/knowledge-fs/spaces/{knowledge_base_id}/source-workflows")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"canceled_at": null,
"checkpoint": "preview-staged",
"completed_at": "2026-10-18T07:41:09Z",
"created_at": "2026-10-18T07:40:00Z",
"cursor": null,
"execution_attempts": 1,
"failure": {
"action": "configure_source",
"category": "not_found",
"code": "SOURCE_CRAWL_PAGE_NOT_FOUND",
"message": "The requested Agent Knowledge Base resource was not found.",
"parameters": null,
"retryPolicy": "never",
"stage": "preview-staged",
"traceId": "d4c3b2a1-6f5e-4d7c-8b9a-0f1e2d3c4b5a"
},
"id": "d4c3b2a1-6f5e-4d7c-8b9a-0f1e2d3c4b5a",
"kind": "crawl-import",
"knowledge_space_id": "0a9d3c2e-5b6f-4e1a-8c7d-2f3e4a5b6c7d",
"last_error_code": "SOURCE_CRAWL_PAGE_NOT_FOUND",
"max_execution_attempts": 5,
"progress_completed": 3,
"progress_failed": 0,
"progress_skipped": 0,
"progress_total": 3,
"source_id": "6f1c2b0e-3d0b-4a5e-9f4c-1c0e6a7b8d90",
"state": "failed",
"updated_at": "2026-10-18T07:41:09Z"
},
{
"canceled_at": null,
"checkpoint": "provider-read",
"completed_at": null,
"created_at": "2026-10-20T10:00:00Z",
"cursor": "ss1:eyJmaW5nZXJwcmludCI6ImNhOWE4YWUzMDljZTFiMzE5NzkyNTc3YzRmYjA4NGVhNzY1OGZiMzkzMjM1MGZlNzk2ZTdhNjEzM2Q4N2M4NzMiLCJraW5kIjoid2Vic2l0ZSIsIm9mZnNldCI6MTIsInBoYXNlIjoiaXRlbXMiLCJwcm9ncmVzc0NvbXBsZXRlZCI6MTIsInByb2dyZXNzVG90YWwiOjQ1fQ",
"execution_attempts": 1,
"failure": null,
"id": "e1f2a3b4-c5d6-4e7f-8a9b-0c1d2e3f4a5b",
"kind": "sync",
"knowledge_space_id": "0a9d3c2e-5b6f-4e1a-8c7d-2f3e4a5b6c7d",
"last_error_code": null,
"max_execution_attempts": 5,
"progress_completed": 12,
"progress_failed": 0,
"progress_skipped": 0,
"progress_total": 45,
"source_id": "6f1c2b0e-3d0b-4a5e-9f4c-1c0e6a7b8d90",
"state": "syncing",
"updated_at": "2026-10-20T10:02:40Z"
}
],
"next_cursor": null
}