Controller #
Available since 2.8.0
The Controller abstract class is the base class used to declare new controllers. Those controllers instances are meant to be used with the BackendController.use method.
See also the API Controllers guide.
app #
| Type | Description |
|---|---|
Backend | Reference to the instantiated Backend class |
sdk #
This property is an instance of the EmbeddedSDK class that allows to interact with the Kuzzle API.
| Type | Description |
|---|---|
EmbeddedSDK | EmbeddedSDK instance |
See also the Embedded SDK guide.
name #
| Type | Description |
|---|---|
string | Optional controller name. It will be inferred from the class name if not set |
definition #
This property defines the controller actions: their handlers and, optionally, their HTTP routes and OpenAPI specification.
| Type | Description |
|---|---|
ControllerDefinition | A valid ControllerDefinition object defining the controller actions list. |