Operation
Bootstrap a Live session
POST
/sessionResolves the channel and mints a session that holds the channel’s publishable key server-side. Hosted callers (channel resolved from the Host header or an explicit `domain`) receive an httpOnly cookie; embed callers (providing a `channelKey`) receive the session id in the body.
Body
Returns
Session created.
status*"success"
data*any
metadata*any
Errors
- 400
- The channel could not be resolved (no host).
- 404
- No channel is configured for this site.
Every error names its code and links to it. All error codes
curl -X POST "https://live.ticketlayer.com/session" \ -H "Authorization: Bearer tlpk_..." \ -H "Content-Type: application/json" \ -d '{ "channelKey": "tlpk_live_abc123", "domain": "tickets.example.com" }'Response 201
{
"status": "success",
"data": {
"sessionToken": "string",
"channel": {
"id": "sch_123",
"name": "Main Box Office",
"slug": "main-box-office"
},
"customer": {
"id": "cus_123",
"email": "visitor@example.com",
"firstName": "Ada",
"lastName": "Lovelace"
}
},
"metadata": {
"requestId": "string"
}
}