feat: endpoint for create video service

This commit is contained in:
Rafi Arrafif
2026-01-30 15:18:00 +07:00
parent 0521c27834
commit ab0c8afca4
6 changed files with 83 additions and 1 deletions

View File

@ -0,0 +1,23 @@
import { SystemAccountId } from "../../../../config/account/system";
import { ErrorForwarder } from "../../../../helpers/error/instances/forwarder";
import { CreateVideoServiceBodyRequest } from "../../controllers/createVideoService.controller";
import { createVideoServiceInternalRepository } from "../../repositories/createVideoService.repository";
export const createVideoServiceInternalService = async (
body: CreateVideoServiceBodyRequest,
) => {
try {
return await createVideoServiceInternalRepository({
name: body.name,
domain: body.domain,
logo: body.logo,
hexColor: body.hexColor,
endpointVideo: body.endpointVideo,
endpointThumbnail: body.endpointThumbnail,
endpointDownload: body.endpointDownload,
createdBy: SystemAccountId,
});
} catch (error) {
ErrorForwarder(error);
}
};