backend: Rename recording content endpoint to media
This commit is contained in:
parent
597b412027
commit
6774e56a27
@ -18,7 +18,7 @@ paths:
|
||||
/recordings/{recordingId}:
|
||||
$ref: './paths/recordings.yaml#/~1recordings~1{recordingId}'
|
||||
/recordings/{recordingId}/content:
|
||||
$ref: './paths/recordings.yaml#/~1recordings~1{recordingId}~1content'
|
||||
$ref: './paths/recordings.yaml#/~1recordings~1{recordingId}~1media'
|
||||
components:
|
||||
securitySchemes:
|
||||
$ref: './components/security.yaml'
|
||||
|
||||
@ -126,13 +126,13 @@
|
||||
$ref: '../components/responses/error-recording-in-progress.yaml'
|
||||
'500':
|
||||
$ref: '../components/responses/internal-server-error.yaml'
|
||||
/recordings/{recordingId}/content:
|
||||
/recordings/{recordingId}/media:
|
||||
get:
|
||||
operationId: getRecordingContent
|
||||
summary: Get recording content
|
||||
operationId: getRecordingMeedia
|
||||
summary: Get recording media
|
||||
description: >
|
||||
Retrieves the content of a recording with the specified recording ID.
|
||||
The content is returned in a binary format suitable for video playback.
|
||||
Retrieves the media of a recording with the specified recording ID.
|
||||
The media is returned in a binary format suitable for video playback.
|
||||
This endpoint supports range requests, allowing partial content retrieval
|
||||
for video playback without downloading the entire file.
|
||||
tags:
|
||||
|
||||
@ -127,13 +127,13 @@ export const deleteRecording = async (req: Request, res: Response) => {
|
||||
};
|
||||
|
||||
/**
|
||||
* Streams a recording video file to the client with support for range requests.
|
||||
* Get recording media
|
||||
*
|
||||
* This controller endpoint retrieves a recording by its ID and streams it as a video/mp4 file.
|
||||
* It supports HTTP range requests, allowing for features like video seeking and partial downloads.
|
||||
*
|
||||
*/
|
||||
export const getRecordingContent = async (req: Request, res: Response) => {
|
||||
export const getRecordingMedia = async (req: Request, res: Response) => {
|
||||
const logger = container.get(LoggerService);
|
||||
|
||||
const recordingId = req.params.recordingId;
|
||||
|
||||
@ -46,10 +46,10 @@ recordingRouter.delete(
|
||||
);
|
||||
|
||||
recordingRouter.get(
|
||||
'/:recordingId/content',
|
||||
'/:recordingId/media',
|
||||
withAuth(apiKeyValidator, tokenAndRoleValidator(UserRole.ADMIN)),
|
||||
withValidRecordingId,
|
||||
recordingCtrl.getRecordingContent
|
||||
recordingCtrl.getRecordingMedia
|
||||
);
|
||||
|
||||
// Internal Recording Routes
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user