Skip to main content
GET
List Source Pages

Authorizations

Authorization
string
header
required

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
string<uuid>
required

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.

source_id
string<uuid>
required

Source ID. From List Sources.

Query Parameters

cursor
string

The next_cursor from the previous response. Treat it as an opaque string. In tree view, send it with the same view, parentId, and limit.

Required string length: 1 - 4096
limit
integer
default:50

Pages per response.

Required range: 1 <= x <= 200
view
enum<string>

Send tree to list one level of the page tree: the top level, or the pages under parentId. Leave it out for the flat list.

Among the official data source plugins, only GitHub supports tree view, from plugin version 0.4.12.

On GitHub, use tree view to reach a repository's files. Both views cover at most the 20 most recently updated repositories. Under them, the two views reach different pages:

  • Tree view: under each repository, its Contents, Issues (when the repository has issues turned on), and Pull requests. Contents and its folders hold folders and importable text files.
  • Flat list: each repository, its README if it has one, and up to five issues and five pull requests.
Available options:
tree
parentId
string

The page_id of the page to expand, from an earlier tree-view response in which its has_children is true. Requires view=tree.

Spell it in camelCase as shown, even though the matching response field is parent_id.

Required string length: 1 - 4096

Response

Pages grouped by workspace.

next_cursor
string | null

Cursor for the next page, or null on the last page. Send it back as cursor.

workspaces
object[]

Provider workspaces the credentials can see.