Recommended: Use the Cal.com CLI
For agents that can execute commands on a machine, use the official Cal.com CLI instead of calling the API directly. The CLI handles authentication, versioning, and common workflows automatically.- npm
- curl
--help flags on all commands to learn about available options:
Only fall back to the API approach below if your agent cannot install or execute the CLI on its machine.
Overview
Cal.com API v2 enables AI agents to:- Check availability - Query available time slots for any user or team
- Create bookings - Schedule meetings on behalf of users
- Manage event types - Create and configure different meeting types
- Handle rescheduling and cancellations - Modify existing bookings
- Manage schedules - Set and update user availability
- Track credit usage - Check balances and charge credits for agent interactions
Authentication
AI agents should authenticate using an API key. Generate one in Settings → Developer → API Keys.Common workflows
1. Check availability
Query available slots using username and event slug—no need to look up IDs first:2. Create a booking
Schedule a meeting using username and event slug. This is the most common pattern for AI agents that extract scheduling intent from natural language (e.g., “book 15min with bailey”):The booking creation endpoint is public and does not require authentication. This allows agents to book on behalf of external users.
3. Handle custom booking questions
Most Cal.com users have required questions on their booking pages (e.g., “What is this meeting about?”). If you omit required fields, the API returns a 400 error. Include responses inbookingFieldsResponses:
4. Instant bookings for urgent requests
For teams handling urgent requests, use theinstant flag to bypass normal scheduling and immediately ring available team members:
Instant bookings require the event type to be configured for instant meetings. This is ideal for AI agents routing urgent customer requests.
5. Get user’s event types
Retrieve available event types to offer booking options:6. Reschedule a booking
Move an existing booking to a new time:7. Cancel a booking
Credit management
If your AI agent runs on the Cal.com platform, you can track usage by checking and charging credits through the API. This is useful for metering agent interactions against your account’s credit balance.Check available credits
Before performing a billable action, verify that the user or team has sufficient credits:balance object breaks down your remaining credits:
monthlyRemaining— credits included in your current billing cycleadditional— purchased credits outside the monthly allowance