drive2 feed

This commit is contained in:
Pan'kov Maksim
2025-09-13 00:18:39 +03:00
parent cca6e0547a
commit 029839154e
7 changed files with 465 additions and 0 deletions

View File

@@ -0,0 +1,12 @@
from fastapi import FastAPI, Response
from generator import generate
from cachetools import cached, TTLCache
import math
app = FastAPI()
@app.get("/")
@cached(cache=TTLCache(maxsize=math.inf, ttl=3600))
def read_root(url: str):
atom = generate(url)
return Response(content=atom, media_type='application/atom+xml; charset=utf-8')