You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 53ed80d
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: docs/book/v7/commands/display-available-endpoints.md
+52-44Lines changed: 52 additions & 44 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
## Summary
4
4
5
-
The `route:list` CLI command inspects the application's routes at runtime and prints every endpoint's request method, route name and path.
5
+
The `route:list` CLI command inspects the application's routes at runtime and prints a numbered table of every endpoint's request method, route name and path.
6
6
Results can be filtered by name, path or method.
7
7
8
8
## Usage
@@ -14,51 +14,54 @@ php ./bin/cli.php route:list
14
14
```
15
15
16
16
The command runs through all routes and extracts endpoint information in realtime.
17
+
Rows are sorted by path, then by request method, and UUID route parameters are shown as `{id}` rather than the full regular expression they are declared with.
18
+
The count in the table header reflects method/path pairs, so a path answering three methods contributes three rows.
@@ -69,7 +72,11 @@ The following filters can be applied when displaying the route list:
69
72
* Filter routes by path, using: `-p|--path[=PATH]`
70
73
* Filter routes by method, using: `-m|--method[=METHOD]`
71
74
72
-
The filters are case-insensitive and can be combined.
75
+
The filters are matched as case-sensitive substrings and can be combined.
76
+
For example, `php ./bin/cli.php route:list -i avatar` lists only the six avatar routes, and adding `-m GET` narrows that to two.
77
+
78
+
> Case matters.
79
+
> Route names and paths are lowercase and methods are uppercase, so `-i avatar` and `-m GET` match, while `-i Avatar` and `-m get` match nothing and print an empty table.
73
80
74
81
Get more help by running this command:
75
82
@@ -86,7 +93,8 @@ A: No. The command walks the application's registered routes in realtime, so it
86
93
**Q: Which filters are available?**
87
94
88
95
A: `-i|--name`, `-p|--path` and `-m|--method`.
89
-
They are case-insensitive and can be combined.
96
+
Each is a case-sensitive substring match, and they can be combined.
97
+
Use lowercase for names and paths and uppercase for methods — `-m get` matches nothing.
90
98
91
99
**Q: Why do route names matter beyond documentation?**
0 commit comments