Documentation Index
Fetch the complete documentation index at: https://cal.com/docs/llms.txt
Use this file to discover all available pages before exploring further.
Why migrate to v2?
The v2 API includes numerous enhancements and new features that are not available in v1:- Performance improvements: Optimized for better performance and scalability
- User-friendly response objects: Improved response structure for better developer experience
- Enhanced security: Improved security measures to protect your data
- New features: Access to new Cal.com features only available in v2
- Better error handling: More descriptive error messages and status codes
Authentication changes
In v1, you authenticated using an API key passed as a query parameter:Authorization header:
Endpoint-by-endpoint migration guide
Bookings
Create a booking
v1 endpoint:responsesobject replaced withattendeeobjectendtime is no longer required (calculated from event type duration)locationstructure changed from{value, optionValue}to{type}- Must include
cal-api-version: 2024-08-13header - Response structure is more detailed with
statusanddatawrapper
Get all bookings
v1: Not available as a dedicated endpoint v2 endpoint:status: Filter by booking status (accepted, pending, cancelled, rejected)attendeeEmail: Filter by attendee emaileventTypeId: Filter by event typeafterStart,beforeEnd: Filter by date rangetake,skip: PaginationsortStart,sortEnd,sortCreated: Sorting options
Cancel a booking
v1 endpoint:- Changed from DELETE to POST method
- Uses booking
uidin path instead ofidquery parameter - Cancellation reason in request body instead of query parameter
Reschedule a booking
v1: Required creating a new booking withrescheduleUid
v2 endpoint:
- Dedicated reschedule endpoint in v2
- Simpler process - just provide new start time
- Automatically handles the relationship between old and new bookings
Event types
Get all event types
v1 endpoint:- v2 response includes more detailed information about each event type
- v2 includes pagination support
- v2 response wrapped in
{status, data}structure
Create an event type
v1 endpoint:lengthrenamed tolengthInMinutesfor clarity- Location types simplified (no
integrations:prefix) - More configuration options available in v2
Update an event type
v1 endpoint:- Same HTTP method and path structure
- Request/response body structure differences match create endpoint
- v2 provides more granular control over event type settings
- v2 treats the
teamIdandparentIdof an event type as immutable. Update requests that attempt to change either field are rejected. Delete and recreate the event type to move it to another team or change its managed parent.
Schedules
Get all schedules
v1 endpoint:- v2 includes default schedule indicator
- v2 response includes more detailed availability information
- v2 supports filtering and pagination
Create a schedule
v1 endpoint:availabilityrenamed toschedulein v2isDefaultflag added to set default schedule- More flexible schedule configuration options
Webhooks
Get all webhooks
v1 endpoint:Create a webhook
v1 endpoint:eventTriggersrenamed totriggers- Added
payloadTemplatefor custom webhook payloads - More webhook event types available in v2
Slots
Get available slots
v1 endpoint:- v2 requires full ISO 8601 timestamps
- v2 response includes more metadata about slot availability
- v2 supports additional filtering options (username, teamSlug, etc.)
Teams
Get all teams
v1 endpoint:- v2 includes organization context if team is part of an org
- v2 response includes more team metadata
- v2 supports pagination
Users
Get user profile
v1 endpoint:- v2 uses
/meendpoint for current user - v2 returns more detailed profile information
- v2 includes organization and team memberships
Response structure changes
v1 response format
v2 response format
status: Either “success” or “error”data: The actual response dataerror: Error details (only present when status is “error”)
Error handling
v1 errors
v2 errors
Migration checklist
- Update authentication to use
Authorizationheader instead of query parameter - Add
cal-api-version: 2024-08-13header to all requests - Update base URL from
/v1/to/v2/ - Update request body structures (especially
responses→attendeefor bookings) - Update response parsing to handle
{status, data}wrapper - Update location object structures
- Update field names (
length→lengthInMinutes,eventTriggers→triggers, etc.) - Implement pagination handling for list endpoints
- Update error handling to parse new error structure
- Test all endpoints in your integration
- Update any stored booking/event type IDs if needed