What to have ready
- A Chert project and provisioned FaceTime line, including its handle and line ID.
- Your LiveKit project, WebSocket URL, and server-side API key and secret.
- A backend that prepares a room and mints separate tokens for your agent and Chert’s bridge.
- An agent that publishes audio and consumes the caller’s audio. For inbound video, also publish and subscribe to video.
- A person ready to place or answer the test call. Each line handles one active call at a time.
1. Get your project key
Open Developer → Project API keys. Create a key withfacetime:write for create/end and facetime:read for status/events. Store it on your backend and copy the Project ID.
2. Choose your line
line_id. Chert does not fall back to another line when it is unavailable.
3. Prepare your LiveKit agent
Run your agent in your room with exactly one eligible, unmuted audio publication. Mint a separate, room-scoped bridge token with join, publish, and subscribe grants and an identity distinct from your agent. See the token requirements. For outbound, keep the agent silent untilbridge_ready. The bridge token needs more than 90 seconds remaining at allocation and an issued lifetime of at most two hours.
4. Choose a calling direction
- Inbound
- Outbound
Set the line to Call your provisioned handle using FaceTime Audio, or FaceTime Video on a video-enabled line. The BYOR guide covers the incoming event and decline response.
customer_decides with no default Assistant. Configure its HTTPS Integration URL. If you enable webhook signing, store the signing secret on your backend and verify incoming signatures.On call.incoming, return an accept response within the decision deadline (five seconds by default):5. Verify the call and cleanup
Confirm clear two-way audio. For inbound video, also confirm that each side sees the other’s current video. Subscribe to the bridge’sfacetime-remote-audio track and, when enabled, facetime-remote-video.
Hang up from either end, or end through the API using the call ID and a unique end key (8–200 characters):
END_KEY before running the command. HTTP 202 acknowledges the request. Check that FaceTime ends, the call becomes terminal, and the line becomes available again. Your backend must also release its agent and room resources. See Calls API.
