---
title: "Step 2 of an upload: register the uploaded object as an asset."
method: POST
path: "/v1/media"
tags: ["Media"]
---

# Step 2 of an upload: register the uploaded object as an asset.

`POST /v1/media`

## Request

- Base URL: `https://api.ravenpo.st`
- URL: `https://api.ravenpo.st/v1/media`
- Auth: HTTP bearer

Returns the asset `id` to put in `mediaIds`.

## Request body

- object
  - `type` string, required: Asset kind.
  - `storageKey` string, required: From the presign response.
  - `url` string, required: Public URL, from the presign response.
  - `mimeType` string: Recorded for the per-platform compatibility check.
  - `width` number: Pixels.
  - `height` number: Pixels.
  - `durationSec` number: Video length.
  - `sizeBytes` number: File size, checked against each platform’s cap.

## Response `200`

Success

## Other responses

- `401`: Missing, malformed or revoked token
- `429`: Rate limited (120 requests/minute)

---

[API](https://skmtc.dev/ravenpo/apis/ravenpost-api.md) · [All operations](https://skmtc.dev/ravenpo/apis/ravenpost-api/llms.txt) · [OpenAPI document](https://skmtc.dev/ravenpo/apis/ravenpost-api/revisions/82905d43e21d?raw)
