Skip to main content
This guide will help you get started with the Promptwatch API, from authentication to making your first request.

Prerequisites

  • A Promptwatch account (Sign up here)
  • An active project
  • Basic familiarity with RESTful APIs

Step 1: Get Your API Key

API Key Types

Promptwatch offers two types of API keys: Project-Level Keys
  • Scoped to a specific project
  • Automatically associated with the project
  • Recommended for most use cases
Organization-Level Keys
  • Access to all projects in your organization
  • Require X-Project-Id header to specify which project to query
  • Useful for cross-project analytics

Creating an API Key

  1. Go to Settings -> API Keys
  2. Click “Create API Key”
  3. Choose your key type and project (for project-level keys)
  4. Copy and securely store your API key
Store your API key securely. Never commit it to version control or share it publicly.

Step 2: Authenticate Your Requests

All API requests require authentication via the X-API-Key header.

Using Project-Level Keys

Using Organization-Level Keys

Postman: Download our Postman Collection for pre-configured requests with all endpoints.

Step 3: Validate Your API Key

Test your API key by calling the validate endpoint:
Success Response:

Step 4: Make Your First API Request

Now that your API key is validated, try fetching your monitors:

One-step project setup

Use an organization-level key to create a project, enrich it from the website, and generate monitors with prompts in one call. This is synchronous and can take 1-2 minutes. Omit monitors to create one monitor with 10 mixed prompts.
At most 3 monitors and 50 prompts in total. For more control, use POST /projects and POST /monitors separately. If prompt generation or the monitor write fails after the project is created, the response is still 201 with monitors: [] and a warning. Use the returned project id with POST /monitors instead of calling setup again — the project already counts toward the org’s project limit.

Error Handling

The API uses standard HTTP status codes: Error Response Format:

Next Steps

API Reference

Explore all available endpoints

Rate Limits

Learn about rate limits

Need Help?