document

Since Kuzzle v1.0.0

Events triggered when a request is sent to the document controller.


document:after<Action>

Since Kuzzle v1.0.0

Event type: Pipe

Payload: a Request object

All actions in the document controller trigger this event after a successful execution. The <Action> part of the event name is replaced with the name of the action, where each word starts with a capital letter.

Example: after a successful create request, a document:afterCreate event is triggered.


document:before<Action>

Since Kuzzle v1.0.0

Event type: Pipe

Payload: a Request object

All actions in the document controllers trigger this event before execution. The <Action> part of the event name is replaced with the name of the action, where each word starts with a capital letter.

Example: before performing a get request, a document:beforeGet event is triggered.


document:error<Action>

Since Kuzzle v1.0.0

Event type: Pipe

Payload: a Request object

All actions in the document controllers trigger this event after a failed execution. The <Action> part of the event name is replaced with the name of the action, where each word starts with a capital letter.

Example: after a failed delete request, a document:errorDelete event is triggered.