Sign out of the portal
curl --request DELETE \
--url https://app.hookie.ai/portal/api/session \
--cookie __Host-hookie_portal=const options = {method: 'DELETE', headers: {cookie: '__Host-hookie_portal='}};
fetch('https://app.hookie.ai/portal/api/session', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.hookie.ai/portal/api/session"
headers = {"cookie": "__Host-hookie_portal="}
response = requests.delete(url, headers=headers)
print(response.text){
"ok": true
}{
"error": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"reason": "<string>",
"code": "agent_scope_insufficient",
"required_scope": "hookie:read",
"granted_scopes": [
"<string>"
],
"manage_url": "<string>"
}Customer Portal
Sign out of the portal
Clears the session cookie. Needs X-Requested-With: fetch, and no valid session. The token itself stays valid until it is revoked or expires.
DELETE
/
portal
/
api
/
session
Sign out of the portal
curl --request DELETE \
--url https://app.hookie.ai/portal/api/session \
--cookie __Host-hookie_portal=const options = {method: 'DELETE', headers: {cookie: '__Host-hookie_portal='}};
fetch('https://app.hookie.ai/portal/api/session', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.hookie.ai/portal/api/session"
headers = {"cookie": "__Host-hookie_portal="}
response = requests.delete(url, headers=headers)
print(response.text){
"ok": true
}{
"error": "<string>",
"retry_after": 123,
"upgrade_url": "<string>",
"reason": "<string>",
"code": "agent_scope_insufficient",
"required_scope": "hookie:read",
"granted_scopes": [
"<string>"
],
"manage_url": "<string>"
}Authorizations
The customer portal's session cookie, set by POST /portal/api/session: sealed (AES-GCM), HttpOnly, Secure, SameSite=None, Partitioned, and valid for 8 hours or until the token expires, whichever is sooner. It names the token rather than copying what it grants, so revoking the token or switching the portal off ends the session at once. Requests other than GET made with it must carry X-Requested-With: fetch (CSRF).
Response
The cookie is cleared (Max-Age=0).
Available options:
true