Update Logout Flow
GET/auth/self-service/logout
This endpoint logs out an identity in a self-service manner.
If the Accept
HTTP header is not set to application/json
, the browser will be redirected (HTTP 303 See Other)
to the return_to
parameter of the initial request or fall back to urls.default_return_to
.
If the Accept
HTTP header is set to application/json
, a 204 No Content response
will be sent on successful logout instead.
This endpoint is NOT INTENDED for API clients and only works with browsers (Chrome, Firefox, ...).
Request
Query Parameters
A Valid Logout Token
If you do not have a logout token because you only have a session cookie,
call /logout/browser
to generate a URL for this endpoint.
The URL to return to after the logout was completed.
Header Parameters
HTTP Cookies
When using the SDK in a browser app, on the server side you must include the HTTP Cookie Header sent by the client to your server here. This ensures that CSRF and session cookies are respected.
Responses
- 204
- 303
- default
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
errorGeneric
- application/json
- Schema
- Example (from schema)
Schema
error objectrequired
The status code
Debug information
This field is often not exposed to protect against leaking sensitive information.
details object
Further error details
The error ID
Useful when trying to identify various errors in application logic.
Error message
The error's message.
A human-readable reason for the error
The request ID
The request ID is often exposed internally in order to trace errors across service architectures. This is often a UUID.
The status description
{
"error": {
"code": 404,
"debug": "SQL field \"foo\" is not a bool.",
"details": {},
"id": "string",
"message": "The resource could not be found",
"reason": "User with ID 1234 does not exist.",
"request": "d7ef54b1-ec15-46e6-bccb-524b82c035e6",
"status": "Not Found"
}
}