Skip to main content

Get My User Sessions

Returns a list of a user session for the user agent of the authenticated user. This can be used to switch accounts in the current application.

Request Body required
  • object
Responses

A successful response.


Schema
  • result object[]
  • Array [
  • sessionId string
  • agentId string
  • authState string

    Possible values: [SESSION_STATE_UNSPECIFIED, SESSION_STATE_ACTIVE, SESSION_STATE_TERMINATED]

    Default value: SESSION_STATE_UNSPECIFIED

    current state of the session

  • userId string
  • userName string
  • loginName string
  • displayName string

    the display name of the user

  • details object
  • sequence uint64

    on read: the sequence of the last event reduced by the projection

    on manipulation: the timestamp of the event(s) added by the manipulation

  • creationDate date-time

    on read: the timestamp of the first event of the object

    on create: the timestamp of the event(s) added by the manipulation

  • changeDate date-time

    on read: the timestamp of the last event reduced by the projection

    on manipulation: the

  • resourceOwner resource_owner is the organization an object belongs to
  • avatarUrl string

    avatar URL of the user

  • ]
POST /users/me/sessions/_search

Authorization

type: oauth2flow: authorizationCodescopes: openid

Request

Base URL
https://$ZITADEL_DOMAIN/auth/v1
Bearer Token
Content-Type
Body required
{}
Accept
curl -L -X POST 'https://$ZITADEL_DOMAIN/auth/v1/users/me/sessions/_search' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{}'