solari-sdk
Python client for the SOLARI API — creator and brand intelligence across Instagram and TikTok. Standard library only; Python 3.9+; ships py.typed.
pip install solari-sdk
Quickstart
from solari_sdk import Solari
solari = Solari() # reads SOLARI_TOKEN; or Solari(token="...")
hits = solari.tools.catalog.instagram.account.search(query="nike", limit=3)
brand = solari.tools.insight.instagram.brand.overview(username="nike")
tools = solari.list_tools()
Create an API key on your SOLARI My page (long-lived, solari_sk_…, shown once), or mint a short-lived token with solari auth token on a machine signed in to the solari CLI.
Typed tools
solari.tools is generated from the SOLARI tool registry: every tool is a real method with keyword-only, typed parameters (Literal[...] for enums), so pyright and mypy catch a missing required argument, a misspelled keyword, or a wrong enum value before anything runs, and your editor completes the paths.
solari.tools.catalog.instagram.account.search(query="nike", query_type="bio")
solari.tools.catalog.instagram.account.search(limit=3) # type checker: missing "query"
solari.tools.catalog.instagram.account.search(query="nike", query_type="fuzzy") # type checker: not a Literal value
Tool responses are JSON (Any) whose shape is documented per tool at solari.sh/docs.
solari.call(name, arguments=None, **kwargs) runs any tool by name, including the per-account solari_apps_* tools that are not in the generated catalog; solari.dynamic.<any>.<path>(**kwargs) spells such a call as a path without type checking.
API
Solari(token=None, base_url="https://solari.sh", timeout=150, user_agent=None, transport=None)tools.<family>.<platform>.<group>.<name>(**kwargs)— typed tool calls; segments mirror thesolari_tool names.call(name, arguments=None, **kwargs)— run a tool by name and get its JSON payload back.list_tools()— every tool the signed-in account can call, with its JSON input schema.get_tool(name)— one tool.me()— the identity behind the token.dynamic— untyped path proxy for tools that are not in the generated catalog.SOLARI_TOOL_NAMES,SolariTools— the generated catalog.
Errors raise SolariError with status, code, message, tool, retry_after_seconds, and a retryable property (429, 502, 503, 504).
Development
python3 -m unittest discover -s tests -v
uvx pyright
uvx mypy --strict solari_sdk tests/typed_usage.py
solari_sdk/_tools.py is produced from the MCP worker's tool registry by pnpm run sdk:generate in cf-workers/solari-mcp; CI fails when it is stale.
Metadata
Release files for solari-sdk 0.2.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| solari_sdk-0.2.3.tar.gz | 21.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| solari_sdk-0.2.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 41.3 kB
Release files / solari_sdk-0.2.3.tar.gz
| Download URL | solari_sdk-0.2.3.tar.gz |
|---|---|
| Size | 21.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e7ae1f23378ea9e12021c0e2a4f44f266a8e3130c5cc736f0097f43a90882c10
|
|
BLAKE2b-256 checksum How to use checksums |
b2f809d611affe1b2d99f495abf470530ff3da985e6f0b38bfafebcbf5015fb0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 23, 2026.
Transparency logRelease files / solari_sdk-0.2.3-py3-none-any.whl
| Download URL | solari_sdk-0.2.3-py3-none-any.whl |
|---|---|
| Size | 19.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c56cafda4928377dc20cafe829a59fdcfd8a68be11f6f388542788131e525e9f
|
|
BLAKE2b-256 checksum How to use checksums |
32756d11e0a27896bd7068555ae51b4a06a3305916791dabc60eaf9c9bb14387
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 23, 2026.
Transparency log