https://github.com/n-ce/xtractify
Simply fast yt-dlp api using Sanic.
https://github.com/n-ce/xtractify
api bottlepy extractor python sanic yt-dlp
Last synced: about 1 year ago
JSON representation
Simply fast yt-dlp api using Sanic.
- Host: GitHub
- URL: https://github.com/n-ce/xtractify
- Owner: n-ce
- Created: 2022-12-18T18:04:08.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-04-13T07:36:01.000Z (about 2 years ago)
- Last Synced: 2024-04-23T21:29:46.843Z (about 2 years ago)
- Topics: api, bottlepy, extractor, python, sanic, yt-dlp
- Language: Python
- Homepage: https://xtractify.onrender.com
- Size: 10.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Xtractify Reborn
- Reborn with Sanic, with
- **17.5x** more requests per second
- **15x** lesser latency on average compared to bottle.py.
- zero dependencies, well technically sanic & yt-dlp are still required.
#### [`main.py`](https://github.com/n-ce/xtractify/blob/main/main.py)
```py
from sanic import Sanic,text
from yt_dlp import YoutubeDL
app = Sanic('xtractify')
@app.get('/')
async def index(request):
return text('/uid/itag')
@app.get('//')
async def main(request,id,itag):
ydl = YoutubeDL({'format': itag}).extract_info('https://youtu.be/'+id, download=False)
if ydl :
return text(ydl['url'])
```
Thanks to render for hosting the web service.