Clerk · Capability

Clerk Backend Api — Sessions

Clerk Sessions capability. 7 operations. Lead operation: List All Sessions.

Run with Naftiko ClerkSessions

Capability Spec

clerk-backend-api-sessions.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Clerk Backend Api — Sessions
  description: 'Clerk Sessions capability. 7 operations. Lead operation: List All Sessions.'
  tags:
  - Clerk
  - Sessions
  created: '2026-05-22'
  modified: '2026-05-22'
binds:
- namespace: env
  keys:
    CLERK_SECRET_KEY: CLERK_SECRET_KEY
capability:
  consumes:
  - type: http
    namespace: clerk-backend-api-sessions
    baseUri: https://api.clerk.com/v1
    description: Clerk clerk-backend-api Sessions business capability.
    resources:
    - name: sessions
      path: /sessions
      operations:
      - name: GetSessionList
        method: GET
        description: List All Sessions
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: client_id
          in: query
          type: string
          description: List sessions for the given client
          required: false
        - name: user_id
          in: query
          type: string
          description: List sessions for the given user
          required: false
        - name: status
          in: query
          type: string
          description: Filter sessions by the provided status
          required: false
      - name: createSession
        method: POST
        description: Create a New Active Session
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: sessions-session-id
      path: /sessions/{session_id}
      operations:
      - name: GetSession
        method: GET
        description: Retrieve a Session
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: session_id
          in: path
          type: string
          description: The ID of the session
          required: true
    - name: sessions-session-id-refresh
      path: /sessions/{session_id}/refresh
      operations:
      - name: RefreshSession
        method: POST
        description: Refresh a Session
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: session_id
          in: path
          type: string
          description: The ID of the session
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: sessions-session-id-revoke
      path: /sessions/{session_id}/revoke
      operations:
      - name: RevokeSession
        method: POST
        description: Revoke a Session
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: session_id
          in: path
          type: string
          description: The ID of the session
          required: true
    - name: sessions-session-id-tokens
      path: /sessions/{session_id}/tokens
      operations:
      - name: CreateSessionToken
        method: POST
        description: Create a Session Token
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: session_id
          in: path
          type: string
          description: The ID of the session
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: sessions-session-id-tokens-template-name
      path: /sessions/{session_id}/tokens/{template_name}
      operations:
      - name: CreateSessionTokenFromTemplate
        method: POST
        description: Create a Session Token from a JWT Template
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: session_id
          in: path
          type: string
          description: The ID of the session
          required: true
        - name: template_name
          in: path
          type: string
          description: The name of the JWT template defined in your instance (e.g. `custom_hasura`).
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true