13 lines
363 B
Python
13 lines
363 B
Python
from __future__ import annotations
|
|
|
|
from fastapi import APIRouter, Query
|
|
from typing import List, Dict, Any
|
|
|
|
from app.services.decisions import store
|
|
|
|
router = APIRouter(prefix="/decisions", tags=["Decisions"])
|
|
|
|
|
|
@router.get("/latest")
|
|
async def latest_decisions(limit: int = Query(20, ge=1, le=100)) -> List[Dict[str, Any]]:
|
|
return store.latest(limit=limit) |