from fastapi import FastAPI import utils app = FastAPI() @app.get("/video") def get_video(channel_name: str): uploads = utils.get_uploads_playlist(channel_name) videos = utils.get_all_videos(uploads) return { "id": videos[0] }