benji-knu0mt/endpoints/email.delete.py
2025-04-19 03:48:05 +00:00

14 lines
573 B
Python

# Simplified DELETE template
from fastapi import APIRouter, Depends, HTTPException, status
router = APIRouter()
@router.delete("/email", status_code=status.HTTP_204_NO_CONTENT) # Operates on the base path
async def delete_email( # Function name reflects resource (plural)
# db: Session = Depends(get_db) # Example dependency
):
"""Endpoints for email: Delete resource(s)"""
# TODO: Implement logic to delete email (e.g., clear collection or delete specific item based on criteria?)
print(f"Deleting email")
return None # Return No Content on success