import os from datetime import datetime, timezone from fastapi import APIRouter, HTTPException, Request from fastapi.responses import HTMLResponse from pydantic import BaseModel from sqlmodel import select from ..wallet import get_balance, send_token from .db import ApiKey, create_session admin_router = APIRouter(prefix="/admin", include_in_schema=False) class WithdrawRequest(BaseModel): amount: int def login_form() -> str: return """
""" def info(content: str) -> str: return f"""Your Balance: {owner_balance} sats
The balance is calculated by subtracting the combined user balance from the total Cashu wallet balance.
Total Cashu Balance: {current_balance} sats
User Balance: {total_user_balance} sats
Save this token! It represents your withdrawn balance.
| Hashed Key | Balance (mSats) | Total Spent (mSats) | Total Requests | Refund Address | Refund Time |
|---|