ErrorCode: {
    allPredicatesFailed: "all_predicates_failed";
    alreadyExists: "already_exists";
    checkTokenError: "check_token_error";
    internalServerError: "internal_server_error";
    invalidAdapterModification: "invalid_adapter_modification";
    invalidApplyParameter: "invalid_apply_parameter";
    invalidExpandParameter: "invalid_expand_parameter";
    invalidFilterParameter: "invalid_filter_parameter";
    invalidOrderByParameter: "invalid_order_by_parameter";
    missAuthEncSignSecret: "miss_auth_enc_sign_secret";
    noPermission: "no_permission";
    notFound: "not_found";
    notFoundRoute: "route_not_found";
    oauthError: "oauth_error";
    parseTokenError: "parse_token_error";
    schemaMismatchError: "schema_mismatch_error";
    sendGridEmailError: "sendgrid_email_error";
    shortAuthEncSignSecret: "short_auth_enc_sign_secret";
    tokenFailsSecurityCheck: "token_fails_security_check";
    wrongParameter: "wrong_parameter";
} = BaseErrorCode

Type declaration

  • Readonly allPredicatesFailed: "all_predicates_failed"

    Occurs when a combination of multiple validators fails (e.g. when using security.some())

  • Readonly alreadyExists: "already_exists"

    Occurs when the given item already exists (fails uniqueness constraint)

  • Readonly checkTokenError: "check_token_error"

    Occurs when the wrong type of token is used for an authentication method

  • Readonly internalServerError: "internal_server_error"

    Generic 500 error (e.g. DB error or similar)

  • Readonly invalidAdapterModification: "invalid_adapter_modification"

    Occurs when adapter modification cannot be performed

  • Readonly invalidApplyParameter: "invalid_apply_parameter"

    Occurs when using the $apply param incorrectly

  • Readonly invalidExpandParameter: "invalid_expand_parameter"

    Occurs when using the $expand param incorrectly

  • Readonly invalidFilterParameter: "invalid_filter_parameter"

    Occurs when using the $filter param incorrectly

  • Readonly invalidOrderByParameter: "invalid_order_by_parameter"

    Occurs when using the $orderBy param incorrectly

  • Readonly missAuthEncSignSecret: "miss_auth_enc_sign_secret"

    Occurs when auth secret environment variables have not been provided

  • Readonly noPermission: "no_permission"

    Generic 403 error: You do not have permission over the given resource

  • Readonly notFound: "not_found"

    Generic 404 error: Item not found/does not exist in DB

  • Readonly notFoundRoute: "route_not_found"

    404 error: Route/method not found

  • Readonly oauthError: "oauth_error"

    Generic oauth error

  • Readonly parseTokenError: "parse_token_error"

    Occurs when the given token could not be parsed (e.g. invalid format)

  • Readonly schemaMismatchError: "schema_mismatch_error"

    Occurs when a schema validation does not match the given request/response

  • Readonly sendGridEmailError: "sendgrid_email_error"

    Occurs when an email fails to send using SendGrid

  • Readonly shortAuthEncSignSecret: "short_auth_enc_sign_secret"

    Occurs when auth secret environment variables are not long enough to be secure

  • Readonly tokenFailsSecurityCheck: "token_fails_security_check"

    Occurs when the given token is valid, but fails security checks (e.g. IP address mismatch, user agent mismatch)

  • Readonly wrongParameter: "wrong_parameter"

    Generic 400 error: Incorrect parameter provided

Deprecated

Use BaseErrorCode

Generated using TypeDoc