Where a sign-in ends
const url = 'https://api.sloose.com/auth/zoho/done?rediscover=1';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.sloose.com/auth/zoho/done?rediscover=1'Better Auth sends the browser here after its callback, with the session cookie it just set — or with ?error= when the sign-in failed. On success this reads the session, runs discovery for an administrator (the first time, or when /auth/zoho/start was asked to rediscover) with the login access token, and answers with the popup page that hands { type: "sloose:session", token, orgId, userId, role, dc, exp } to the opener. On failure the page carries { type: "sloose:auth-error", message }.
You never call this directly.
Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”The origin the session is posted to; checked again here.
The origin the session is posted to; checked again here.
Re-read the CRM even if a snapshot exists.
Example
1Re-read the CRM even if a snapshot exists.
Set by Better Auth when the sign-in failed.
Set by Better Auth when the sign-in failed.
The reason, when there is one.
The reason, when there is one.
Responses
Section titled “Responses”A small HTML page that posts the outcome to window.opener and closes itself. Not a JSON API.
A small HTML page that posts the outcome to window.opener and closes itself. Not a JSON API.
A small HTML page that posts the outcome to window.opener and closes itself. Not a JSON API.