# Music

> A sound or song short videos use: title, artist, length, cover, audio link and how many posts use it.

Canonical page: https://okdata.online/docs/objects/music/

The same shape on every platform. A field a platform does not have is null, and meta.unavailable says why. Use fields= to keep only what you need.

| Field | Type | Description |
|---|---|---|
| `id` | string | The music ID; douyin.music.get takes it. |
| `url` | string \| null | The music's page on the platform. |
| `title` | string | Title, as the platform shows it. |
| `artist` | string \| null | Who it is credited to: the singer, or the account an original sound comes from. |
| `album` | string \| null | Album, where given. |
| `duration_seconds` | integer \| null | Duración en segundos. |
| `cover_url` | string \| null | Cover image; the link expires in hours. |
| `audio_url` | string \| null | The audio file; the link expires in hours, so download it soon. |
| `uses` | integer \| null | Posts made with it, as the platform counts them. |
| `original` | boolean \| null | true: an original sound from a user's own video; false: a licensed track. |
| `ext` | object | Datos adicionales propios de la plataforma. Solo se devuelven con view=full. |

## Endpoints that return a Music

- [Douyin music search](https://okdata.online/apis/douyin/music/search/) (`douyin.music.search`): $0.02 per call · about 10 results per page
- [Douyin music detail](https://okdata.online/apis/douyin/music/get/) (`douyin.music.get`): $0.002 per call

## Fields by view

Each view includes the fields of the views above it. `view=compact` is the smallest; `full` adds platform extras under `ext`.

- compact: `id`, `url`, `title`, `artist`, `duration_seconds`, `uses`, `original`
- standard: `album`, `cover_url`, `audio_url`
- full: `ext`
