[]previous and next page

Request ids and unsupported methods

Request ids and unsupported methods in the Configuration with dusk.config.ts guide.

For agentsUpdated
  • security.requestId controls x-request-id on every answer, including the OPTIONS, 404 and 405 answers. true (default) sends the request id. false omits the header. A header a route or the handler sets is kept. In dusk.config.ts the value is true or false; a function ((event) => string) is passed to createHandler in the server entry, because the config file is written into the server bundle.
  • security.methodNotAllowed chooses the 405 answer. "json" (default) is the error body. "empty" is an empty 405 with no body and no content type. Allow is sent in both shapes.