openapi: replace participantName with participantIdentity in API parameters and improve updateParticipant endpoint
This commit is contained in:
parent
06b2938bf3
commit
1071c4c97e
@ -0,0 +1,7 @@
|
|||||||
|
name: participantIdentity
|
||||||
|
in: path
|
||||||
|
required: true
|
||||||
|
description: The identity of the participant.
|
||||||
|
schema:
|
||||||
|
type: string
|
||||||
|
example: 'Alice'
|
||||||
@ -1,7 +0,0 @@
|
|||||||
name: participantName
|
|
||||||
in: path
|
|
||||||
required: true
|
|
||||||
description: The name of the participant.
|
|
||||||
schema:
|
|
||||||
type: string
|
|
||||||
example: 'Alice'
|
|
||||||
@ -0,0 +1,12 @@
|
|||||||
|
description: Update participant role
|
||||||
|
required: true
|
||||||
|
content:
|
||||||
|
application/json:
|
||||||
|
schema:
|
||||||
|
type: object
|
||||||
|
properties:
|
||||||
|
role:
|
||||||
|
type: string
|
||||||
|
enum: ['moderator', 'speaker']
|
||||||
|
description: The new role to assign to the participant.
|
||||||
|
example: 'moderator'
|
||||||
@ -6,4 +6,4 @@ content:
|
|||||||
properties:
|
properties:
|
||||||
message:
|
message:
|
||||||
type: string
|
type: string
|
||||||
example: 'Participant "123" role updated to "moderator"'
|
example: 'Participant "Alice" role updated to "moderator"'
|
||||||
|
|||||||
@ -46,8 +46,8 @@ paths:
|
|||||||
$ref: './paths/internal/participants.yaml#/~1participants~1token~1refresh'
|
$ref: './paths/internal/participants.yaml#/~1participants~1token~1refresh'
|
||||||
/meetings/{roomId}:
|
/meetings/{roomId}:
|
||||||
$ref: './paths/internal/meetings.yaml#/~1meetings~1{roomId}'
|
$ref: './paths/internal/meetings.yaml#/~1meetings~1{roomId}'
|
||||||
/meetings/{roomId}/participants/{participantName}:
|
/meetings/{roomId}/participants/{participantIdentity}:
|
||||||
$ref: './paths/internal/meetings.yaml#/~1meetings~1{roomId}~1participants~1{participantName}'
|
$ref: './paths/internal/meetings.yaml#/~1meetings~1{roomId}~1participants~1{participantIdentity}'
|
||||||
|
|
||||||
components:
|
components:
|
||||||
securitySchemes:
|
securitySchemes:
|
||||||
|
|||||||
@ -26,9 +26,38 @@
|
|||||||
$ref: '../../components/responses/error-room-not-found.yaml'
|
$ref: '../../components/responses/error-room-not-found.yaml'
|
||||||
'500':
|
'500':
|
||||||
$ref: '../../components/responses/internal-server-error.yaml'
|
$ref: '../../components/responses/internal-server-error.yaml'
|
||||||
/meetings/{roomId}/participants/{participantName}:
|
/meetings/{roomId}/participants/{participantIdentity}:
|
||||||
|
patch:
|
||||||
|
operationId: updateParticipant
|
||||||
|
summary: Update participant in a meeting
|
||||||
|
description: >
|
||||||
|
Updates the properties of a participant in the current meeting in an OpenVidu Meet room.
|
||||||
|
This can be used to change the participant role.
|
||||||
|
tags:
|
||||||
|
- Internal API - Meetings
|
||||||
|
security:
|
||||||
|
- participantTokenCookie: []
|
||||||
|
parameters:
|
||||||
|
- $ref: '../../components/parameters/room-id-path.yaml'
|
||||||
|
- $ref: '../../components/parameters/internal/participant-identity.yaml'
|
||||||
|
- $ref: '../../components/parameters/internal/x-participant-role.yaml'
|
||||||
|
requestBody:
|
||||||
|
$ref: '../../components/requestBodies/internal/update-participant-request.yaml'
|
||||||
|
responses:
|
||||||
|
'200':
|
||||||
|
$ref: '../../components/responses/internal/success-update-participant.yaml'
|
||||||
|
'400':
|
||||||
|
$ref: '../../components/responses/internal/error-invalid-participant-role.yaml'
|
||||||
|
'401':
|
||||||
|
$ref: '../../components/responses/unauthorized-error.yaml'
|
||||||
|
'403':
|
||||||
|
$ref: '../../components/responses/forbidden-error.yaml'
|
||||||
|
'404':
|
||||||
|
$ref: '../../components/responses/internal/error-room-participant-not-found.yaml'
|
||||||
|
'500':
|
||||||
|
$ref: '../../components/responses/internal-server-error.yaml'
|
||||||
delete:
|
delete:
|
||||||
operationId: disconnectParticipant
|
operationId: kickParticipant
|
||||||
summary: Kick a participant from a meeting
|
summary: Kick a participant from a meeting
|
||||||
description: >
|
description: >
|
||||||
Kicks a participant from the current meeting in an OpenVidu Meet room.
|
Kicks a participant from the current meeting in an OpenVidu Meet room.
|
||||||
@ -38,7 +67,7 @@
|
|||||||
- participantTokenCookie: []
|
- participantTokenCookie: []
|
||||||
parameters:
|
parameters:
|
||||||
- $ref: '../../components/parameters/room-id-path.yaml'
|
- $ref: '../../components/parameters/room-id-path.yaml'
|
||||||
- $ref: '../../components/parameters/internal/participant-name.yaml'
|
- $ref: '../../components/parameters/internal/participant-identity.yaml'
|
||||||
- $ref: '../../components/parameters/internal/x-participant-role.yaml'
|
- $ref: '../../components/parameters/internal/x-participant-role.yaml'
|
||||||
responses:
|
responses:
|
||||||
'200':
|
'200':
|
||||||
@ -53,42 +82,4 @@
|
|||||||
$ref: '../../components/responses/internal/error-room-participant-not-found.yaml'
|
$ref: '../../components/responses/internal/error-room-participant-not-found.yaml'
|
||||||
'500':
|
'500':
|
||||||
$ref: '../../components/responses/internal-server-error.yaml'
|
$ref: '../../components/responses/internal-server-error.yaml'
|
||||||
patch:
|
|
||||||
operationId: updateParticipant
|
|
||||||
summary: Update participant in a meeting
|
|
||||||
description: >
|
|
||||||
Updates the properties of a participant in the current meeting in an OpenVidu Meet room.
|
|
||||||
This can be used to change the participant role.
|
|
||||||
tags:
|
|
||||||
- Internal API - Meetings
|
|
||||||
security:
|
|
||||||
- participantTokenCookie: []
|
|
||||||
parameters:
|
|
||||||
- $ref: '../../components/parameters/room-id-path.yaml'
|
|
||||||
- $ref: '../../components/parameters/internal/participant-name.yaml'
|
|
||||||
# - $ref: '../../components/parameters/internal/x-participant-role.yaml'
|
|
||||||
requestBody:
|
|
||||||
required: true
|
|
||||||
content:
|
|
||||||
application/json:
|
|
||||||
schema:
|
|
||||||
type: object
|
|
||||||
properties:
|
|
||||||
role:
|
|
||||||
type: string
|
|
||||||
enum: [MODERATOR, SPEAKER]
|
|
||||||
description: The new role for the participant.
|
|
||||||
responses:
|
|
||||||
'200':
|
|
||||||
$ref: '../../components/responses/internal/success-update-participant.yaml'
|
|
||||||
'400':
|
|
||||||
$ref: '../../components/responses/internal/error-invalid-participant-role.yaml'
|
|
||||||
'401':
|
|
||||||
$ref: '../../components/responses/unauthorized-error.yaml'
|
|
||||||
'403':
|
|
||||||
$ref: '../../components/responses/forbidden-error.yaml'
|
|
||||||
'404':
|
|
||||||
$ref: '../../components/responses/internal/error-room-participant-not-found.yaml'
|
|
||||||
'500':
|
|
||||||
$ref: '../../components/responses/internal-server-error.yaml'
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user