Prerequisites
You need:- A Funky API key
- Python 3.10 or newer, or Node.js 20 or newer
1. Install the SDK
- Python
- TypeScript
2. Set your API key
The SDK reads your API key from theFUNKY_API_KEY environment variable.
3. Create your first session
Createquickstart.py for Python or quickstart.ts for TypeScript. Add the
snippet from each step to the file, in order.
1
Create an agent
An agent defines the model, system prompt, and tool policy. You can reuse the
same agent across many sessions.
- Python
- TypeScript
2
Create an environment
An environment configures the sandbox where the agent runs. This example
limits outbound network access to GitHub.
- Python
- TypeScript
3
Start a session
A session connects the agent to the environment for one independent task or
conversation. Wait until its sandbox is ready before sending work.
- Python
- TypeScript
4
Send a message
run_turn() and runTurn() send the message, follow session events until
the turn completes, and return the agent’s response.- Python
- TypeScript