Introduction

Brief discussion about the role of routers and controllers

Routers and controllers are considered the foundational building blocks of a Blueprint application. A controller is an application entity that provides the execution logic for different facets of the Blueprint application via actions. Each action in a controller is responsible for handling a request, which can include validating and sanitizing the request input, processing the request, and sending a response to the request.

A controller is an application entity that provides the execution logic for different facets of the Blueprint application via actions.

Routers are the main access point to the Blueprint application. The router exposes the public facing interface (or application programming interface) via paths (or urls). For example, /messages is a path exposed by a router that clients can invoke.

Routers are the main access point to the Blueprint application.

Each path in a router is connected to a single action on a controller. We call this a route.

Last updated