Sign a device out
DELETE
/api/v1/me/sessions/{sessionId}
const url = 'http://localhost:8080/api/v1/me/sessions/1';const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request DELETE \ --url http://localhost:8080/api/v1/me/sessions/1 \ --header 'Authorization: Bearer <token>'Ends one of your sessions, such as a lost device’s. Ending the current one signs you out. Refused for a demo account (demo_account), whose visitors would sign each other out; they sign out with signOut.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”sessionId
required
integer format: int64
Responses
Section titled “Responses”The session was ended.
The request has no valid session token.
Media typeapplication/json
object
code
required
string
message
required
Explains the problem to a developer.
string
Example
{ "code": "bad_request"}The signed-in user may not do this. demo_account when the user is a
shared demo account, named in CHEK_DEMO_USERS, which can’t change
its password, sessions, sign-in providers, extensions or annotations.
Media typeapplication/json
object
code
required
string
message
required
Explains the problem to a developer.
string
Example
{ "code": "bad_request"}The resource does not exist.
Media typeapplication/json
object
code
required
string
message
required
Explains the problem to a developer.
string
Example
{ "code": "bad_request"}The server failed; details are in its log.
Media typeapplication/json
object
code
required
string
message
required
Explains the problem to a developer.
string
Example
{ "code": "bad_request"}