Comment on page
Request & Response Objects
Request and Response objects are available to the controller as
request and responsemethods.
The request object contains a lot of useful information about the request coming in from the client. To get a full list of the available methods, refer to the Crystal API Documentation https://crystal-lang.org/api/latest/HTTP/Request.html
The response object is not usually used directly, but is built up during the execution of the action and rendering of the data that is being sent back to the user, but sometimes - like in an after filter - it can be useful to access the response directly. Some of these accessor methods also have setters, allowing you to change their values. To get a full list of the available methods, refer to the https://crystal-lang.org/api/latest/HTTP/Server/Response.html