API ReferenceMedia
Complete a direct binary upload
Call after the PUT succeeds. Records the real file size, consumes the upload quota, and queues thumbnail generation. The asset is unusable in posts until completed.
Authorization
api-key AuthorizationBearer <token>
Workspace API key (nim_live_...)
In: header
Path Parameters
id*string
mediaId from createMediaUpload
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://example.com/v1/media/uploads/string/complete" \ -H "Content-Type: application/json" \ -d '{ "sizeBytes": 10485760 }'{ "id": "123e4567-e89b-12d3-a456-426614174000", "name": "launch-banner.png", "type": "IMAGE", "url": "string", "thumbnailUrl": {}, "size": 245760, "createdAt": "2026-07-05T10:00:00.000Z"}Empty