Logout Current User Session
    • Dark
      Light
    • PDF

    Logout Current User Session

    • Dark
      Light
    • PDF

    Article summary

    Post
    /api/v1/sessions/logout.me
    Premium tag

    This endpoint allows an authenticated user to log out of any of their sessions on the workspace. It is designed specifically for the user to terminate their sessions and cannot be used to log out sessions belonging to other users on the workspace.

    Changelog

    VersionDescription
    5.0.0Added
    Header parameters
    X-User-Id
    stringRequired

    The user ID.

    ExampleCkCPNctrgCDfmWLqC
    X-Auth-Token
    stringRequired

    The authentication token.

    Example1Dd4iN_ClKn5jl-xPC36snQ4s9Zd5GZnXCQuCNSKcVE
    Body parameters
    Example 1
    {
      "sessionId": "WJ2giBwm4B9mcojFi"
    }
    object
    sessionId
    string Required

    The session ID.

    Responses
    200

    OK

    Success Example
    {
      "sessionId": "WJ2giBwm4B9mcojFi",
      "success": true
    }
    object
    sessionId
    string
    success
    boolean
    400

    Bad Request

    Example 1
    {
      "success": false,
      "error": "Session not found"
    }
    object
    success
    boolean
    error
    string
    401

    Unauthorized

    Authorization Error
    {
      "status": "error",
      "message": "You must be logged in to do this."
    }
    object
    status
    string
    message
    string


    Was this article helpful?

    What's Next
    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.