Authorized iframe Access
Get New Access Token from Refresh Token
POST
Get New Access Token from Refresh Token
Generate a new short-livedDocumentation Index
Fetch the complete documentation index at: https://docs.chatzy.ai/llms.txt
Use this file to discover all available pages before exploring further.
access_token using a valid refresh_token previously issued.
⚠️ Important: This endpoint must be called from your server. Never expose refresh_token or any sensitive token logic to the frontend or the iframe.
When the access_token passed in the iframe query params expires, the Chatzy AI iframe will send a postMessage event to the parent window with following JSON payload:
postMessage event, and call this /ai_agent/refresh_token API from your server to get a new access_token using the stored refresh_token.
Once you get the new token, respond back to the iframe with following JSON payload:
⚠️ Do not sendrefresh_tokento the iframe or store it in localStorage/cookies on the client. Chatzy AI iframe only needsaccess_tokento make authorized API calls.
Body
application/json
Response
200 - application/json
New access token issued successfully
Get New Access Token from Refresh Token