Skip to main content
Get your first prompt from Claro in just a few steps. This guide will have you making API calls in less than 5 minutes.

Prerequisites

Before you begin, you’ll need:
  • A Claro account - Sign up here
  • Python 3.8 or higher installed
  • At least one prompt created in your Claro workspace

Step 1: Get Your API Key

1

Navigate to API Keys

Log into Claro and click API Keys from the sidebar
2

Create API Key

Click Create API Key, give it a name (e.g., “Development”), and copy the key
Save your API key immediately - you won’t be able to see it again after closing the dialog.
3

Set Environment Variable

Add your API key to your environment:
Add this to your ~/.bashrc, ~/.zshrc, or .env file to persist across sessions

Step 2: Install the SDK

Install the Claro Python SDK using pip:

Step 3: Make Your First API Call

Create a new Python file called test_claro.py:
Run it:
Replace @workspace/my-prompt:v1 with the package name of a prompt from your Claro workspace.Find your prompt’s package name in the Claro dashboard under the prompt’s settings.

Step 4: Use With an LLM

Now let’s use the prompt with an actual LLM. Here’s an example with OpenAI:
When your team updates the prompt in Claro, your next API call automatically gets the new version. No code changes needed.

Next Steps

Now that you’re up and running, explore more features:

Python SDK Guide

Learn about all SDK features and configuration options

Working with Prompts

Discover prompt versioning, variables, and context

Code Examples

Browse production-ready examples

Error Handling

Learn how to handle errors gracefully

Common Issues

Make sure you’ve installed the SDK:
If you’re using a virtual environment, ensure it’s activated.
Double-check that:
  1. Your API key is set correctly in the environment variable
  2. You haven’t accidentally included extra spaces or quotes
  3. The API key hasn’t been deleted from your Claro account
Verify that:
  1. The package name is correct (including @workspace/ prefix)
  2. The version exists (e.g., :v1, :v2)
  3. You have access to the workspace containing the prompt

Need Help?