Authorized iframe Access
Get Access Token
POST
Get Access Token
Securely generate 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 and long-lived refresh_token for authorized iframe access.
⚠️ Important: This endpoint must be called from your server, not from the client side. The client_api_key is sensitive and should never be exposed on the client side.
Once you obtain the tokens, pass the access_token to the client-side where the iframe will be embedded.
Embed URL for Iframe
Use the following format to embed the iframe securely:- Ensure tokens are stored securely, as refresh token will be used to retrieve a new access token when the old one expires.
- Refresh token logic is explained in the next API endpoint:
/ai-agent/refresh_token. - Never expose the
client_api_keyon the frontend.
Body
application/json
Example:
"user123 // client's customer id"
Example:
"8a1e3f18-991b-4a2e-9973-f53e7fc94ff1"
AI Agent Auth Key - Can be retrieved from https://app.chatzy.ai/profile
Example:
"ak-xxxxxxxxxxx"
Response
200 - application/json
Access and refresh token response
Get Access Token