Route parameter
A route parameter is a named variable embedded in a URL path whose value is captured from a matching request to identify or select a resource or operation.
The Design of Web APIs, Second Edition
A path parameter is a variable in a resource path that supplies an identifier or other value needed to identify the addressed resource.
- How it is used
- Identifies particular resources in request paths and distinguishes required identifiers from optional modifiers.
- How deep it goes
- Works through path selection, input placement, OpenAPI declaration, not-found handling, and compatibility; does not examine routing implementation internals.
- Examples
- Uses product URLs, category search filters, banking paths with globally unique or scoped IDs, and an OpenAPI parameter listing.
- What you can do after
- Build it from scratch: choose necessary path identifiers, separate filters into the query, and declare required parameters in OpenAPI.
Read how The Design of Web APIs, Second Edition explains route parameter →
Learn Go with Pocket-Sized Projects
A path parameter is a required value encoded as part of a URL path and used to identify or select a resource.
- How it is used
- Identifies individual games and habits in HTTP endpoint paths.
- How deep it goes
- Defines wildcards and query-parameter contrasts, then demonstrates route registration, value extraction, missing-value checks, and direct handler tests.
- Examples
- Uses game-status and habit-tick endpoints, including a handler test that supplies an ID with SetPathValue.
- What you can do after
- Apply it via Go's net/http to register parameterized routes, read identifiers, and test handlers.
Read how Learn Go with Pocket-Sized Projects explains route parameter →
ASP.NET Core in Action, 3e
A route parameter is a named variable embedded in a URL pattern whose value is extracted from a matching request path.
- How it is used
- Maps multiple request URLs to one endpoint while extracting variable path values for handler logic.
- How deep it goes
- Defines required, optional, and default parameters with examples, while deferring broader routing mechanics and syntax.
- Examples
- Uses a people-search API, product-category URLs, optional product identifiers, and Razor Page product paths.
- What you can do after
- Build it from scratch by declaring named URL variables and consuming their bound values in minimal API handlers.
Read how ASP.NET Core in Action, 3e explains route parameter →
Pro ASP.NET Core 7, Tenth Edition
A route segment variable is a named placeholder in a route pattern that captures a value supplied by a URL path segment.
- How it is used
- Uses named URL placeholders to pass path values from ASP.NET Core routing to endpoints.
- How deep it goes
- Works through route registration, value access, split-segment matching, and a matching pitfall without detailing the routing algorithm.
- Examples
- Tests three-segment paths, filename extensions, capital lookups, and product-ID URLs.
- What you can do after
- Apply it via ASP.NET Core routing to capture path values for endpoint logic and page or component parameters.
Read how Pro ASP.NET Core 7, Tenth Edition explains route parameter →
Pro Angular 16
A route parameter is a value supplied through a URL at runtime and made available to the route's navigation or component logic.
- How it is used
- Consolidates URLs for one component while passing values that select its behavior.
- How deep it goes
- Works through matching, named retrieval, input binding, and dynamic links without examining router internals.
- Examples
- Uses create-and-edit form URLs, an edit link containing a product ID, and administration routes with mode and ID parameters.
- What you can do after
- Apply it via Angular Router to consolidate routes, read URL values, and populate a form for a selected product.
Rust Servers, Services, and Apps
A URL path parameter is a variable value embedded in a URL path and supplied to the operation selected by that route.
- How it is used
- Uses URL segments to select resources and deliver typed identifiers to Actix handler functions.
- How deep it goes
- Explains route declarations, typed extraction, filtering, database calls, and manual tests, while deferring exhaustive success and failure coverage.
- Examples
- Uses `/courses/1`, `/courses/1/1`, tuple extraction, course filtering, tutor lookup, and Actix handler tests.
- What you can do after
- Apply via Actix by declaring typed path placeholders, extracting values, and passing them to filtering or database operations.
Read how Rust Servers, Services, and Apps explains route parameter →
Also covered in
- React Hooks in Action: With Suspense and Concurrent Mode
- Contract Testing in Action
- Vanilla WebIn early access (MEAP)
- Essential TypeScript 5, Third Edition
- Code Like a Pro in Rust
- Modern Angular
What to know first
- uriA URI (Uniform Resource Identifier) is a standardized sequence of characters that identifies an abstract or physical resource.
- JSONJSON is a language-independent text-based data-interchange format that represents structured values using objects, arrays, strings, numbers, booleans, and null.
- HTTP requestAn HTTP request is a message sent by a client to a server using the Hypertext Transfer Protocol, specifying a method and target and optionally including headers and a body.
- RESTREST is an architectural style for distributed systems that organizes interactions around identifiable resources and their representations, using a uniform interface and constraints such as statelessness and cacheability.
Related concepts
- url pathpart of · A URL path is the hierarchical component following the authority that identifies a resource or route within the addressed host.
- optional segmentincludes · An optional segment is a route-pattern segment that may be omitted while still allowing a URL to match the route.
- parametercontrasts with · A parameter is a value or named input that specifies or influences the behavior, computation, or output of a function, model, or system.
- bindToComponentInputsused by · bindToComponentInputs is an Angular router configuration option that binds route parameters, query parameters, and resolved data to matching component inputs.
- FromRoute attributeused by · The FromRoute attribute directs ASP.NET Core model binding to obtain a parameter or property value from route data.
Questions about route parameter
What is route parameter?
A route parameter is a named variable embedded in a URL path whose value is captured from a matching request to identify or select a resource or operation.
Which Manning books explain route parameter?
The Design of Web APIs, Second Edition, Learn Go with Pocket-Sized Projects, ASP.NET Core in Action, 3e, Pro ASP.NET Core 7, Tenth Edition, Pro Angular 16 and Rust Servers, Services, and Apps.
What should I know before learning route parameter?
Manning books that teach route parameter usually introduce uri, JSON, HTTP request and REST first.
What is the difference between route parameter and parameter?
A route parameter is a named variable embedded in a URL path whose value is captured from a matching request to identify or select a resource or operation. A parameter is a value or named input that specifies or influences the behavior, computation, or output of a function, model, or system.
What kinds of route parameter are there?
Kinds of route parameter include optional segment.
What is route parameter part of?
Route parameter is part of url path. A URL path is the hierarchical component following the authority that identifies a resource or route within the addressed host.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.





