Make an agent calendar
Makes a separate calendar for an agent inside the person's own Google or Outlook account. It counts when checking whether the person is free, and bookings for the agent's mailbox land on it. A Google account connected before this existed is asked to sign in again to approve one more permission: the refusal carries the link.
Requires an API key with the calendar:use scope.
apiKeyAuthorizationBearer <token>A secret API key from the dashboard (Developers → API keys): vl_live_…, or vl_test_… for test mode. Each operation says which scope the key needs.
application/json- body
name*stringA name people will recognise, for example Sales agent.
1 <= length <= 100timeZone*stringWhere the agent works, as an IANA name such as America/Chicago.
1 <= length <= 64forMailbox?stringThe agent's email address, so meetings booked for that mailbox land on this calendar. One calendar per mailbox.
length <= 320connectionId?stringOnly needed when more than one calendar account is connected.
1 <= length <= 64The new calendar
application/json- response
calendar*summary*stringcurl -X POST https://api.vlayers.ai/v1/calendar/calendars \ -H "Authorization: Bearer $VOICELAYER_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "name": "Sales agent", "timeZone": "America/Chicago", "forMailbox": "[email protected]" }'{ "calendar": { "connectionId": "0192f5c0-1a2b-7c3d-8e4f-5a6b7c8d9e01", "account": "[email protected]", "app": "Google Calendar", "id": "[email protected]", "name": "Sales agent", "main": false, "agentCalendar": true, "mailbox": "[email protected]", "countsForAvailability": true }, "summary": "Made a calendar called \"Sales agent\" in Google Calendar for [email protected]. It counts when I check if you're free, and you can rename or edit it in Google Calendar like any other."}