dev-api
БесплатноЗапускает вложенные скриптыНе проверенUse, test, and integrate against the MediaCMS REST API v1 — media listing/upload/edit/delete, actions, bulk actions, comments, playlists, categories, tags…
от greedychipmunk★ 24 звезды на GitHubОб этом скилле
MediaCMS REST API
Scope: targets mediacms-io/mediacms v9.6.1 (commit
99a1801, branchmain). Endpoints resolve at the site root of a running installation.
Authentication
Three interchangeable schemes:
- Session — log in through the UI, reuse the cookie
- HTTP Basic — works on all API views (
Authorization: Basic base64(user:pass)) - DRF token —
GET /api/v1/user/tokenwith Basic auth returns{"token": "..."}; then sendAuthorization: Token <token>
GET /api/v1/whoami (Basic auth) returns the authenticated user — the quickest credential check.
Endpoint map
| Endpoint | Methods | Notes |
|---|---|---|
/api/v1/media |
GET, POST | GET list (page, author, `show=recommended |
/api/v1/media/{friendly_token} |
GET, POST, PUT, DELETE | Detail; POST/PUT edit metadata, DELETE removes |
/api/v1/media/{token}/actions |
POST | {"type": "like"|"dislike"|"report"|"feature", ...} |
/api/v1/media/user/bulk_actions |
POST | media_ids + action (playlist/category/tags/state/owner/ownership) |
/api/v1/media/{token}/comments |
GET, POST | Comment list/create |
/api/v1/media/{token}/chapters |
POST | Video chapters |
/api/v1/media/{token}/trim_video |
POST | Requires ALLOW_VIDEO_TRIMMER |
/api/v1/media/{token}/pdf |
GET | PDF viewer |
/api/v1/search |
GET | Search media |
/api/v1/categories, /api/v1/categories/{uid} |
GET | contributor variant lists RBAC-editable ones |
/api/v1/tags, /api/v1/comments, /api/v1/playlists |
GET | Listings |
/api/v1/playlists/{friendly_token} |
GET, POST | Playlist detail/edit |
/api/v1/user/action/{action} |
POST | User actions |
/api/v1/users, /api/v1/users/{username} |
GET | User list/detail |
/api/v1/whoami, /api/v1/user/token, /api/v1/login |
GET/POST | Auth helpers |
/api/v1/encode_profiles/ |
GET | Active encode profiles |
/api/v1/tasks, /api/v1/tasks/{token} |
GET | Encoding task status |
| `/api/v1/manage_media | manage_comments | manage_users` |
/api/v1/media-auth |
GET | Protected-media auth handshake (nginx X-Accel) |
/api/v1/migrations |
GET, POST | Migration jobs (superuser; skill migrations) |
Full parameter details: references/endpoints.md. Upload and action payloads: references/upload-and-actions.md.
Upload essentials
curl -u user:pass -F [email protected] -F title="Title" \
-F description="Desc" http://localhost/api/v1/media
- Multipart POST with
media_fileplus optionaltitle,description,new_tags(comma list),category_uids/category_titles,state(public/private/unlisted),license - Response contains
friendly_token; encoding runs asynchronously — pollencoding_statuson the detail endpoint or/api/v1/tasks/{friendly_token} - Gated by
CAN_ADD_MEDIA/UPLOAD_MEDIA_ALLOWEDsettings (skillportal-configuration) - Chunked uploads (Fine Uploader) happen through
/fu/endpoints — the browser flow, not the REST API
Schema and tooling
- Swagger UI:
/swagger— schema:/swagger.json(drf-yasg) - Browsable API login:
/api-auth/ - Bundled client:
cli-tool/cli.py(login,whoami; own venv +pip install -r cli-tool/requirements.txt,.envincli-tool/)
Smoke-testing a live instance
python scripts/api_smoke.py --base-url http://localhost --user admin --password admin
python scripts/api_smoke.py --base-url http://localhost --user admin --password admin \
--upload-file sample.mp4 # adds upload → detail → delete round-trip
Stdlib-only (no requests); exits non-zero on any failed check. Auth-less runs test only the anonymous endpoints. See tests/test_api_smoke.py for offline coverage of request building and response classification.
Additional resources
files/urls.py,users/urls.py,migrationservice/urls.py(upstream route sources)- Skills:
rbac-permissions(401/403 causes),media-pipeline(encoding statuses),migrations
Установить dev-api в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл dev-api?
Use, test, and integrate against the MediaCMS REST API v1 — media listing/upload/edit/delete, actions, bulk actions, comments, playlists, categories, tags, search, users, encode profiles, and migrations endpoints. Use when scripting uploads or metadata updates, authenticating (session, HTTP Basic, or DRF token), debugging 401/403 permission errors, reading Swagger schemas, or using the bundled cli-tool.
Как установить скилл dev-api?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл dev-api запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic