What You Can Do
Create and manage AI agents that can write code, fix bugs, and handle development tasks across your repositories with full programmatic control over their execution and monitoring. Access your organization data including users, repositories, integrations, and programmatically retrieve detailed agent traces for analysis and debugging.All agents created through the API are fully configurable and viewable in the
Codegen web UI at codegen.com, allowing seamless integration between
programmatic and manual workflows.
Not seeing a capability you want? Get in touch! Join our community
Slack or email us at support@codegen.com.
Authentication
All API endpoints require authentication using Bearer tokens and your organization ID.Authentication Guide
Get your API token and organization ID to start using the Codegen API.
Rate Limits
The API includes rate limiting to ensure fair usage:- Standard endpoints: 60 requests per 30 seconds
- Agent creation: 10 requests per minute
- Setup commands: 5 requests per minute
- Log analysis: 5 requests per minute
Getting Started
1. Create Your First Agent Run
2. Check Agent Status
3. Resume with Follow-up
Use Cases
Automated Workflows- Trigger agents from CI/CD pipelines when builds fail
- Create agents in response to issue tracking system events
- Automate code reviews and quality checks
- Build Codegen into your existing development tools
- Create custom dashboards for agent activity
- Integrate with internal systems and workflows
- Process multiple repositories with consistent changes
- Generate setup commands for new projects
- Analyze logs across multiple sandbox environments
Explore the API
Browse API Endpoints
Explore all available endpoints with detailed schemas and examples.
Programmatically Retrieve Agent Traces
Learn how to retrieve and analyze detailed agent execution logs.
SDKs and Tools
For easier integration, we recommend using our Python SDK which provides a simple wrapper around the API:Python SDK
Use the Codegen Python SDK for a pythonic interface to create and manage
agents programmatically.
- CLI Tool - Command-line interface for common API operations
The API is RESTful and returns JSON responses. All endpoints support standard
HTTP status codes and include detailed error messages for troubleshooting.