> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aigenda.tech/llms.txt
> Use this file to discover all available pages before exploring further.

# Загрузка с YouTube

> Обработка видео с YouTube по ссылке.

Передайте ссылку на видео, AiGenda скачает звуковую дорожку сама.

```bash theme={null}
curl -X POST https://api.aigenda.tech/api/spaces/1024/audio/by_youtube/ \
  -H "Authorization: Bearer <access>" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://www.youtube.com/watch?v=VIDEO_ID"}'
```

| Поле | Правило |
| - | - |
| `url` | Ссылка на видео YouTube, до 2048 символов. Видео должно открываться без входа в аккаунт |

## Что дальше

Как и при [загрузке по ссылке](/upload/url), файл скачивается после ответа:

1. Возьмите `id` записи из ответа.
2. Опрашивайте [`info/`](/api-reference/audio/info), пока не придёт `is_uploaded: true`. Длинное видео скачивается дольше.
3. Запустите [обработку](/processing/start).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.