KnightBot API Documentation
Everything you need to call the KnightBot API.
Introduction
A public REST API for media downloads, AI chat, lyrics, screenshots, speech, QR codes, image cards and image effects. Every endpoint is a plain GET request. Downloaders return JSON; card and image-effect routes return a PNG by default.
https://knightbotapi.streamQuick start
Send one request with your key.
Authentication
Pass your key on every request, either way works.
?apikey=knightX-API-Key: knight401403Responses
Check for HTTP 200 and success: true, then use result.
{
"success": true,
"result": { "download": "/files/a1b2.mp4" }
}Universal download
One route for any supported link: /api/download?url=…&type=mp3|mp4. The six main sites use their own fast downloaders; every other supported site is handled automatically. SoundCloud, Mixcloud and Bandcamp always return MP3. Same limits as YouTube: max 10 minutes and 100MB. Direct file links and unknown sites return 400.
https://youtu.be/DTbfw8_SMmI?si=YPUgUhtZSSYvdZ27https://vt.tiktok.com/ZSbF9V9Eh/https://www.instagram.com/reel/DdviNYUpmsw/https://www.facebook.com/share/r/19axMcades/https://x.com/WholesomeMeme/status/2107101246687461385https://pin.it/<id>https://soundcloud.com/forss/flickermoodhttps://www.reddit.com/r/<sub>/comments/<id>/<title>/https://clips.twitch.tv/<clip-slug>https://vimeo.com/<id>https://www.dailymotion.com/video/<id>https://www.bilibili.com/video/BV<id>https://bsky.app/profile/<user>/post/<id>https://www.snapchat.com/spotlight/<id>https://<user>.tumblr.com/post/<id>https://streamable.com/<id>https://www.mixcloud.com/<user>/<show>/https://<artist>.bandcamp.com/track/<track>https://likee.video/@<user>/video/<id>https://www.douyin.com/video/<id>https://9gag.com/gag/<id>https://imgur.com/<id>https://www.linkedin.com/posts/<post-slug>https://drive.google.com/file/d/<id>/viewPlus 1000+ more sites.
Image cards
Card routes render PNG on the server (Satori). Default response is the image itself so a bot can send the URL as a photo. Add json=1 for the usual { success, result.download } (file expires in 5 minutes).
/api/card/welcome · name, group, pic, count, theme=aurora neon ticket split royal comic ocean light/api/card/goodbye · same params & themes as welcome/api/card/rank · xp / needed progress bar/api/card/quote · Hindi/Hinglish via Noto Devanagari/api/card/wanted · photo, crime, reward/api/card/jail · photo, crime, sentence, cell, number/api/yt/card?url= · now-playing card/api/fake/tweet · /api/fake/ytcommentImage effects
All routes need a public url. PNG by default (max 8MB / 40MP in). Add json=1 for { success, result.download }. ascii and colors always return JSON. Upscale is lanczos resize, not AI.
/api/img/blur · level 1–100/api/img/pixelate · size 2–100/api/img/grayscale/api/img/circle · size 64–2048/api/img/upscale · scale 2–4, max 4096px/api/img/meme · top, bottom/api/img/ascii · width 20–160 · JSON/api/img/colors · count 2–12 · hex / rgb / percent JSON/api/img/removebg · first call downloads the model and can be slowLimits & files
- Per-key minute / hour / day caps return
429. - Check
/api/usage?apikey=…any time. - Hosted files under
/files/expire after 5 minutes. - Free YouTube: max 10 minutes, 100MB, and up to 720p. 1080p / best need a premium / custom key.
Status codes
FAQ
Which HTTP methods are supported?
GET only.
How long can an AI prompt be?
The q parameter is limited to 800 characters.
My download link stopped working
Hosted files expire after 5 minutes. Request it again.