The options to construct the service.
Protected
Readonly
_configThe application configuration, to get the version
and the postMessagesPrefix
.
Protected
Readonly
_statusesThe uility service to get HTTP status codes.
Protected
_htmlProtected
_normalizeUtility method used to make sure a recevied status is a valid status code. If the
status is a string, the method will try to find the code from the statuses
package.
The status to normalize.
If status
is a string, but there's no valid code, it will return 200.
Generates and send an HTML response that emits a post message.
The post message will be prefixed with the value of the configuration setting
postMessagesPrefix
.
The options to customize how the HTML is generated.
Generates and sends a JSON response.
The options to customize how the JSON is generated.
A utility service to build responses.