Getting started
Quickstart.
From install to insight in three steps.
Install the SDK, add your API key, and read your agents and this week’s numbers.
Before you start
- Python 3.10 or later.
- An Ollive workspace with your agents in it. If you can sign in to platform.ollive.ai, you’re ready.
Step by step
- Install the SDK
Terminal
pip install olliveOr add
olliveto your project’s requirements. - Add your API key
In Ollive, go to Admin → API keys and create a key. Save it as an environment variable on your server, and the SDK picks it up from there.
Terminal
export OLLIVE_API_KEY="ollive_sk_…" - Make your first call
List your agents, then count this week’s runs and findings, with the week before beside them:
first_call.py
from datetime import datetime, timedelta, timezonefrom ollive import Measure, MetricSpec, Ollive client = Ollive() # reads OLLIVE_API_KEY for agent in client.agents.list(): print(agent.name, agent.status) now = datetime.now(timezone.utc)week = client.metrics.query( metrics=[ MetricSpec(name="runs", measure=Measure.RUNS), MetricSpec(name="findings", measure=Measure.FINDINGS), ], start=now - timedelta(days=7), end=now, include_previous=True,) runs = week.total["runs"].checked_run_countfindings = week.total["findings"].finding_countbefore = week.previous["findings"].finding_countprint(f"{runs:,} runs checked this week")print(f"{findings} findings, {before} the week before")Output
Support assistant activeOnboarding assistant active1,284 runs checked this week6 findings, 9 the week before
Or hand it to your coding agent
Install the SDK and add your key, then paste this into your coding agent:
Prompt
Using the ollive Python SDK and the OLLIVE_API_KEY in our environment, list our agents and print this week’s runs and findings next to last week’s.
Where to go next
Customer-facing
A compliance view your customers can see
Show each of your customers how their agents measure up against the rules they’re bound by, inside your product and in your design.
See how Leadership reportingA weekly risk report that writes itself
What changed this week, where the risk sits and what to look at first, in your leadership’s inbox before they ask.
See how