# TikTok Media API Reference

Canonical: https://monsterapi.co/docs/api/tiktok-media

Read the TikTok Media reference. Review parameters, response fields, examples, and current credit prices.

OpenAPI specification: [TikTok](https://monsterapi.co/docs/openapi/platforms/tiktok.yaml).

---

Current operation prices: [public catalog](https://monsterapi.co/account/api/v1/public/api-prices). Prices use credits per request.

---

# TikTok: Media bytes and metadata

`GET /tiktok/api/web/video/cdn`

Documentation: https://monsterapi.co/docs/api/tiktok#tiktok-media-bytes-and-metadata

Operation ID: `tiktok_web_cdn`

Returns up to 1024 media bytes beginning at byte 0, plus metadata, for an HTTPS TikTok media URL.

## Authentication

Send your billing API key in the `Authorization: Bearer <YOUR_API_KEY>` header. Your account login is separate.

## Inputs

- `url` (query, required): Required HTTPS media URL at the exact host `v16-webapp-prime.tiktok.com`, `v16-webapp-prime.us.tiktok.com`, or one of these hosts or a subdomain: `tiktokcdn.com`, `tiktokcdn-us.com`, `tiktokcdn-eu.com`, `byteoversea.com`, `ibytedtos.com`, `ibyteimg.com`, `tiktokv.com`, `tiktokv.us`. Limit: 2048 UTF-8 bytes; no credentials, nondefault port or fragment. The returned media URL must satisfy these host restrictions. Use `named.posts[].media_url` from [GET /web/item/detail](https://monsterapi.co/docs/api/tiktok-publications#tiktok-publication-details).

## Responses

- 200: Public TikTok data

- 400: Invalid subject, query value or cursor

Refused at the gateway: the request target, path and query string together, is longer than 8,192 bytes; or the headers, the target counted among them, exceed 16,384 bytes or 64 fields

- 401: #/components/responses/GatewayUnauthorized

- 402: #/components/responses/GatewayPaymentRequired

- 403: Resource is private or unavailable

Refused at the gateway: the API key is unknown or revoked

- 404: Resource is absent or final page is empty

- 405: `method_not_allowed`: the endpoint answers GET alone, and any other method, HEAD included, is refused

Refused at the gateway: the path exists, but no operation on it takes the method of the request, HEAD included; `Allow` names the methods that do

- 409: #/components/responses/GatewayConflict

- 429: #/components/responses/GatewayTooManyRequests

- 500: Response structure is unavailable

- 501: Resource requires authentication

- 503: Temporary TikTok or service refusal

Refused at the gateway: the check could not complete, the account is suspended, or the platform did not answer; each may pass later, and `Retry-After` comes only when the platform did not answer

## Credits

Check the live price in the documentation before sending. Platform 2xx and 4xx responses can use credits, including empty data. Gateway refusals and 5xx responses do not use credits. Each pagination request is a separate call.

https://monsterapi.co/docs/pricing

## Request template

Replace path placeholders and add the required query parameters from the Inputs section before sending.

```shell

curl --get 'https://api.monsterapi.co/tiktok/api/web/video/cdn' \
  -H 'Authorization: Bearer <YOUR_API_KEY>'

```
