# Douyin Account collections API (douyin.user_mixes)

- Canonical page: [https://everyinfra.com/en/douyin-api/user_mixes](https://everyinfra.com/en/douyin-api/user_mixes?utm_medium=ai_doc&utm_campaign=page_md)
- Endpoint: POST https://api.everyinfra.com/api/v1/social with {"platform": "douyin", "action": "user_mixes", "params": {...}}
- Price: $0.000792 per call ($0.79 per 1,000 requests); failed calls and empty results are not charged
- Returns: list, one page of up to 20 per call; the number of rows varies from page to page and a short page is not the end (limit is ignored; pass the top-level next_page_token from the response as page_token for the next page; no next_page_token means the end)
- Pagination: pass next_page_token back as page_token for the next page, other params unchanged; one call per page, tokens last 24 hours
- Mode: sync; add "mode": "async" for slow tasks

## Health

- Live health (24h percent, hourly and daily trends): https://api.everyinfra.com/api/v1/social/availability?platform=douyin&action=user_mixes

## Parameters

| name | type | required | default | description |
|---|---|---|---|---|
| user_id | not declared | yes | not declared | The account whose collections you want: its `secUid` (starting `MS4w`) or a profile link `https://www.douyin.com/user/<secUid>`. Nicknames, Douyin IDs and short links are not accepted. |
| page_token | not declared | no | not declared | Page token for `user_mixes`. Leave it out for the first page, then pass back the previous response's `next_page_token` exactly as received, keeping `user_id` unchanged. Tokens last 24 hours; the last page has no `next_page_token`. A page holds up to 20 collections. |

## Response fields (items in `results`)

| field | meaning |
|---|---|
| mix_id | Douyin collection ID (`user_mixes`). Pass it as `mix_id` to `mix_posts` to list the collection's videos. |
| name | Name of the collection (`user_mixes`). |
| description | Description of the collection (`user_mixes`). |
| url | Link to the record on the platform. |
| cover_image_url | Cover image URL: the cover of a video or image post on search, user_posts, posts_batch, related_posts, mix_posts, music_posts and media_links rows; the music cover on music_search and music_detail; the topic image on billboard_topic_hot; the collection cover on user_mixes; the room cover on live_room. Signed links expire. |
| author_id | Author's unique ID on the platform. |
| author_name | Author's display name. |
| episode_count | How many episodes the collection has (`user_mixes`). |
| play_count | Real only on Hot Spot Treasure and mixes. On the boards billboard_video_hot, billboard_low_fan_explosion and billboard_high_completion it is Douyin's own play figure. On mix_posts it is the plays of that episode, and on user_mixes the plays of the whole collection. Elsewhere Douyin does not publish play counts, so the value is usually 0 and does not reflect real plays; judge reach by likes, comments and shares. |
| created_at | Creation time, same format as posted_at. |
| updated_at | When the collection was last updated (`user_mixes`, ISO 8601, UTC). |
| mix_count | How many collections the account has in all (`user_mixes`); the same on every row. Some accounts return fewer collections than this. |
| platform | Source platform identifier, the same as platform in the request (for example xiaohongshu, tiktok). |

## Example

```bash
curl -X POST 'https://api.everyinfra.com/api/v1/social' \
  -H "Authorization: Bearer $EVERYINFRA_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "platform": "douyin",
  "action": "user_mixes",
  "params": {
    "user_id": "https://www.douyin.com/user/MS4wLjABAAAAk1tZ-L085zZf2yW_H5dnVFZWyk8Rt8v4RAvf9KhTyPoVdMDxTs7Q_rvgTJGWXezS"
  }
}'
```

```python
import os
import requests

response = requests.post(
    "https://api.everyinfra.com/api/v1/social",
    headers={"Authorization": f"Bearer {os.environ['EVERYINFRA_API_KEY']}"},
    json={
        "platform": "douyin",
        "action": "user_mixes",
        "params": {
            "user_id": "https://www.douyin.com/user/MS4wLjABAAAAk1tZ-L085zZf2yW_H5dnVFZWyk8Rt8v4RAvf9KhTyPoVdMDxTs7Q_rvgTJGWXezS",
        },
    },
    timeout=120,
)
print(response.status_code)
print(response.json())
```

## Response example

No real sample for these example parameters yet: structure only, every value is a placeholder (…).

```text
{
  "id": "req_…",
  "platform": "douyin",
  "action": "user_mixes",
  "results": [
    {
      "mix_id": …,
      "name": …,
      "description": …,
      "url": …,
      "cover_image_url": …,
      "author_id": …,
      "author_name": …,
      "episode_count": …,
      "play_count": …,
      "created_at": …,
      "updated_at": …,
      "mix_count": …,
      "platform": …
    }
  ],
  "next_page_token": …,
  "pagination": { … },
  "count": …,
  "billing": {
    "charged": …,
    "charged_usd": …,
    "balance_after_usd": …,
    …
  },
  "quota": { … }
}
```

## Also

- Capability catalog (no key): https://api.everyinfra.com/api/v1/social/catalog?platform=douyin
- OpenAPI: https://everyinfra.com/openapi.json · Agents guide: https://everyinfra.com/agents.md
