3 use Friendica\App\Router as R;
7 * Configuration for the default routes in Friendica
10 * - 'route' => [ Module::class , [ HTTPMethod(s) ] ]
11 * - 'group' => [ 'route' => [ Module::class, [ HTTPMethod(s) ] ]
13 * It's possible to create recursive groups
16 '/' => [Module\Home::class, [R::GET]],
19 '/host-meta' => [Module\WellKnown\HostMeta::class, [R::GET]],
20 '/nodeinfo' => [Module\WellKnown\NodeInfo::class, [R::GET]],
21 '/webfinger' => [Module\Xrd::class, [R::GET]],
22 '/x-social-relay' => [Module\WellKnown\XSocialRelay::class, [R::GET]],
26 '[/]' => [Module\Security\TwoFactor\Verify::class, [R::GET, R::POST]],
27 '/recovery' => [Module\Security\TwoFactor\Recovery::class, [R::GET, R::POST]],
32 '/custom_emojis' => [Module\Api\Mastodon\CustomEmojis::class, [R::GET ]],
33 '/follow_requests' => [Module\Api\Mastodon\FollowRequests::class, [R::GET ]],
34 '/follow_requests/{id:\d+}/{action}' => [Module\Api\Mastodon\FollowRequests::class, [ R::POST]],
35 '/instance' => [Module\Api\Mastodon\Instance::class, [R::GET ]],
36 '/instance/peers' => [Module\Api\Mastodon\Instance\Peers::class, [R::GET ]],
39 '/profile/show' => [Module\Api\Friendica\Profile\Show::class , [R::GET ]],
44 '[/]' => [Module\Admin\Summary::class, [R::GET]],
46 '/addons' => [Module\Admin\Addons\Index::class, [R::GET, R::POST]],
47 '/addons/{addon}' => [Module\Admin\Addons\Details::class, [R::GET, R::POST]],
50 '/blocklist/contact' => [Module\Admin\Blocklist\Contact::class, [R::GET, R::POST]],
51 '/blocklist/server' => [Module\Admin\Blocklist\Server::class, [R::GET, R::POST]],
53 '/dbsync[/check]' => [Module\Admin\DBSync::class, [R::GET]],
54 '/dbsync/{update:\d+}' => [Module\Admin\DBSync::class, [R::GET]],
55 '/dbsync/mark/{update:\d+}' => [Module\Admin\DBSync::class, [R::GET]],
57 '/features' => [Module\Admin\Features::class, [R::GET, R::POST]],
58 '/federation' => [Module\Admin\Federation::class, [R::GET]],
60 '/item/delete' => [Module\Admin\Item\Delete::class, [R::GET, R::POST]],
61 '/item/source[/{guid}]' => [Module\Admin\Item\Source::class, [R::GET, R::POST]],
63 '/logs/view' => [Module\Admin\Logs\View::class, [R::GET]],
64 '/logs' => [Module\Admin\Logs\Settings::class, [R::GET, R::POST]],
66 '/phpinfo' => [Module\Admin\PhpInfo::class, [R::GET]],
68 '/queue[/deferred]' => [Module\Admin\Queue::class, [R::GET]],
70 '/site' => [Module\Admin\Site::class, [R::GET, R::POST]],
72 '/themes' => [Module\Admin\Themes\Index::class, [R::GET, R::POST]],
73 '/themes/{theme}' => [Module\Admin\Themes\Details::class, [R::GET, R::POST]],
74 '/themes/{theme}/embed' => [Module\Admin\Themes\Embed::class, [R::GET, R::POST]],
76 '/tos' => [Module\Admin\Tos::class, [R::GET, R::POST]],
78 '/users[/{action}/{uid}]' => [Module\Admin\Users::class, [R::GET, R::POST]],
80 '/amcd' => [Module\AccountManagementControlDocument::class, [R::GET]],
81 '/acctlink' => [Module\Acctlink::class, [R::GET]],
82 '/allfriends/{id:\d+}' => [Module\AllFriends::class, [R::GET]],
83 '/apps' => [Module\Apps::class, [R::GET]],
84 '/attach/{item:\d+}' => [Module\Attach::class, [R::GET]],
85 '/babel' => [Module\Debug\Babel::class, [R::GET, R::POST]],
86 '/bookmarklet' => [Module\Bookmarklet::class, [R::GET]],
87 '/compose[/{type}]' => [Module\Item\Compose::class, [R::GET, R::POST]],
90 '[/]' => [Module\Contact::class, [R::GET]],
91 '/{id:\d+}[/]' => [Module\Contact::class, [R::GET, R::POST]],
92 '/{id:\d+}/archive' => [Module\Contact::class, [R::GET]],
93 '/{id:\d+}/block' => [Module\Contact::class, [R::GET]],
94 '/{id:\d+}/conversations' => [Module\Contact::class, [R::GET]],
95 '/{id:\d+}/drop' => [Module\Contact::class, [R::GET]],
96 '/{id:\d+}/ignore' => [Module\Contact::class, [R::GET]],
97 '/{id:\d+}/posts' => [Module\Contact::class, [R::GET]],
98 '/{id:\d+}/update' => [Module\Contact::class, [R::GET]],
99 '/{id:\d+}/updateprofile' => [Module\Contact::class, [R::GET]],
100 '/archived' => [Module\Contact::class, [R::GET]],
101 '/batch' => [Module\Contact::class, [R::GET, R::POST]],
102 '/pending' => [Module\Contact::class, [R::GET]],
103 '/blocked' => [Module\Contact::class, [R::GET]],
104 '/hidden' => [Module\Contact::class, [R::GET]],
105 '/ignored' => [Module\Contact::class, [R::GET]],
106 '/hovercard' => [Module\Contact\Hovercard::class, [R::GET]],
109 '/credits' => [Module\Credits::class, [R::GET]],
110 '/delegation'=> [Module\Delegation::class, [R::GET, R::POST]],
111 '/dirfind' => [Module\Search\Directory::class, [R::GET]],
112 '/directory' => [Module\Directory::class, [R::GET]],
115 '/{nickname}' => [Module\Feed::class, [R::GET]],
116 '/{nickname}/posts' => [Module\Feed::class, [R::GET]],
117 '/{nickname}/comments' => [Module\Feed::class, [R::GET]],
118 '/{nickname}/replies' => [Module\Feed::class, [R::GET]],
119 '/{nickname}/activity' => [Module\Feed::class, [R::GET]],
121 '/feedtest' => [Module\Debug\Feed::class, [R::GET]],
124 '/post/{guid}' => [Module\Diaspora\Fetch::class, [R::GET]],
125 '/status_message/{guid}' => [Module\Diaspora\Fetch::class, [R::GET]],
126 '/reshare/{guid}' => [Module\Diaspora\Fetch::class, [R::GET]],
128 '/filer[/{id:\d+}]' => [Module\Filer\SaveTag::class, [R::GET]],
129 '/filerm/{id:\d+}' => [Module\Filer\RemoveTag::class, [R::GET]],
130 '/follow_confirm' => [Module\FollowConfirm::class, [R::GET, R::POST]],
131 '/followers/{owner}' => [Module\Followers::class, [R::GET]],
132 '/following/{owner}' => [Module\Following::class, [R::GET]],
133 '/friendica[/json]' => [Module\Friendica::class, [R::GET]],
136 '[/]' => [Module\Group::class, [R::GET, R::POST]],
137 '/{group:\d+}' => [Module\Group::class, [R::GET, R::POST]],
138 '/none' => [Module\Group::class, [R::GET, R::POST]],
139 '/new' => [Module\Group::class, [R::GET, R::POST]],
140 '/drop/{group:\d+}' => [Module\Group::class, [R::GET, R::POST]],
141 '/{group:\d+}/{contact:\d+}' => [Module\Group::class, [R::GET, R::POST]],
143 '/{group:\d+}/add/{contact:\d+}' => [Module\Group::class, [R::GET, R::POST]],
144 '/{group:\d+}/remove/{contact:\d+}' => [Module\Group::class, [R::GET, R::POST]],
146 '/hashtag' => [Module\Hashtag::class, [R::GET]],
147 '/help[/{doc:.+}]' => [Module\Help::class, [R::GET]],
148 '/home' => [Module\Home::class, [R::GET]],
149 '/hcard/{profile}[/{action}]' => [Module\HoverCard::class, [R::GET]],
150 '/inbox[/{nickname}]' => [Module\Inbox::class, [R::GET, R::POST]],
151 '/invite' => [Module\Invite::class, [R::GET, R::POST]],
154 '[/]' => [Module\Install::class, [R::GET, R::POST]],
155 '/testrewrite' => [Module\Install::class, [R::GET]],
159 '/ignore/{id}' => [Module\Item\Ignore::class, [R::GET]],
162 '/like/{item:\d+}' => [Module\Like::class, [R::GET]],
163 '/localtime' => [Module\Debug\Localtime::class, [R::GET, R::POST]],
164 '/login' => [Module\Security\Login::class, [R::GET, R::POST]],
165 '/logout' => [Module\Security\Logout::class, [R::GET, R::POST]],
166 '/magic' => [Module\Magic::class, [R::GET]],
167 '/maintenance' => [Module\Maintenance::class, [R::GET]],
168 '/manifest' => [Module\Manifest::class, [R::GET]],
169 '/modexp/{nick}' => [Module\PublicRSAKey::class, [R::GET]],
170 '/newmember' => [Module\Welcome::class, [R::GET]],
171 '/nodeinfo/{version}' => [Module\NodeInfo::class, [R::GET]],
172 '/nogroup' => [Module\Group::class, [R::GET]],
175 '/{nick}' => [Module\NoScrape::class, [R::GET]],
176 '/{profile}/view' => [Module\NoScrape::class, [R::GET]],
179 '/notifications' => [
180 '/network[/json]' => [Module\Notifications\Notifications::class, [R::GET, R::POST]],
181 '/system[/json]' => [Module\Notifications\Notifications::class, [R::GET, R::POST]],
182 '/personal[/json]' => [Module\Notifications\Notifications::class, [R::GET, R::POST]],
183 '/home[/json]' => [Module\Notifications\Notifications::class, [R::GET, R::POST]],
184 '/intros[/json]' => [Module\Notifications\Introductions::class, [R::GET, R::POST]],
185 '/intros/all[/json]' => [Module\Notifications\Introductions::class, [R::GET, R::POST]],
186 '/intros/{contact:\d+}[/json]' => [Module\Notifications\Introductions::class, [R::GET, R::POST]],
190 '[/]' => [Module\Notifications\Notification::class, [R::GET]],
191 '/mark/all' => [Module\Notifications\Notification::class, [R::GET]],
192 '/{id:\d+}' => [Module\Notifications\Notification::class, [R::GET, R::POST]],
194 '/objects/{guid}' => [Module\Objects::class, [R::GET]],
197 '/b2h' => [Module\Oembed::class, [R::GET]],
198 '/h2b' => [Module\Oembed::class, [R::GET]],
199 '/{hash}' => [Module\Oembed::class, [R::GET]],
201 '/outbox/{owner}' => [Module\Outbox::class, [R::GET]],
202 '/owa' => [Module\Owa::class, [R::GET]],
203 '/openid' => [Module\Security\OpenID::class, [R::GET]],
204 '/opensearch' => [Module\OpenSearch::class, [R::GET]],
207 '/{name}' => [Module\Photo::class, [R::GET]],
208 '/{type}/{name}' => [Module\Photo::class, [R::GET]],
209 '/{type}/{customize}/{name}' => [Module\Photo::class, [R::GET]],
212 '/pinned/{item:\d+}' => [Module\Pinned::class, [R::GET]],
213 '/pretheme' => [Module\ThemeDetails::class, [R::GET]],
214 '/probe' => [Module\Debug\Probe::class, [R::GET]],
217 '/{nickname}' => [Module\Profile\Index::class, [R::GET]],
218 '/{nickname}/profile' => [Module\Profile\Profile::class, [R::GET]],
219 '/{nickname}/contacts[/{type}]' => [Module\Profile\Contacts::class, [R::GET]],
220 '/{nickname}/status[/{category}[/{date1}[/{date2}]]]' => [Module\Profile\Status::class, [R::GET]],
224 '[/]' => [Module\Proxy::class, [R::GET]],
225 '/{url}' => [Module\Proxy::class, [R::GET]],
226 '/{sub1}/{url}' => [Module\Proxy::class, [R::GET]],
227 '/{sub1}/{sub2}/{url}' => [Module\Proxy::class, [R::GET]],
231 '[/]' => [Module\Search\Index::class, [R::GET]],
232 '/acl' => [Module\Search\Acl::class, [R::GET, R::POST]],
233 '/saved/add' => [Module\Search\Saved::class, [R::GET]],
234 '/saved/remove' => [Module\Search\Saved::class, [R::GET]],
238 '/public' => [Module\Diaspora\Receive::class, [R::POST]],
239 '/users/{guid}' => [Module\Diaspora\Receive::class, [R::POST]],
244 '[/]' => [Module\Settings\TwoFactor\Index::class, [R::GET, R::POST]],
245 '/recovery' => [Module\Settings\TwoFactor\Recovery::class, [R::GET, R::POST]],
246 '/app_specific' => [Module\Settings\TwoFactor\AppSpecific::class, [R::GET, R::POST]],
247 '/verify' => [Module\Settings\TwoFactor\Verify::class, [R::GET, R::POST]],
249 '/delegation[/{action}/{user_id}]' => [Module\Settings\Delegation::class, [R::GET, R::POST]],
251 '[/]' => [Module\Settings\Profile\Index::class, [R::GET, R::POST]],
252 '/photo[/new]' => [Module\Settings\Profile\Photo\Index::class, [R::GET, R::POST]],
253 '/photo/crop/{guid}' => [Module\Settings\Profile\Photo\Crop::class, [R::GET, R::POST]],
255 '/userexport[/{action}]' => [Module\Settings\UserExport::class, [R::GET, R::POST]],
258 '/randprof' => [Module\RandomProfile::class, [R::GET]],
259 '/register' => [Module\Register::class, [R::GET, R::POST]],
260 '/robots.txt' => [Module\RobotsTxt::class, [R::GET]],
261 '/rsd.xml' => [Module\ReallySimpleDiscovery::class, [R::GET]],
262 '/smilies[/json]' => [Module\Smilies::class, [R::GET]],
263 '/statistics.json' => [Module\Statistics::class, [R::GET]],
264 '/starred/{item:\d+}' => [Module\Starred::class, [R::GET]],
265 '/toggle_mobile' => [Module\ToggleMobile::class, [R::GET]],
266 '/tos' => [Module\Tos::class, [R::GET]],
268 '/update_profile' => [Module\Update\Profile::class, [R::GET]],
270 '/view/theme/{theme}/style.pcss' => [Module\Theme::class, [R::GET]],
271 '/viewsrc/{item:\d+}' => [Module\Debug\ItemBody::class, [R::GET]],
272 '/webfinger' => [Module\Debug\WebFinger::class, [R::GET]],
273 '/xrd' => [Module\Xrd::class, [R::GET]],