Skip to content

Commit 0d28e39

Browse files
chore: Update OpenAPI Specs (#34)
Co-authored-by: Clerk Bot <cookie@clerk.dev>
1 parent de599eb commit 0d28e39

File tree

3 files changed

+213
-0
lines changed

3 files changed

+213
-0
lines changed

bapi/2021-02-05.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -696,6 +696,71 @@ paths:
696696
$ref: '#/components/responses/AuthenticationInvalid'
697697
'404':
698698
$ref: '#/components/responses/ResourceNotFound'
699+
/sessions/{session_id}/refresh:
700+
post:
701+
operationId: RefreshSession
702+
x-speakeasy-group: sessions
703+
x-speakeasy-name-override: refresh
704+
tags:
705+
- Sessions
706+
summary: Refresh a session
707+
description: |-
708+
Refreshes a session by creating a new session token. A 401 is returned when there
709+
are validation errors, which signals the SDKs to fallback to the handshake flow.
710+
parameters:
711+
- name: session_id
712+
in: path
713+
description: The ID of the session
714+
required: true
715+
schema:
716+
type: string
717+
requestBody:
718+
description: Refresh session parameters
719+
content:
720+
application/json:
721+
schema:
722+
type: object
723+
additionalProperties: false
724+
properties:
725+
expired_token:
726+
type: string
727+
description: |-
728+
The JWT that is sent via the `__session` cookie from your frontend.
729+
Note: this JWT must be associated with the supplied session ID.
730+
refresh_token:
731+
type: string
732+
description: The JWT that is sent via the `__session` cookie from your frontend.
733+
request_origin:
734+
type: string
735+
description: The origin of the request.
736+
request_headers:
737+
type: object
738+
additionalProperties: true
739+
description: The headers of the request.
740+
nullable: true
741+
format:
742+
type: string
743+
description: The format of the response.
744+
nullable: true
745+
default: token
746+
enum:
747+
- token
748+
- cookie
749+
request_originating_ip:
750+
type: string
751+
description: The IP address of the request.
752+
nullable: true
753+
required:
754+
- expired_token
755+
- refresh_token
756+
- request_origin
757+
responses:
758+
'200':
759+
$ref: '#/components/responses/Session.Refresh'
760+
'400':
761+
$ref: '#/components/responses/ClerkErrors'
762+
'401':
763+
$ref: '#/components/responses/AuthenticationInvalid'
699764
/sessions/{session_id}/revoke:
700765
post:
701766
operationId: RevokeSession
@@ -8528,6 +8593,12 @@ components:
85288593
application/json:
85298594
schema:
85308595
$ref: '#/components/schemas/Session'
8596+
Session.Refresh:
8597+
description: Success
8598+
content:
8599+
application/json:
8600+
schema:
8601+
$ref: '#/components/schemas/Session'
85318602
Template.List:
85328603
description: Success
85338604
content:

bapi/2024-10-01.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -696,6 +696,71 @@ paths:
696696
$ref: '#/components/responses/AuthenticationInvalid'
697697
'404':
698698
$ref: '#/components/responses/ResourceNotFound'
699+
/sessions/{session_id}/refresh:
700+
post:
701+
operationId: RefreshSession
702+
x-speakeasy-group: sessions
703+
x-speakeasy-name-override: refresh
704+
tags:
705+
- Sessions
706+
summary: Refresh a session
707+
description: |-
708+
Refreshes a session by creating a new session token. A 401 is returned when there
709+
are validation errors, which signals the SDKs to fallback to the handshake flow.
710+
parameters:
711+
- name: session_id
712+
in: path
713+
description: The ID of the session
714+
required: true
715+
schema:
716+
type: string
717+
requestBody:
718+
description: Refresh session parameters
719+
content:
720+
application/json:
721+
schema:
722+
type: object
723+
additionalProperties: false
724+
properties:
725+
expired_token:
726+
type: string
727+
description: |-
728+
The JWT that is sent via the `__session` cookie from your frontend.
729+
Note: this JWT must be associated with the supplied session ID.
730+
refresh_token:
731+
type: string
732+
description: The JWT that is sent via the `__session` cookie from your frontend.
733+
request_origin:
734+
type: string
735+
description: The origin of the request.
736+
request_headers:
737+
type: object
738+
additionalProperties: true
739+
description: The headers of the request.
740+
nullable: true
741+
format:
742+
type: string
743+
description: The format of the response.
744+
nullable: true
745+
default: token
746+
enum:
747+
- token
748+
- cookie
749+
request_originating_ip:
750+
type: string
751+
description: The IP address of the request.
752+
nullable: true
753+
required:
754+
- expired_token
755+
- refresh_token
756+
- request_origin
757+
responses:
758+
'200':
759+
$ref: '#/components/responses/Session.Refresh'
760+
'400':
761+
$ref: '#/components/responses/ClerkErrors'
762+
'401':
763+
$ref: '#/components/responses/AuthenticationInvalid'
699764
/sessions/{session_id}/revoke:
700765
post:
701766
operationId: RevokeSession
@@ -8524,6 +8589,12 @@ components:
85248589
application/json:
85258590
schema:
85268591
$ref: '#/components/schemas/Session'
8592+
Session.Refresh:
8593+
description: Success
8594+
content:
8595+
application/json:
8596+
schema:
8597+
$ref: '#/components/schemas/Session'
85278598
Template.List:
85288599
description: Success
85298600
content:

bapi/2025-12-03.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -696,6 +696,71 @@ paths:
696696
$ref: '#/components/responses/AuthenticationInvalid'
697697
'404':
698698
$ref: '#/components/responses/ResourceNotFound'
699+
/sessions/{session_id}/refresh:
700+
post:
701+
operationId: RefreshSession
702+
x-speakeasy-group: sessions
703+
x-speakeasy-name-override: refresh
704+
tags:
705+
- Sessions
706+
summary: Refresh a session
707+
description: |-
708+
Refreshes a session by creating a new session token. A 401 is returned when there
709+
are validation errors, which signals the SDKs to fallback to the handshake flow.
710+
parameters:
711+
- name: session_id
712+
in: path
713+
description: The ID of the session
714+
required: true
715+
schema:
716+
type: string
717+
requestBody:
718+
description: Refresh session parameters
719+
content:
720+
application/json:
721+
schema:
722+
type: object
723+
additionalProperties: false
724+
properties:
725+
expired_token:
726+
type: string
727+
description: |-
728+
The JWT that is sent via the `__session` cookie from your frontend.
729+
Note: this JWT must be associated with the supplied session ID.
730+
refresh_token:
731+
type: string
732+
description: The JWT that is sent via the `__session` cookie from your frontend.
733+
request_origin:
734+
type: string
735+
description: The origin of the request.
736+
request_headers:
737+
type: object
738+
additionalProperties: true
739+
description: The headers of the request.
740+
nullable: true
741+
format:
742+
type: string
743+
description: The format of the response.
744+
nullable: true
745+
default: token
746+
enum:
747+
- token
748+
- cookie
749+
request_originating_ip:
750+
type: string
751+
description: The IP address of the request.
752+
nullable: true
753+
required:
754+
- expired_token
755+
- refresh_token
756+
- request_origin
757+
responses:
758+
'200':
759+
$ref: '#/components/responses/Session.Refresh'
760+
'400':
761+
$ref: '#/components/responses/ClerkErrors'
762+
'401':
763+
$ref: '#/components/responses/AuthenticationInvalid'
699764
/sessions/{session_id}/revoke:
700765
post:
701766
operationId: RevokeSession
@@ -8524,6 +8589,12 @@ components:
85248589
application/json:
85258590
schema:
85268591
$ref: '#/components/schemas/Session'
8592+
Session.Refresh:
8593+
description: Success
8594+
content:
8595+
application/json:
8596+
schema:
8597+
$ref: '#/components/schemas/Session'
85278598
Template.List:
85288599
description: Success
85298600
content:

0 commit comments

Comments
 (0)