openapi: 3.2.0 info: title: Public Media API version: beta description: 'Response bodies vary by endpoint and may return `{ data }`, `{ dataList }`, `{ dataList, pagination }`, or no body for status-only operations. Successful responses use the HTTP status defined on each operation. Error responses return `{ error: { code, message, status, meta } }` with the corresponding HTTP status code.' servers: - url: https://esaas-api.eventx.io tags: - name: Media paths: /public-api/v1/event/{eventId}/media: post: responses: '200': description: Success content: application/json: schema: type: object properties: data: type: object properties: id: type: string format: uuid fileName: type: string mimeType: type: string uploadUrl: type: string required: - id - fileName - mimeType - uploadUrl additionalProperties: false required: - data additionalProperties: false '500': description: ERROR parameters: - name: eventId in: path required: true schema: type: string format: uuid requestBody: content: application/json: schema: type: object properties: fileName: type: string checksum: type: string mimeType: type: string byteSize: type: number format: float metadata: type: object properties: eventId: type: string format: uuid regFormId: type: string format: uuid attendeeId: type: string format: uuid source: type: string enum: - attendee_registration - attendee_custom_question_update - whatsapp_incoming_message additionalProperties: false required: - fileName - checksum - mimeType - byteSize additionalProperties: false security: - bearerAuth: [] tags: - Media operationId: createMedia summary: Create a media record and get an upload URL /public-api/v1/event/{eventId}/media/{mediaId}/mark-uploaded: put: responses: {} parameters: - name: mediaId in: path required: true schema: type: string format: uuid - name: eventId in: path required: true schema: type: string format: uuid security: - bearerAuth: [] tags: - Media operationId: markMediaAsUploaded summary: Mark a media record as uploaded /public-api/v1/event/{eventId}/media/{mediaId}: get: responses: '200': description: Success content: application/json: schema: type: object properties: data: anyOf: - type: object properties: id: type: string format: uuid originalFilename: type: string originalFilepath: type: string mimeType: type: string type: type: string enum: - image - video - file size: type: number format: float required: - id - originalFilename - originalFilepath - mimeType - size additionalProperties: false - type: object properties: id: type: string format: uuid originalFilename: type: string originalFilepath: type: string mimeType: type: string type: type: string enum: - image - video - file cloudflarePlaybackUrl: type: string nullable: true size: type: number format: float required: - id - originalFilename - originalFilepath - mimeType - size additionalProperties: false - type: object properties: id: type: string format: uuid originalFilename: type: string previewFilename: type: string originalFilepath: type: string previewFilepath: type: string mimeType: type: string type: type: string enum: - image - video - file size: type: number format: float required: - id - originalFilename - previewFilename - originalFilepath - previewFilepath - mimeType - size additionalProperties: false required: - data additionalProperties: false '500': description: ERROR parameters: - name: mediaId in: path required: true schema: type: string format: uuid - name: eventId in: path required: true schema: type: string format: uuid security: - bearerAuth: [] tags: - Media operationId: getOneMedia summary: Get a media record delete: responses: {} parameters: - name: mediaId in: path required: true schema: type: string format: uuid - name: eventId in: path required: true schema: type: string format: uuid security: - bearerAuth: [] tags: - Media operationId: removeOneMedia summary: Delete a media record components: securitySchemes: bearerAuth: name: Authorization type: apiKey in: header description: Bearer Authorization with jwt token