Using API v1? See what changes in v2, or the v1 docs
Availability
Check free/busy information, find meeting times and find rooms.
The examples use IDs from a sample sandbox. Your sandbox has the same people, calendars and events with its own IDs, which GET /v2/sandbox returns. When you're signed in to the dashboard, Try it fills in your IDs and sends the request to your sandbox, never to live data.
Get free/busy for one account
Returns the same response as POST /v2/free-busy, for one account. The v1 parameter names still work, and responses to requests that use them include a Pyas-Deprecated-Fields header.
Query parameters
- Name
accountId- Type
- string
- Required
- required
- Description
The
accountIdof the connected account.
- Name
calendarRefs- Type
- string
- Description
The calendars to read, comma-separated. Defaults to
primary.
- Name
from- Type
- string
- Description
The start of the time window, as an ISO 8601 time with a zone.
- Name
to- Type
- string
- Description
The end of the time window, at most 92 days after
from.
- Name
calendarIds- Type
- string
- Description
The v1 name for
calendarRefs.
- Name
timeMin- Type
- string
- Description
The v1 name for
from.
- Name
timeMax- Type
- string
- Description
The v1 name for
to.
Errors
VALIDATION_INVALID_QUERY(400): A query parameter is not valid.AUTH_INVALID_KEY(401): The API key is missing, unknown or revoked.AUTH_EXPIRED_KEY(401): The API key has expired.AUTH_INSUFFICIENT_SCOPE(403): The API key or session does not have permission to make this request.CONNECTION_NOT_FOUND(404): No connected account was found for this request.RATE_LIMIT_EXCEEDED(429): The request rate exceeds this plan's rate limit.RATE_LIMIT_BURST(429): Too many requests were sent in a short period.INTERNAL_ERROR(500): Something went wrong on our end.
Request
curl 'https://api.pyas.io/v2/free-busy?accountId=sbx_fda58c5980_1&from=2026-11-14T00%3A00%3A00Z&to=2026-11-21T00%3A00%3A00Z' \ -H "x-api-key: $PYAS_API_KEY"Response
{ "success": true, "data": { "busy": [ { "startsAt": "2026-11-14T15:00:00Z", "endsAt": "2026-11-14T16:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T14:30:00Z", "endsAt": "2026-11-15T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T16:00:00Z", "endsAt": "2026-11-15T17:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T19:00:00Z", "endsAt": "2026-11-15T19:30:00Z", "status": "busy" }, { "startsAt": "2026-11-15T20:00:00Z", "endsAt": "2026-11-15T21:00:00Z", "status": "busy" }, { "startsAt": "2026-11-16T14:30:00Z", "endsAt": "2026-11-16T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T21:00:00Z", "endsAt": "2026-11-16T21:30:00Z", "status": "busy" }, { "startsAt": "2026-11-17T14:30:00Z", "endsAt": "2026-11-17T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-17T18:00:00Z", "endsAt": "2026-11-17T20:00:00Z", "status": "busy" }, { "startsAt": "2026-11-18T14:30:00Z", "endsAt": "2026-11-18T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T13:00:00Z", "endsAt": "2026-11-19T14:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T14:30:00Z", "endsAt": "2026-11-19T14:45:00Z", "status": "busy" } ], "accounts": [ { "accountId": "sbx_fda58c5980_1", "provider": "pyas", "busy": [ { "startsAt": "2026-11-14T15:00:00Z", "endsAt": "2026-11-14T16:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T14:30:00Z", "endsAt": "2026-11-15T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T16:00:00Z", "endsAt": "2026-11-15T17:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T19:00:00Z", "endsAt": "2026-11-15T19:30:00Z", "status": "busy" }, { "startsAt": "2026-11-15T20:00:00Z", "endsAt": "2026-11-15T21:00:00Z", "status": "busy" }, { "startsAt": "2026-11-16T14:30:00Z", "endsAt": "2026-11-16T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T21:00:00Z", "endsAt": "2026-11-16T21:30:00Z", "status": "busy" }, { "startsAt": "2026-11-17T14:30:00Z", "endsAt": "2026-11-17T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-17T18:00:00Z", "endsAt": "2026-11-17T20:00:00Z", "status": "busy" }, { "startsAt": "2026-11-18T14:30:00Z", "endsAt": "2026-11-18T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T13:00:00Z", "endsAt": "2026-11-19T14:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T14:30:00Z", "endsAt": "2026-11-19T14:45:00Z", "status": "busy" } ], "calendars": { "primary": [ { "startsAt": "2026-11-14T15:00:00Z", "endsAt": "2026-11-14T16:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T14:30:00Z", "endsAt": "2026-11-15T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T16:00:00Z", "endsAt": "2026-11-15T17:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T19:00:00Z", "endsAt": "2026-11-15T19:30:00Z", "status": "busy" }, { "startsAt": "2026-11-15T20:00:00Z", "endsAt": "2026-11-15T21:00:00Z", "status": "busy" }, { "startsAt": "2026-11-16T14:30:00Z", "endsAt": "2026-11-16T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T21:00:00Z", "endsAt": "2026-11-16T21:30:00Z", "status": "busy" }, { "startsAt": "2026-11-17T14:30:00Z", "endsAt": "2026-11-17T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-17T18:00:00Z", "endsAt": "2026-11-17T20:00:00Z", "status": "busy" }, { "startsAt": "2026-11-18T14:30:00Z", "endsAt": "2026-11-18T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T13:00:00Z", "endsAt": "2026-11-19T14:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T14:30:00Z", "endsAt": "2026-11-19T14:45:00Z", "status": "busy" } ] } } ] }, "provider": null, "traceId": "trc_5f2a9c1e7b3d4a6f8e0c2b1d", "meta": { "from": "2026-11-14T00:00:00Z", "to": "2026-11-21T00:00:00Z", "partial": false }}Get free/busy for several accounts
Returns when each account is busy on the requested calendars, merged per account and across all accounts, so you can find when anyone is busy in one request. If one account fails, the error is reported on that account and meta.partial is true.
Headers
- Name
Idempotency-Key- Type
- string
- Description
A unique key that makes the request safe to retry. A retry with the same key returns the original response and does not make the change twice. Keys are kept for 24 hours.
Body
- Name
accountIds- Type
- array of string
- Description
Up to 20 account IDs. Each account is read on the calendars in
calendarRefs. Send exactly one ofaccountIds,subjectIdoraccounts.
- Name
subjectId- Type
- string
- Description
Selects every Google Calendar, Outlook or virtual calendar account labeled with this
subjectId.
- Name
accounts- Type
- array of object
- Description
Accounts, each with its own list of calendars.
- Name
calendarRefs- Type
- array of string
- Description
Up to 20 calendars to read, as
calendarRefvalues. Defaults toprimary.
- Name
from- Type
- string (date-time)
- Required
- required
- Description
The start of the time window, as an ISO 8601 time with a zone.
- Name
to- Type
- string (date-time)
- Required
- required
- Description
The end of the time window, at most 92 days after
from.
Errors
VALIDATION_INVALID_BODY(400): The request body is not valid.AUTH_INVALID_KEY(401): The API key is missing, unknown or revoked.AUTH_EXPIRED_KEY(401): The API key has expired.AUTH_INSUFFICIENT_SCOPE(403): The API key or session does not have permission to make this request.RATE_LIMIT_EXCEEDED(429): The request rate exceeds this plan's rate limit.RATE_LIMIT_BURST(429): Too many requests were sent in a short period.INTERNAL_ERROR(500): Something went wrong on our end.
Request
curl -X POST 'https://api.pyas.io/v2/free-busy' \ -H "x-api-key: $PYAS_API_KEY" \ -H "content-type: application/json" \ -d '{ "accountIds": [ "sbx_fda58c5980_1", "sbx_fda58c5980_2" ], "from": "2026-11-14T00:00:00Z", "to": "2026-11-21T00:00:00Z"}'Response
{ "success": true, "data": { "busy": [ { "startsAt": "2026-11-14T10:00:00Z", "endsAt": "2026-11-14T11:00:00Z", "status": "busy" }, { "startsAt": "2026-11-14T15:00:00Z", "endsAt": "2026-11-14T16:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T09:30:00Z", "endsAt": "2026-11-15T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T14:00:00Z", "endsAt": "2026-11-15T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T15:00:00Z", "endsAt": "2026-11-15T17:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T19:00:00Z", "endsAt": "2026-11-15T19:30:00Z", "status": "busy" }, { "startsAt": "2026-11-15T20:00:00Z", "endsAt": "2026-11-15T21:00:00Z", "status": "busy" }, { "startsAt": "2026-11-16T09:30:00Z", "endsAt": "2026-11-16T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T14:30:00Z", "endsAt": "2026-11-16T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T16:00:00Z", "endsAt": "2026-11-16T16:30:00Z", "status": "busy" }, { "startsAt": "2026-11-16T21:00:00Z", "endsAt": "2026-11-16T21:30:00Z", "status": "busy" }, { "startsAt": "2026-11-17T09:30:00Z", "endsAt": "2026-11-17T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-17T10:00:00Z", "endsAt": "2026-11-17T11:00:00Z", "status": "busy" }, { "startsAt": "2026-11-17T13:00:00Z", "endsAt": "2026-11-17T15:00:00Z", "status": "busy" }, { "startsAt": "2026-11-17T18:00:00Z", "endsAt": "2026-11-17T20:00:00Z", "status": "busy" }, { "startsAt": "2026-11-18T09:30:00Z", "endsAt": "2026-11-18T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-18T14:30:00Z", "endsAt": "2026-11-18T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T08:00:00Z", "endsAt": "2026-11-19T09:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T09:30:00Z", "endsAt": "2026-11-19T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T13:00:00Z", "endsAt": "2026-11-19T14:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T14:30:00Z", "endsAt": "2026-11-19T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T18:00:00Z", "endsAt": "2026-11-19T19:00:00Z", "status": "busy" } ], "accounts": [ { "accountId": "sbx_fda58c5980_1", "provider": "pyas", "busy": [ { "startsAt": "2026-11-14T15:00:00Z", "endsAt": "2026-11-14T16:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T14:30:00Z", "endsAt": "2026-11-15T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T16:00:00Z", "endsAt": "2026-11-15T17:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T19:00:00Z", "endsAt": "2026-11-15T19:30:00Z", "status": "busy" }, { "startsAt": "2026-11-15T20:00:00Z", "endsAt": "2026-11-15T21:00:00Z", "status": "busy" }, { "startsAt": "2026-11-16T14:30:00Z", "endsAt": "2026-11-16T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T21:00:00Z", "endsAt": "2026-11-16T21:30:00Z", "status": "busy" }, { "startsAt": "2026-11-17T10:00:00Z", "endsAt": "2026-11-17T11:00:00Z", "status": "busy" }, { "startsAt": "2026-11-17T14:30:00Z", "endsAt": "2026-11-17T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-17T18:00:00Z", "endsAt": "2026-11-17T20:00:00Z", "status": "busy" }, { "startsAt": "2026-11-18T14:30:00Z", "endsAt": "2026-11-18T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T13:00:00Z", "endsAt": "2026-11-19T14:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T14:30:00Z", "endsAt": "2026-11-19T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T18:00:00Z", "endsAt": "2026-11-19T19:00:00Z", "status": "busy" } ], "calendars": { "primary": [ { "startsAt": "2026-11-14T15:00:00Z", "endsAt": "2026-11-14T16:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T14:30:00Z", "endsAt": "2026-11-15T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T16:00:00Z", "endsAt": "2026-11-15T17:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T19:00:00Z", "endsAt": "2026-11-15T19:30:00Z", "status": "busy" }, { "startsAt": "2026-11-15T20:00:00Z", "endsAt": "2026-11-15T21:00:00Z", "status": "busy" }, { "startsAt": "2026-11-16T14:30:00Z", "endsAt": "2026-11-16T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T21:00:00Z", "endsAt": "2026-11-16T21:30:00Z", "status": "busy" }, { "startsAt": "2026-11-17T10:00:00Z", "endsAt": "2026-11-17T11:00:00Z", "status": "busy" }, { "startsAt": "2026-11-17T14:30:00Z", "endsAt": "2026-11-17T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-17T18:00:00Z", "endsAt": "2026-11-17T20:00:00Z", "status": "busy" }, { "startsAt": "2026-11-18T14:30:00Z", "endsAt": "2026-11-18T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T13:00:00Z", "endsAt": "2026-11-19T14:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T14:30:00Z", "endsAt": "2026-11-19T14:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T18:00:00Z", "endsAt": "2026-11-19T19:00:00Z", "status": "busy" } ] } }, { "accountId": "sbx_fda58c5980_2", "provider": "pyas", "busy": [ { "startsAt": "2026-11-14T10:00:00Z", "endsAt": "2026-11-14T11:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T09:30:00Z", "endsAt": "2026-11-15T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T14:00:00Z", "endsAt": "2026-11-15T14:30:00Z", "status": "busy" }, { "startsAt": "2026-11-15T15:00:00Z", "endsAt": "2026-11-15T16:00:00Z", "status": "busy" }, { "startsAt": "2026-11-16T09:30:00Z", "endsAt": "2026-11-16T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T16:00:00Z", "endsAt": "2026-11-16T16:30:00Z", "status": "busy" }, { "startsAt": "2026-11-17T09:30:00Z", "endsAt": "2026-11-17T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-17T13:00:00Z", "endsAt": "2026-11-17T15:00:00Z", "status": "busy" }, { "startsAt": "2026-11-18T09:30:00Z", "endsAt": "2026-11-18T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T08:00:00Z", "endsAt": "2026-11-19T09:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T09:30:00Z", "endsAt": "2026-11-19T09:45:00Z", "status": "busy" } ], "calendars": { "primary": [ { "startsAt": "2026-11-14T10:00:00Z", "endsAt": "2026-11-14T11:00:00Z", "status": "busy" }, { "startsAt": "2026-11-15T09:30:00Z", "endsAt": "2026-11-15T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-15T14:00:00Z", "endsAt": "2026-11-15T14:30:00Z", "status": "busy" }, { "startsAt": "2026-11-15T15:00:00Z", "endsAt": "2026-11-15T16:00:00Z", "status": "busy" }, { "startsAt": "2026-11-16T09:30:00Z", "endsAt": "2026-11-16T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-16T16:00:00Z", "endsAt": "2026-11-16T16:30:00Z", "status": "busy" }, { "startsAt": "2026-11-17T09:30:00Z", "endsAt": "2026-11-17T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-17T13:00:00Z", "endsAt": "2026-11-17T15:00:00Z", "status": "busy" }, { "startsAt": "2026-11-18T09:30:00Z", "endsAt": "2026-11-18T09:45:00Z", "status": "busy" }, { "startsAt": "2026-11-19T08:00:00Z", "endsAt": "2026-11-19T09:00:00Z", "status": "busy" }, { "startsAt": "2026-11-19T09:30:00Z", "endsAt": "2026-11-19T09:45:00Z", "status": "busy" } ] } } ] }, "provider": null, "traceId": "trc_5f2a9c1e7b3d4a6f8e0c2b1d", "meta": { "from": "2026-11-14T00:00:00Z", "to": "2026-11-21T00:00:00Z", "partial": false }}Find meeting times
Finds free time slots common to several people across Google Calendar, Outlook and virtual calendars. Slots respect each attendee's working hours, buffers and minimum notice, and can include a room.
Headers
- Name
Idempotency-Key- Type
- string
- Description
A unique key that makes the request safe to retry. A retry with the same key returns the original response and does not make the change twice. Keys are kept for 24 hours.
Body
- Name
attendees- Type
- array of object
- Description
The required and optional attendees. Send this or
accountIds. At most 20 items.
- Name
accountIds- Type
- array of string
- Description
A shorthand for
attendees. Each account is a required attendee, read on its primary calendar.
- Name
from- Type
- string (date-time)
- Required
- required
- Description
The start of the time window to search.
- Name
to- Type
- string (date-time)
- Required
- required
- Description
The end of the time window, at most 62 days after
from.
- Name
durationMinutes- Type
- integer
- Description
The length of the meeting in minutes. Defaults to 30. From 5 to 1440.
- Name
timezone- Type
- string
- Description
The IANA time zone that slots line up with (on the hour or half hour there). Slot times are always returned in UTC. Defaults to UTC.
- Name
workingHours- Type
- object
- Description
The working hours to use for attendees whose provider doesn't report them. Without a
timezone, they apply in each attendee's own time zone. Defaults to 09:00 to 17:00, Monday to Friday.
- Name
workingHours.days- Type
- array of string
- Required
- required
- Description
One of
sunday,monday,tuesday,wednesday,thursday,friday,saturday.
- Name
workingHours.start- Type
- string
- Required
- required
- Description
- Name
workingHours.end- Type
- string
- Required
- required
- Description
- Name
workingHours.timezone- Type
- string
- Description
- Name
respectWorkingHours- Type
- boolean
- Description
Whether to return only slots within working hours. Defaults to
true.
- Name
buffer- Type
- object
- Description
The minutes to keep free before and after other events.
- Name
buffer.before- Type
- integer
- Description
From 0 to 240.
- Name
buffer.after- Type
- integer
- Description
From 0 to 240.
- Name
minimumNoticeMinutes- Type
- integer
- Description
The minimum number of minutes between now and the start of a slot. From 0 to 43200.
- Name
slotMinutes- Type
- integer
- Description
The interval between slot start times, in minutes: 5, 10, 15, 20, 30 or 60. Defaults to 30. From 5 to 60.
- Name
tentativeIsBusy- Type
- boolean
- Description
Whether to count tentative events as busy. Defaults to
true.
- Name
limit- Type
- integer
- Description
The maximum number of slots to return. Defaults to 20. From 1 to 100.
- Name
rooms- Type
- object
- Description
Finds a free room as well, from the listed room email addresses or from the organization's matching rooms.
- Name
rooms.accountId- Type
- string
- Required
- required
- Description
The account whose organization the rooms are in.
- Name
rooms.emails- Type
- array of string
- Description
At most 20 items.
- Name
rooms.minCapacity- Type
- integer
- Description
From 1 to 10000.
- Name
rooms.building- Type
- string
- Description
- Name
rooms.required- Type
- boolean
- Description
Whether to return only slots with a free room. Defaults to
true.
Errors
VALIDATION_INVALID_BODY(400): The request body is not valid.AUTH_INVALID_KEY(401): The API key is missing, unknown or revoked.AUTH_EXPIRED_KEY(401): The API key has expired.AUTH_INSUFFICIENT_SCOPE(403): The API key or session does not have permission to make this request.CONNECTION_NOT_FOUND(404): No connected account was found for this request.RATE_LIMIT_EXCEEDED(429): The request rate exceeds this plan's rate limit.RATE_LIMIT_BURST(429): Too many requests were sent in a short period.INTERNAL_ERROR(500): Something went wrong on our end.
Request
curl -X POST 'https://api.pyas.io/v2/meeting-times' \ -H "x-api-key: $PYAS_API_KEY" \ -H "content-type: application/json" \ -d '{ "accountIds": [ "sbx_fda58c5980_1", "sbx_fda58c5980_2" ], "from": "2026-11-15T00:00:00Z", "to": "2026-11-22T00:00:00Z", "durationMinutes": 30, "timezone": "America/New_York"}'Response
{ "success": true, "data": [ { "startsAt": "2026-11-16T14:00:00Z", "endsAt": "2026-11-16T14:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-16T15:00:00Z", "endsAt": "2026-11-16T15:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-16T15:30:00Z", "endsAt": "2026-11-16T16:00:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-16T16:30:00Z", "endsAt": "2026-11-16T17:00:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-17T15:00:00Z", "endsAt": "2026-11-17T15:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-17T15:30:00Z", "endsAt": "2026-11-17T16:00:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-17T16:00:00Z", "endsAt": "2026-11-17T16:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-17T16:30:00Z", "endsAt": "2026-11-17T17:00:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-18T14:00:00Z", "endsAt": "2026-11-18T14:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-18T15:00:00Z", "endsAt": "2026-11-18T15:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-18T15:30:00Z", "endsAt": "2026-11-18T16:00:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-18T16:00:00Z", "endsAt": "2026-11-18T16:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-18T16:30:00Z", "endsAt": "2026-11-18T17:00:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-19T14:00:00Z", "endsAt": "2026-11-19T14:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-19T15:00:00Z", "endsAt": "2026-11-19T15:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-19T15:30:00Z", "endsAt": "2026-11-19T16:00:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-19T16:00:00Z", "endsAt": "2026-11-19T16:30:00Z", "optionalFree": [], "optionalBusy": [] }, { "startsAt": "2026-11-19T16:30:00Z", "endsAt": "2026-11-19T17:00:00Z", "optionalFree": [], "optionalBusy": [] } ], "provider": null, "traceId": "trc_5f2a9c1e7b3d4a6f8e0c2b1d", "meta": { "timezone": "America/New_York", "attendees": [ { "accountId": "sbx_fda58c5980_1", "optional": false, "workingHours": { "days": [ "monday", "tuesday", "wednesday", "thursday", "friday" ], "start": "09:00", "end": "17:00", "timezone": "America/New_York", "source": "default" } }, { "accountId": "sbx_fda58c5980_2", "optional": false, "workingHours": { "days": [ "monday", "tuesday", "wednesday", "thursday", "friday" ], "start": "09:00", "end": "17:00", "timezone": "Europe/London", "source": "default" } } ], "partial": false }}List rooms and resources
Returns the rooms and resources of the account's organization, from the Google Workspace resource directory or from the Microsoft Outlook room list. Both providers require an administrator's consent, and the error explains when it is missing. To book a room, add its email address to an event's rooms.
Query parameters
- Name
accountId- Type
- string
- Required
- required
- Description
The Pyas
accountIdof the connected account.
- Name
minCapacity- Type
- integer
- Description
Returns only rooms with at least this many seats. From 1 to 10000.
- Name
building- Type
- string
- Description
In this building (its name, any case).
- Name
feature- Type
- string
- Description
Returns only rooms with a feature that contains this text, such as
video.
- Name
q- Type
- string
- Description
Returns only rooms whose name or email address contains this text.
- Name
kind- Type
- string
- Description
One of
room,resource.
Errors
VALIDATION_INVALID_QUERY(400): A query parameter is not valid.AUTH_INVALID_KEY(401): The API key is missing, unknown or revoked.AUTH_EXPIRED_KEY(401): The API key has expired.AUTH_INSUFFICIENT_SCOPE(403): The API key or session does not have permission to make this request.CONNECTION_NOT_FOUND(404): No connected account was found for this request.CONNECTION_SCOPE_INSUFFICIENT(422): The connected account did not grant a permission that this operation requires.VALIDATION_UNSUPPORTED_OPERATION(422): This provider does not support this operation.PROVIDER_RATE_LIMITED(429): The calendar provider is rate limiting requests for this account.RATE_LIMIT_EXCEEDED(429): The request rate exceeds this plan's rate limit.RATE_LIMIT_BURST(429): Too many requests were sent in a short period.INTERNAL_ERROR(500): Something went wrong on our end.PROVIDER_UNAVAILABLE(503): The calendar provider is not responding normally.
Request
curl 'https://api.pyas.io/v2/rooms?accountId=sbx_fda58c5980_google&minCapacity=6' \ -H "x-api-key: $PYAS_API_KEY"Response
{ "success": true, "data": [ { "id": "c_1880boardroom", "name": "Boardroom", "email": "c_1880boardroom@resource.calendar.google.com", "capacity": 12, "building": "HQ", "floor": "3", "features": [ "Video conferencing", "Whiteboard" ], "accessible": null, "kind": "room" }, { "id": "c_1880room4b", "name": "Room 4B", "email": "c_1880room4b@resource.calendar.google.com", "capacity": 6, "building": "HQ", "floor": "4", "features": [ "Display" ], "accessible": null, "kind": "room" } ], "provider": "google", "traceId": "trc_5f2a9c1e7b3d4a6f8e0c2b1d", "meta": {}}