Sanka CLI
Thin command-line wrapper for Sanka's public CRM and AI API.
The CLI keeps business logic on the server. It handles:
- Developer API token auth and refresh
- local profile and config management
- request construction for CRM, workflow, and AI endpoints
- table or JSON output
- polling for long-running workflow runs
Install
From PyPI:
uv tool install sanka-cli
Bootstrap script from a pinned release tag:
curl -fsSLO https://raw.githubusercontent.com/sankaHQ/sanka-cli/v0.1.3/scripts/install.sh
sh install.sh
From a pinned GitHub release tag:
uv tool install "git+https://github.com/sankaHQ/sanka-cli.git@v0.1.3"
Homebrew support is published through
sankaHQ/homebrew-cli. Install with:
brew tap sankaHQ/cli
brew install sankaHQ/cli/sanka
If you previously installed sanka from the old sankaHQ/tap tap
(sankaHQ/homebrew-tap), remove that formula and untap it first:
brew uninstall sanka
brew untap sankaHQ/tap
brew tap sankaHQ/cli
brew install sankaHQ/cli/sanka
Authenticate
Create a Developer API Token in Sanka, then save it locally. Login verifies the token against the API and prints the workspace and user it belongs to; a rejected token is not saved. If the API is unreachable, the token is saved with a warning so offline setup still works.
sanka auth login --access-token "<ACCESS_TOKEN>"
Migration commands
sanka also fronts the Sanka migration engine: scan, plan, validate,
apply, test, verify, status, migrate, connect, research, and assess
are delegated to the sanka-migrate package. PyPI installs of sanka-cli
0.1.7+ bundle the engine, so the commands just work — no API token needed for
local migration runs:
uv tool install sanka-cli
sanka scan .
The Homebrew formula stays lean and does not bundle the engine; add it with
uv tool install sanka-migrate and sanka delegates to it on PATH.
Check the active profile:
sanka auth status
Command Areas
CRM records:
sanka companies list
sanka contacts get <contact-id>
sanka deals create --data @deal.json
sanka tickets delete <ticket-id>
Workflow automation:
sanka workflows list
sanka workflows run <workflow-ref>
sanka workflows run <workflow-ref> --wait
Custom Code — write a workflow action in JavaScript or Python, keep it in your own repository, and push versions to Sanka:
sanka code init --slug enrich-company --runtime node
sanka code create
sanka code push --activate -m "add tier logic"
Your repository is the source of truth. Versions are immutable and content-addressed, so pushing unchanged code returns the version that already exists — safe to run on every CI merge. Rolling back is a pointer move, not a redeploy:
sanka code versions enrich-company
sanka code rollback enrich-company # or: deploy --version 4
pull writes a deployed version back to disk and diff reports whether your working
directory matches what is live. diff exits non-zero when they differ, which makes it
usable as a CI drift check:
sanka code pull enrich-company --dir ./functions/enrich
sanka code diff --dir ./functions/enrich
Secrets are per-function and never readable back — list shows only a masked suffix:
sanka code secrets set enrich-company CLEARBIT_API_KEY # prompts, no echo
sanka code secrets list enrich-company
Files are excluded from a push by .sankaignore; .git, node_modules,
__pycache__, .venv, build output, and .env are excluded by default.
AI helpers:
sanka ai score company <record-id>
sanka ai score deal <record-id> --score-model-id <score-model-id>
sanka ai enrich company <record-id> --force-refresh
sanka ai enrich company --seed-name "Acme" --seed-url "https://acme.example" --dry-run
Output Modes
The CLI defaults to table output on a TTY and JSON otherwise. Override this per command when needed:
sanka --output json companies list
Environment Overrides
SANKA_PROFILESANKA_BASE_URLSANKA_ACCESS_TOKEN
These override stored profile values without persisting them.
Docs
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sanka_cli-0.1.8.tar.gz.
File metadata
- Download URL: sanka_cli-0.1.8.tar.gz
- Upload date:
- Size: 81.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
183ce42c67e40d55b799ff24c839d59cd957ce937060402cc13d745e12d76c75
|
|
| MD5 |
6404d8765631af2633a3966f32ad830c
|
|
| BLAKE2b-256 |
33a57978a5940cbc25bce6bed82e1538dc16be8b9ff63f8ba373783bd491c4c7
|
Provenance
The following attestation bundles were made for sanka_cli-0.1.8.tar.gz:
Publisher:
release.yml on sankaHQ/sanka-cli
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sanka_cli-0.1.8.tar.gz -
Subject digest:
183ce42c67e40d55b799ff24c839d59cd957ce937060402cc13d745e12d76c75 - Sigstore transparency entry: 2621964874
- Sigstore integration time:
-
Permalink:
sankaHQ/sanka-cli@26c32f17737fd1cafee80d50f25dcb83eb1889b1 -
Branch / Tag:
refs/tags/v0.1.8 - Owner: https://github.com/sankaHQ
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@26c32f17737fd1cafee80d50f25dcb83eb1889b1 -
Trigger Event:
push
-
Statement type:
File details
Details for the file sanka_cli-0.1.8-py3-none-any.whl.
File metadata
- Download URL: sanka_cli-0.1.8-py3-none-any.whl
- Upload date:
- Size: 26.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b45e40f2e8291875384f6bb3423d381c72b3f7943d3780ad079f4ff91d318892
|
|
| MD5 |
460b707a271f876c7ad840bb525da79c
|
|
| BLAKE2b-256 |
287dbaae40d0583e34636f4da56d78f6ecc8a3c33ee45d3a34a751154e653022
|
Provenance
The following attestation bundles were made for sanka_cli-0.1.8-py3-none-any.whl:
Publisher:
release.yml on sankaHQ/sanka-cli
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sanka_cli-0.1.8-py3-none-any.whl -
Subject digest:
b45e40f2e8291875384f6bb3423d381c72b3f7943d3780ad079f4ff91d318892 - Sigstore transparency entry: 2621964878
- Sigstore integration time:
-
Permalink:
sankaHQ/sanka-cli@26c32f17737fd1cafee80d50f25dcb83eb1889b1 -
Branch / Tag:
refs/tags/v0.1.8 - Owner: https://github.com/sankaHQ
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@26c32f17737fd1cafee80d50f25dcb83eb1889b1 -
Trigger Event:
push
-
Statement type: