Blueprint
  • Blueprint Developer Guide
  • Quick Start
    • Getting Started
    • My First Application
      • Creating Your Application
      • Controllers
      • Routers & Routes
      • Services
      • Resources & Resource Controllers
      • Validating & Sanitizing Input
      • Unit Testing Your Application
      • Policies
  • Developer Guide
    • The Object Model
      • Introduction
      • Classes and Instances
      • Computed Properties
      • Aggregated Properties
      • Mixins
    • Routers and Controllers
      • Introduction
      • Routers
      • Controllers
      • Resources
    • Models
    • The Server
    • Policy Framework
    • Services
    • Messaging Framework
    • Configuration Management
    • Application and Resources
      • Lookup Operation
      • Views
      • Assets
    • Blueprint Modules
    • Blueprint Cluster
      • What is a Blueprint Cluster?
      • Running a Blueprint Cluster
      • Technical Details
    • Testing Framework
    • Command-line Interface (Coming Soon)
Powered by GitBook
On this page
  1. Developer Guide
  2. Routers and Controllers

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.

PreviousRouters and ControllersNextRouters

Last updated 7 years ago