> ## Documentation Index
> Fetch the complete documentation index at: https://docs.facetime.trychert.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Model 3: Bring Your Own Room

> You host the room; Chert joins it as the FaceTime gateway.

Your server creates the LiveKit room and mints a participant token for Chert's bridge. The bridge publishes the FaceTime caller's microphone and camera and subscribes to the participant identity you name.

<Tip>
  **No standing credential exchange**

  Each call uses a single-use, single-room, short-expiry token. Chert never holds your LiveKit API keys; you never hold Chert's.
</Tip>

<h2 id="token">
  Token requirements
</h2>

* `canPublish: true`
* `canSubscribe: true`
* Scoped to one room
* Recommended TTL: call duration plus margin, with a two-hour maximum

<h2 id="inbound">
  Inbound flow
</h2>

1. FaceTime rings and Chert sends a signed `call.incoming` event.
2. You choose a room and respond within five seconds.
3. Chert answers, joins, binds to the named participant, and bridges both directions.
4. Hangup emits `call.ended`; the token expires and nothing persists.

```json theme={null}
{
  "event_id": "evt_5a…",
  "type": "call.incoming",
  "call_id": "call_7d1a…",
  "line_id": "line_…",
  "media": "video",
  "from_handle_hash": "sha256:…"
}
```

```json theme={null}
{
  "action": "accept",
  "livekit_url": "wss://your-project.livekit.cloud",
  "participant_token": "eyJ…",
  "remote_participant_identity": "acme-anam-agent"
}
```

No response within five seconds is declined fail-closed. Have the named participant joined or joining before acceptance; if it never appears during the readiness window, Chert ends the call with a named failure.

<h2 id="outbound">
  Outbound
</h2>

```http theme={null}
POST /v1/calls
{
  "facetime_handle": "+15551234567",
  "media": "video",
  "livekit_url": "wss://your-project.livekit.cloud",
  "participant_token": "eyJ…",
  "remote_participant_identity": "acme-anam-agent"
}
→ 202 { "call_id": "call_8e2b…" }
```
