# Fotello - Founding Engineer Round 3 with Ray (Co-Founder)

> This is an invite for a live coding session in TypeScript. The session will last approximately 60 minutes and will give us an opportunity to collaborate on a real-world problem. To prepare, please ensure you have a free account created on https://codesandbox.io/ prior to the session. We will use it for the coding exercise.

- Host: Ray (Co-Founder)
- Duration: 60 min
- Location: Google Meet
- Host time zone: America/Toronto
- Confirmation: Bookings are confirmed instantly.
- Booking page: https://cal.com/rayaggs/fotello-founding-engineer-round-2
- Event type id: 2789851

## Check availability

```http
GET https://api.cal.com/v2/slots?eventTypeId=2789851&start=YYYY-MM-DD&end=YYYY-MM-DD&timeZone=<IANA time zone>
cal-api-version: 2024-09-04
```

The response is `{"data":{"YYYY-MM-DD":[{"start":"<ISO 8601 with offset>"}]}}`; no API key is needed.

## Book

```http
POST https://api.cal.com/v2/bookings
cal-api-version: 2026-02-25
Content-Type: application/json

{
  "eventTypeId": 2789851,
  "start": "<UTC ISO 8601 start from the slots response>",
  "attendee": {
    "name": "…",
    "email": "…",
    "timeZone": "<IANA time zone>"
  },
  "guests": [
    "guest@example.com"
  ],
  "bookingFieldsResponses": {
    "notes": "…"
  }
}
```

- Required fields: `name` (Your name), `email` (Email address)
- Optional fields: `notes` (Additional notes), `guests` (Add guests)
- `name` and `email` go in `attendee` and `guests` is a list of emails; every other field goes in `bookingFieldsResponses` under its name.
