Reference

Authentication

API key authentication and permissions.

Authentication

RawTree API requests use bearer authentication.

Authorization: Bearer rw_...

Use rtree login for interactive CLI workflows. Use API keys for agents, scripts, services, and CI.

Create an API key

rtree key create --name my-agent --permission read_write

Permissions

PermissionInsertQueryLogsDelete tableManage API keys
adminYesYesYesYesYes
read_writeYesYesYesNoNo
write_onlyYesNoNoNoNo
read_onlyNoYesYesNoNo

Recommendations

  • Use read_write for agents that ingest and query.
  • Use read_only for dashboards, audits, and validation jobs.
  • Use write_only for event producers.
  • Use admin only for key management and destructive operations.

Environment variables

export RAWTREE_TOKEN=rw_...
export RAWTREE_PROJECT=analytics
export RAWTREE_ORG=team_alpha

The CLI reads RAWTREE_TOKEN before saved local credentials.