Overview
TheRouting type defines the URL structure of your API by mapping paths to endpoints.
Routing Syntax
Nested Objects
Flat Paths
Path Parameters
Method-Based Routing
Explicit Method in Path
Static File Serving
Complex Example
Endpoint Nesting
Endpoints can handle both their own path and sub-paths:See Also
Routing Concept
Routing patterns and best practices
createServer
Start server with routing