File size: 325 Bytes
a5a6006
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
from enum import Flag

class ErrorCodes(Flag):
    INTERNAL_SERVER_ERROR = (500, "internal server error")
    REQUEST_VALIDATION_ERROR = (400, "request validation error")
    JWT_VALIDATION_ERROR = (401, "jwt validation error")
    TEXT_VALIDATION_ERROR = (490, "text validation error")
    OTHER_ERROR = (999, "other error")