ara-python-sdk.
Python SDK links: GitHub repository · ara-sdk on PyPI
1) Install
2) Create app.py
App(...) accepts the project name either positionally (App("my-app")) or as a keyword (App(project_name="my-app")).
NoteThe standaloneSecret.from_dict(...)andSecret.from_dotenv(...)no longer acceptname=orrequired_keys=parameters. UseSecret.from_name(...)when you need an explicit named secret reference.
ara CLI discovers app = App(...) automatically. You do not need to add any if __name__ == "__main__" runner in your app script.
3) Configure environment
ARA_API_KEY manually.
Optional overrides:
ARA_API_BASE_URL(defaults to production API base)ARA_RUNTIME_KEY(runtime bearer key forrun/events/run-async/run-status/logs)ARA_APP_HEADER_KEY(runtime header key forX-Ara-App-Keyauth mode)
ara auth login stores control-plane credentials in ~/.ara/credentials.json and auto-refreshes JWTs when needed.
ara auth login uses polling-based PKCE OAuth (Google) and does not require a localhost callback listener.
If your Ara account is Google OAuth-only, store an existing control-plane key instead:
ara auth login --api-key <ARA_API_KEY>.
To be explicit, you can pass:
ara auth login --auth-flow poll.
To rotate your API key (invalidates the current one):
ARA_API_KEY as an env var, update it with the new key from the output. If you logged in via ara auth login, credentials are updated automatically.
4) Run commands
deploy returns a runtime_key in command output. Export it as ARA_RUNTIME_KEY (or pass --runtime-key) for runtime commands.
setup-auth returns an app_header_key you can pass as --app-header-key (or export ARA_APP_HEADER_KEY) for app-header-key auth.
No local runtime/auth key files are required.
If you declare local secret sources, deploy also syncs them through /apps/{app_id}/secrets.
Use ara setup app.py to inspect setup.runtime.inherit_owner_tools and verify connector inheritance.
Runtime logs
ara logs is a realtime stream and does not backfill historical events.
Start logs first, then trigger run/run-async in another terminal.
FastAPI endpoint setup metadata
When you declare@fastapi_endpoint(...), ara setup app.py includes endpoint metadata under:
setup.webhook.fastapi_endpoints[].endpoint_urlsetup.webhook.fastapi_endpoints[].slug_endpoint_urlsetup.webhook.fastapi_endpoints[].auth.mode(none,header,bearer,hmac)
runtime_input forwards HTTP body data as input so agent prompts can read request payloads without key collisions.
Decorator-based schedules
You can also attach schedules directly to declarations:at includes ISO one-shot timestamps, the SDK represents them as cron + one-shot metadata.
If a timestamp slot is already in the past at deploy time, the first execution can occur on the next yearly recurrence.
Command summary
deploy/up update existing apps by default. Use --on-existing error only when you want deploy to fail if the app already exists.
For exact behavior and edge cases, see /sdk/reference.
Run maintained examples
The full maintained examples live inara-python-sdk/examples/:
00-get-started.py01-a/b/c-agent-skills-loading.py02-canonical-email-chat-cron.py03-async-ngrok-webhook.py04-calcom-booking.py05-a/b-framework-adapters-*.py06-programmatic-secrets-redeploy-test.py07-app-schedule-decorator.py07b-app-schedule-decorator.py07c-runtime-automation-manager.py
01-cuses a local custom@skill_handlerdecorator inside the example; it is not an SDK primitive.02frontend requiresVITE_ARA_APP_IDandVITE_ARA_RUNTIME_KEYpopulated fromara setup-auth 02-canonical-email-chat-cron.py.03requires a local webhook receiver plus ngrok.06demonstrates programmatic secret updates before redeploy.07demonstrates static/declarative scheduling with@app.schedule(...).07bdemonstrates runtime-managed scheduling viaautomation_create(fire-and-forget).07cdemonstrates the minimal runtime automation lifecycle (create -> list -> delete -> list).
5) Debug your app
UseAraRuntimeClient to interact with your session programmatically — send messages, run tools, and inspect state without the UI.
/sdk/runtime-client for the full guide.