A response that can be sent back to the H5P client when something went wrong.

Implements

Constructors

  • Parameters

    • errorCode: string

      an error code that can be understood by the H5P client

    • httpStatusCode: number

      the HTTP status code

    • message: string

      The message displayed to the user. Should be localized if possible.

    • Optionaldetails: string

      (optional) Further text displayed to the user. Should be localized if possible.

    Returns AjaxErrorResponse

Properties

details?: string

(optional) Further text displayed to the user. Should be localized if possible.

errorCode: string

an error code that can be understood by the H5P client

httpStatusCode: number

the HTTP status code

message: string

The message displayed to the user. Should be localized if possible.

success: boolean = false

True if the request was successful, false if something went wrong (errorCode and message should be filled in then).