1. Media Manager
  • Getting Started
    • Introduction
    • Quickstart
    • Authentication
    • Status codes
  • Webhook
    • Webhook Setup
    • Webhook Events and Schema
  • API Reference
    • Contact
      • Listing
      • Create
      • Filter By SocialPlatformId
      • Form Fields
      • Detail
      • Update
      • Delete
      • Fetch Contact Groups
      • Update tags
    • Tag
      • Listing
    • Channel
      • Listing
      • Create
    • Ticket
      • Listing
      • Create
      • Filter by Contact ID
      • Form Fields
      • Update
      • Update status
    • Category
      • Listing
    • CxLog
      • Listing
    • Message
      • Send message
      • Create comments
      • Get Comments
    • Media Manager
      • Get Folders
        GET
      • Get Folder By ID
        GET
      • Create Folder
        POST
      • Update Folder
        PATCH
      • Delete Folder
        DELETE
      • Get Files
        GET
      • Get File By ID
        GET
      • Create File
        POST
      • Update File
        PATCH
      • Delete File
        DELETE
    • Agent Activity
      • Get Agents Activities
    • Telephony
      • Get Telephony CDR
Blog
Github
  1. Media Manager

Create File

POST
/api/v1/media-manager/files
Create a media file using base64 data

Request

Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Body Params application/json

Examples

Responses

🟢200
application/json
Body

Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://apigw.klinkcx.com/api/v1/media-manager/files' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
  "data": "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8BQDwAEhQGAhKmMIQAAAABJRU5ErkJggg==",
  "fileName": "red-pixel.png",
  "mimeType": "image/png",
  "title": "Red Pixel Test",
  "description": "A tiny test image to verify upload",
  "altText": "Alt text",
  "isPrivate": false,
  "folderId": "019b666f-5b1e-738e-b88f-6e08c466a4f7",
  "isFavorite": true,
  "sortOrder": 0
}'
Response Response Example
{
    "data": {
        "id": "a1196518-4c90-4ed0-ab9f-d5a1c8d58870",
        "uploadId": "a1196518-035f-49b6-9d22-951f6f0a7a39",
        "folderId": null,
        "title": "Red Pixel Test",
        "description": "A tiny test image to verify upload",
        "altText": "Alt text",
        "sortOrder": 0,
        "isFavorite": true,
        "isPrivate": false,
        "createdAt": "2026-02-17T05:00:23.000000Z",
        "updatedAt": "2026-02-17T05:00:23.000000Z",
        "upload": {
            "id": "a1196518-035f-49b6-9d22-951f6f0a7a39",
            "fileName": "red-pixel.png",
            "fileSize": 70,
            "fileUrl": "https://cdn.klink.cloud/media-manager/your-image-url"
        }
    }
}
Modified at 2026-02-23 03:10:02
Previous
Get File By ID
Next
Update File
Built with