KAi/flow
API + CLI

Built to be automated

Integrate Flow into your systems with the REST API and automate up-to-date local copies with the CLI.

01

Machine tokens

Create a token from the Flow admin console: read-only or read-write, scoped to one space or all of them, optionally locked to an IP allowlist. The secret is shown once; the console tracks its last use and lets you revoke it instantly.

02

Keep a local copy up to date with flow-cli pull

The CLI keeps a local folder up to date with the content of a Flow space: it transfers only the changes, replays renames, moves and deletions too, and you can schedule it.

flow-cli pull
# ~/.config/flow-cli/cliente.toml
server = "https://flow.kaigrid.ai"
token  = "fsp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
dest   = "/var/www/site/documenti"

flow-cli pull --config ~/.config/flow-cli/cliente.toml
mirror completed
03

Use the REST API

Use the documented APIs to list spaces, follow changes, download files and search documents. Access depends on permissions and on the token's scope.

curl
curl -H "Authorization: Bearer fsp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \
  https://flow.kaigrid.ai/api/nodes?space_id=...
200application/json

Read the API documentation

The full reference is in the Flow admin console once your plan is active.