Agents
Mint a hosted widget voice session
Validates the published widget, exact browser Origin, Agent/account status, credit posture, and durable per-widget/per-IP daily limits, then returns one short-lived origin-locked omni:session token. The request body cannot select an organization, project, or Agent.
post/public/widgets/{publicId}/session
Request
- Base URL: https://api.pyai.com
- URL: https://api.pyai.com/public/widgets/{publicId}/session
- Auth: none required
Path parameters
publicIdstring required
Headers
Originstring uri required
Response
Short-lived widget session
Example response
{
"object": "omni.session",
"token": "pyai_live_sess_a1B2…",
"url": "wss://api.pyai.com/v1/omni?format=pcm16&rate=24000"
}Changes
No recorded changes to this operation across all 1 revision of this API.