Metadata-Version: 2.4
Name: solari-sdk
Version: 0.1.0
Summary: Python client for the SOLARI API — creator and brand intelligence across Instagram and TikTok.
License-Expression: MIT
Project-URL: Homepage, https://solari.sh
Project-URL: Documentation, https://solari.sh/api
Keywords: solari,brandazine,instagram,tiktok,creator,influencer,brand,sdk,api-client
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Typing :: Typed
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Dynamic: license-file

# solari-sdk

Python client for the [SOLARI API](https://solari.sh/api) — creator and brand intelligence across Instagram and TikTok. Standard library only; Python 3.9+.

```
pip install solari-sdk
```

## Quickstart

```python
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.call("solari_insight_instagram_brand_overview", username="nike")
tools = solari.list_tools()
```

Get a token with `solari auth token` on a machine that is signed in to the [solari CLI](https://solari.sh/docs), or use a token you already hold from an MCP connector.

## API

- `Solari(token=None, base_url="https://solari.sh", timeout=150, user_agent=None, transport=None)`
- `list_tools()` — every tool the signed-in account can call, with its JSON input schema.
- `get_tool(name)` — one tool.
- `call(name, arguments=None, **kwargs)` — run a tool and get its JSON payload back.
- `tools.<family>.<platform>.<group>.<name>(**kwargs)` — the same call spelled as a path; segments join with `_` under the `solari_` prefix.
- `me()` — the identity behind the token.

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
```
