Skip to main content
Use OAuth when your application needs a user-authorized connection to a ChatATP Studio workspace. Public clients must use PKCE with S256.

1. Generate the authorization URL

The consent screen is hosted by Studio at https://studio.chat-atp.com/oauth/authorize/. Register the exact redirect_uri in Account → Developers → OAuth Apps.

2. Exchange the callback code

Your registered redirect URI receives code and state. Validate state against the value stored in the user’s session before exchanging the code.
Keep the access and refresh tokens on your server. Do not put a client secret or refresh token in browser code.

3. Refresh and revoke

Access tokens expire after one hour. Refresh tokens are rotated on every refresh, so replace the stored refresh token with the returned value.

Supported scopes

agents:read, agents:write, conversations:read, conversations:write, messages:send, knowledge:read, knowledge:write, memory:read, memory:write, channels:read, channels:write, and users:read. The users:read scope enables oauth.userinfo().