mickeyf.docs
    Preparing search index...

    Type Alias ApiError

    Error response shape shared by multiple operations.

    Status vs body:

    • Many handlers return { error: ... } without success: false.
    • Some handlers include a status field in the JSON body (e.g. DUPLICATE_USER uses status: 409) without necessarily setting the HTTP status code.
    • Other handlers set real HTTP statuses (e.g. UNAUTHORIZED uses HTTP 401; SERVER_ERROR may use HTTP 500).
    type ApiError = {
        error: ApiErrorCode;
        message?: string;
        status?: number;
        success?: false;
    }
    Index

    Properties

    message?: string
    status?: number
    success?: false