Friendica Communications Platform (please note that this is a clone of the repository at github, issues are handled there) https://friendi.ca
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

435 lines
28 KiB

2 months ago
  1. <?php
  2. /**
  3. * @copyright Copyright (C) 2010-2021, the Friendica project
  4. *
  5. * @license GNU AGPL version 3 or any later version
  6. *
  7. * This program is free software: you can redistribute it and/or modify
  8. * it under the terms of the GNU Affero General Public License as
  9. * published by the Free Software Foundation, either version 3 of the
  10. * License, or (at your option) any later version.
  11. *
  12. * This program is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. * GNU Affero General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU Affero General Public License
  18. * along with this program. If not, see <https://www.gnu.org/licenses/>.
  19. *
  20. * Configuration for the default routes in Friendica
  21. *
  22. * The syntax is either
  23. * - 'route' => [ Module::class , [ HTTPMethod(s) ] ]
  24. * - 'group' => [ 'route' => [ Module::class, [ HTTPMethod(s) ] ]
  25. *
  26. * It's possible to create recursive groups
  27. *
  28. */
  29. use Friendica\App\Router as R;
  30. use Friendica\Module;
  31. $profileRoutes = [
  32. '' => [Module\Profile\Index::class, [R::GET]],
  33. '/profile' => [Module\Profile\Profile::class, [R::GET]],
  34. '/contacts/common' => [Module\Profile\Common::class, [R::GET]],
  35. '/contacts[/{type}]' => [Module\Profile\Contacts::class, [R::GET]],
  36. '/status[/{category}[/{date1}[/{date2}]]]' => [Module\Profile\Status::class, [R::GET]],
  37. ];
  38. return [
  39. '/' => [Module\Home::class, [R::GET]],
  40. '/.well-known' => [
  41. '/host-meta' => [Module\WellKnown\HostMeta::class, [R::GET]],
  42. '/nodeinfo' => [Module\WellKnown\NodeInfo::class, [R::GET]],
  43. '/security.txt' => [Module\WellKnown\SecurityTxt::class, [R::GET]],
  44. '/webfinger' => [Module\Xrd::class, [R::GET]],
  45. '/x-nodeinfo2' => [Module\NodeInfo210::class, [R::GET]],
  46. '/x-social-relay' => [Module\WellKnown\XSocialRelay::class, [R::GET]],
  47. ],
  48. '/2fa' => [
  49. '[/]' => [Module\Security\TwoFactor\Verify::class, [R::GET, R::POST]],
  50. '/recovery' => [Module\Security\TwoFactor\Recovery::class, [R::GET, R::POST]],
  51. ],
  52. '/api' => [
  53. '/v1' => [
  54. '/accounts' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // not supported
  55. '/accounts/{id:\d+}' => [Module\Api\Mastodon\Accounts::class, [R::GET ]],
  56. '/accounts/{id:\d+}/statuses' => [Module\Api\Mastodon\Accounts\Statuses::class, [R::GET ]],
  57. '/accounts/{id:\d+}/followers' => [Module\Api\Mastodon\Accounts\Followers::class, [R::GET ]],
  58. '/accounts/{id:\d+}/following' => [Module\Api\Mastodon\Accounts\Following::class, [R::GET ]],
  59. '/accounts/{id:\d+}/lists' => [Module\Api\Mastodon\Accounts\Lists::class, [R::GET ]],
  60. '/accounts/{id:\d+}/identity_proofs' => [Module\Api\Mastodon\Accounts\IdentityProofs::class, [R::GET ]], // Dummy, not supported
  61. '/accounts/{id:\d+}/follow' => [Module\Api\Mastodon\Accounts\Follow::class, [ R::POST]],
  62. '/accounts/{id:\d+}/unfollow' => [Module\Api\Mastodon\Accounts\Unfollow::class, [ R::POST]],
  63. '/accounts/{id:\d+}/block' => [Module\Api\Mastodon\Accounts\Block::class, [ R::POST]],
  64. '/accounts/{id:\d+}/unblock' => [Module\Api\Mastodon\Accounts\Unblock::class, [ R::POST]],
  65. '/accounts/{id:\d+}/mute' => [Module\Api\Mastodon\Accounts\Mute::class, [ R::POST]],
  66. '/accounts/{id:\d+}/unmute' => [Module\Api\Mastodon\Accounts\Unmute::class, [ R::POST]],
  67. '/accounts/{id:\d+}/pin' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // not supported
  68. '/accounts/{id:\d+}/unpin' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // not supported
  69. '/accounts/{id:\d+}/note' => [Module\Api\Mastodon\Accounts\Note::class, [ R::POST]],
  70. '/accounts/relationships' => [Module\Api\Mastodon\Accounts\Relationships::class, [R::GET ]],
  71. '/accounts/search' => [Module\Api\Mastodon\Accounts\Search::class, [R::GET ]],
  72. '/accounts/update_credentials' => [Module\Api\Mastodon\Accounts\UpdateCredentials::class, [R::PATCH ]],
  73. '/accounts/verify_credentials' => [Module\Api\Mastodon\Accounts\VerifyCredentials::class, [R::GET ]],
  74. '/admin/accounts' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // not supported
  75. '/admin/accounts/{id:\d+}' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // not supported
  76. '/admin/accounts/{id:\d+}/{action}' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // not supported
  77. '/admin/reports' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // not supported
  78. '/admin/reports/{id:\d+}' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // not supported
  79. '/admin/reports/{id:\d+}/{action}' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // not supported
  80. '/announcements' => [Module\Api\Mastodon\Announcements::class, [R::GET ]], // Dummy, not supported
  81. '/announcements/{id:\d+}/dismiss' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // not supported
  82. '/announcements/{id:\d+}/reactions/{name}' => [Module\Api\Mastodon\Unimplemented::class, [R::PUT, R::DELETE]], // not supported
  83. '/apps' => [Module\Api\Mastodon\Apps::class, [ R::POST]],
  84. '/apps/verify_credentials' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // @todo
  85. '/blocks' => [Module\Api\Mastodon\Blocks::class, [R::GET ]],
  86. '/bookmarks' => [Module\Api\Mastodon\Bookmarks::class, [R::GET ]],
  87. '/conversations' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // @todo
  88. '/conversations/{id:\d+}' => [Module\Api\Mastodon\Unimplemented::class, [R::DELETE ]], // @todo
  89. '/conversations/{id:\d+}/read' => [Module\Api\Mastodon\Unimplemented::class, [R::POST ]], // @todo
  90. '/custom_emojis' => [Module\Api\Mastodon\CustomEmojis::class, [R::GET ]],
  91. '/domain_blocks' => [Module\Api\Mastodon\Unimplemented::class, [R::GET, R::POST, R::DELETE]], // not supported
  92. '/directory' => [Module\Api\Mastodon\Directory::class, [R::GET ]],
  93. '/endorsements' => [Module\Api\Mastodon\Endorsements::class, [R::GET ]], // Dummy, not supported
  94. '/favourites' => [Module\Api\Mastodon\Favourited::class, [R::GET ]],
  95. '/featured_tags' => [Module\Api\Mastodon\Unimplemented::class, [R::GET, R::POST]], // not supported
  96. '/featured_tags/{id:\d+}' => [Module\Api\Mastodon\Unimplemented::class, [R::DELETE ]], // not supported
  97. '/featured_tags/suggestions' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // not supported
  98. '/filters' => [Module\Api\Mastodon\Filters::class, [R::GET ]], // Dummy, not supported
  99. '/filters/{id:\d+}' => [Module\Api\Mastodon\Unimplemented::class, [R::GET, R::POST, R::PUT, R::DELETE]], // not supported
  100. '/follow_requests' => [Module\Api\Mastodon\FollowRequests::class, [R::GET ]],
  101. '/follow_requests/{id:\d+}/{action}' => [Module\Api\Mastodon\FollowRequests::class, [ R::POST]],
  102. '/instance' => [Module\Api\Mastodon\Instance::class, [R::GET ]],
  103. '/instance/activity' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // @todo
  104. '/instance/peers' => [Module\Api\Mastodon\Instance\Peers::class, [R::GET ]],
  105. '/lists' => [Module\Api\Mastodon\Lists::class, [R::GET, R::POST]],
  106. '/lists/{id:\d+}' => [Module\Api\Mastodon\Lists::class, [R::GET, R::PUT, R::DELETE]],
  107. '/lists/{id:\d+}/accounts' => [Module\Api\Mastodon\Lists\Accounts::class, [R::GET, R::POST, R::DELETE]],
  108. '/markers' => [Module\Api\Mastodon\Markers::class, [R::GET, R::POST]], // Dummy, not supported
  109. '/media' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // @todo
  110. '/media/{id:\d+}' => [Module\Api\Mastodon\Media::class, [R::GET, R::PUT ]],
  111. '/mutes' => [Module\Api\Mastodon\Mutes::class, [R::GET ]],
  112. '/notifications' => [Module\Api\Mastodon\Notifications::class, [R::GET ]],
  113. '/notifications/{id:\d+}' => [Module\Api\Mastodon\Notifications::class, [R::GET ]],
  114. '/notifications/clear' => [Module\Api\Mastodon\Notifications\Clear::class, [ R::POST]],
  115. '/notifications/{id:\d+}/dismiss' => [Module\Api\Mastodon\Notifications\Dismiss::class, [ R::POST]],
  116. '/polls/{id:\d+}' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // not supported
  117. '/polls/{id:\d+}/votes' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // not supported
  118. '/preferences' => [Module\Api\Mastodon\Preferences::class, [R::GET ]],
  119. '/reports' => [Module\Api\Mastodon\Unimplemented::class, [ R::POST]], // not supported
  120. '/scheduled_statuses' => [Module\Api\Mastodon\ScheduledStatuses::class, [R::GET ]], // Dummy, not supported
  121. '/scheduled_statuses/{id:\d+}' => [Module\Api\Mastodon\Unimplemented::class, [R::GET, R::PUT, R::DELETE]], // not supported
  122. '/statuses' => [Module\Api\Mastodon\Statuses::class, [ R::POST]],
  123. '/statuses/{id:\d+}' => [Module\Api\Mastodon\Statuses::class, [R::GET, R::DELETE]],
  124. '/statuses/{id:\d+}/context' => [Module\Api\Mastodon\Statuses\Context::class, [R::GET ]],
  125. '/statuses/{id:\d+}/reblogged_by' => [Module\Api\Mastodon\Statuses\RebloggedBy::class, [R::GET ]],
  126. '/statuses/{id:\d+}/favourited_by' => [Module\Api\Mastodon\Statuses\FavouritedBy::class, [R::GET ]],
  127. '/statuses/{id:\d+}/favourite' => [Module\Api\Mastodon\Statuses\Favourite::class, [ R::POST]],
  128. '/statuses/{id:\d+}/unfavourite' => [Module\Api\Mastodon\Statuses\Unfavourite::class, [ R::POST]],
  129. '/statuses/{id:\d+}/reblog' => [Module\Api\Mastodon\Statuses\Reblog::class, [ R::POST]],
  130. '/statuses/{id:\d+}/unreblog' => [Module\Api\Mastodon\Statuses\Unreblog::class, [ R::POST]],
  131. '/statuses/{id:\d+}/bookmark' => [Module\Api\Mastodon\Statuses\Bookmark::class, [ R::POST]],
  132. '/statuses/{id:\d+}/unbookmark' => [Module\Api\Mastodon\Statuses\Unbookmark::class, [ R::POST]],
  133. '/statuses/{id:\d+}/mute' => [Module\Api\Mastodon\Statuses\Mute::class, [ R::POST]],
  134. '/statuses/{id:\d+}/unmute' => [Module\Api\Mastodon\Statuses\Unmute::class, [ R::POST]],
  135. '/statuses/{id:\d+}/pin' => [Module\Api\Mastodon\Statuses\Pin::class, [ R::POST]],
  136. '/statuses/{id:\d+}/unpin' => [Module\Api\Mastodon\Statuses\Unpin::class, [ R::POST]],
  137. '/suggestions' => [Module\Api\Mastodon\Suggestions::class, [R::GET ]],
  138. '/suggestions/{id:\d+}' => [Module\Api\Mastodon\Unimplemented::class, [R::DELETE ]], // not implemented
  139. '/timelines/direct' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // @todo
  140. '/timelines/home' => [Module\Api\Mastodon\Timelines\Home::class, [R::GET ]],
  141. '/timelines/list/{id:\d+}' => [Module\Api\Mastodon\Timelines\ListTimeline::class, [R::GET ]],
  142. '/timelines/public' => [Module\Api\Mastodon\Timelines\PublicTimeline::class, [R::GET ]],
  143. '/timelines/tag/{hashtag}' => [Module\Api\Mastodon\Timelines\Tag::class, [R::GET ]],
  144. '/trends' => [Module\Api\Mastodon\Trends::class, [R::GET ]],
  145. ],
  146. '/v2' => [
  147. '/search' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]], // @todo
  148. ],
  149. '/friendica' => [
  150. '/profile/show' => [Module\Api\Friendica\Profile\Show::class, [R::GET ]],
  151. '/events' => [Module\Api\Friendica\Events\Index::class, [R::GET ]],
  152. ],
  153. '/followers/ids' => [Module\Api\Twitter\FollowersIds::class, [R::GET ]],
  154. '/followers/list' => [Module\Api\Twitter\FollowersList::class, [R::GET ]],
  155. '/friends/ids' => [Module\Api\Twitter\FriendsIds::class, [R::GET ]],
  156. '/friends/list' => [Module\Api\Twitter\FriendsList::class, [R::GET ]],
  157. '/oembed' => [Module\Api\Mastodon\Unimplemented::class, [R::GET ]],
  158. '/proofs' => [Module\Api\Mastodon\Proofs::class, [R::GET ]], // Dummy, not supported
  159. ],
  160. '/admin' => [
  161. '[/]' => [Module\Admin\Summary::class, [R::GET]],
  162. '/addons' => [Module\Admin\Addons\Index::class, [R::GET, R::POST]],
  163. '/addons/{addon}' => [Module\Admin\Addons\Details::class, [R::GET, R::POST]],
  164. '/blocklist/contact' => [Module\Admin\Blocklist\Contact::class, [R::GET, R::POST]],
  165. '/blocklist/server' => [Module\Admin\Blocklist\Server::class, [R::GET, R::POST]],
  166. '/dbsync[/{action}[/{update:\d+}]]' => [Module\Admin\DBSync::class, [R::GET]],
  167. '/features' => [Module\Admin\Features::class, [R::GET, R::POST]],
  168. '/federation' => [Module\Admin\Federation::class, [R::GET]],
  169. '/item/delete' => [Module\Admin\Item\Delete::class, [R::GET, R::POST]],
  170. '/item/source[/{guid}]' => [Module\Admin\Item\Source::class, [R::GET, R::POST]],
  171. '/logs/view' => [Module\Admin\Logs\View::class, [R::GET]],
  172. '/logs' => [Module\Admin\Logs\Settings::class, [R::GET, R::POST]],
  173. '/phpinfo' => [Module\Admin\PhpInfo::class, [R::GET]],
  174. '/queue[/{status}]' => [Module\Admin\Queue::class, [R::GET]],
  175. '/site' => [Module\Admin\Site::class, [R::GET, R::POST]],
  176. '/themes' => [Module\Admin\Themes\Index::class, [R::GET, R::POST]],
  177. '/themes/{theme}' => [Module\Admin\Themes\Details::class, [R::GET, R::POST]],
  178. '/themes/{theme}/embed' => [Module\Admin\Themes\Embed::class, [R::GET, R::POST]],
  179. '/tos' => [Module\Admin\Tos::class, [R::GET, R::POST]],
  180. '/users[/{action}/{uid}]' => [Module\Admin\Users\Index::class, [R::GET, R::POST]],
  181. '/users/active[/{action}/{uid}]' => [Module\Admin\Users\Active::class, [R::GET, R::POST]],
  182. '/users/pending[/{action}/{uid}]' => [Module\Admin\Users\Pending::class, [R::GET, R::POST]],
  183. '/users/blocked[/{action}/{uid}]' => [Module\Admin\Users\Blocked::class, [R::GET, R::POST]],
  184. '/users/deleted' => [Module\Admin\Users\Deleted::class, [R::GET ]],
  185. '/users/create' => [Module\Admin\Users\Create::class, [R::GET, R::POST]],
  186. ],
  187. '/amcd' => [Module\AccountManagementControlDocument::class, [R::GET]],
  188. '/acctlink' => [Module\Acctlink::class, [R::GET]],
  189. '/apps' => [Module\Apps::class, [R::GET]],
  190. '/attach/{item:\d+}' => [Module\Attach::class, [R::GET]],
  191. '/babel' => [Module\Debug\Babel::class, [R::GET, R::POST]],
  192. '/debug/ap' => [Module\Debug\ActivityPubConversion::class, [R::GET, R::POST]],
  193. '/bookmarklet' => [Module\Bookmarklet::class, [R::GET]],
  194. '/community[/{content}]' => [Module\Conversation\Community::class, [R::GET]],
  195. '/compose[/{type}]' => [Module\Item\Compose::class, [R::GET, R::POST]],
  196. '/contact' => [
  197. '[/]' => [Module\Contact::class, [R::GET]],
  198. '/{id:\d+}[/]' => [Module\Contact::class, [R::GET, R::POST]],
  199. '/{id:\d+}/archive' => [Module\Contact::class, [R::GET]],
  200. '/{id:\d+}/advanced' => [Module\Contact\Advanced::class, [R::GET, R::POST]],
  201. '/{id:\d+}/block' => [Module\Contact::class, [R::GET]],
  202. '/{id:\d+}/conversations' => [Module\Contact::class, [R::GET]],
  203. '/{id:\d+}/contacts[/{type}]' => [Module\Contact\Contacts::class, [R::GET]],
  204. '/{id:\d+}/drop' => [Module\Contact::class, [R::GET]],
  205. '/{id:\d+}/ignore' => [Module\Contact::class, [R::GET]],
  206. '/{id:\d+}/poke' => [Module\Contact\Poke::class, [R::GET, R::POST]],
  207. '/{id:\d+}/posts' => [Module\Contact::class, [R::GET]],
  208. '/{id:\d+}/update' => [Module\Contact::class, [R::GET]],
  209. '/{id:\d+}/updateprofile' => [Module\Contact::class, [R::GET]],
  210. '/archived' => [Module\Contact::class, [R::GET]],
  211. '/batch' => [Module\Contact::class, [R::GET, R::POST]],
  212. '/pending' => [Module\Contact::class, [R::GET]],
  213. '/blocked' => [Module\Contact::class, [R::GET]],
  214. '/hidden' => [Module\Contact::class, [R::GET]],
  215. '/ignored' => [Module\Contact::class, [R::GET]],
  216. '/hovercard' => [Module\Contact\Hovercard::class, [R::GET]],
  217. ],
  218. '/credits' => [Module\Credits::class, [R::GET]],
  219. '/delegation'=> [Module\Delegation::class, [R::GET, R::POST]],
  220. '/dirfind' => [Module\Search\Directory::class, [R::GET]],
  221. '/directory' => [Module\Directory::class, [R::GET]],
  222. '/feed' => [
  223. '/{nickname}' => [Module\Feed::class, [R::GET]],
  224. '/{nickname}/posts' => [Module\Feed::class, [R::GET]],
  225. '/{nickname}/comments' => [Module\Feed::class, [R::GET]],
  226. '/{nickname}/replies' => [Module\Feed::class, [R::GET]],
  227. '/{nickname}/activity' => [Module\Feed::class, [R::GET]],
  228. ],
  229. '/feedtest' => [Module\Debug\Feed::class, [R::GET]],
  230. '/fetch' => [
  231. '/post/{guid}' => [Module\Diaspora\Fetch::class, [R::GET]],
  232. '/status_message/{guid}' => [Module\Diaspora\Fetch::class, [R::GET]],
  233. '/reshare/{guid}' => [Module\Diaspora\Fetch::class, [R::GET]],
  234. ],
  235. '/filed' => [Module\Search\Filed::class, [R::GET]],
  236. '/filer[/{id:\d+}]' => [Module\Filer\SaveTag::class, [R::GET]],
  237. '/filerm/{id:\d+}' => [Module\Filer\RemoveTag::class, [R::GET]],
  238. '/follow_confirm' => [Module\FollowConfirm::class, [R::GET, R::POST]],
  239. '/followers/{owner}' => [Module\Followers::class, [R::GET]],
  240. '/following/{owner}' => [Module\Following::class, [R::GET]],
  241. '/friendica[/json]' => [Module\Friendica::class, [R::GET]],
  242. '/friendica/inbox' => [Module\Inbox::class, [R::GET, R::POST]],
  243. '/fsuggest/{contact:\d+}' => [Module\FriendSuggest::class, [R::GET, R::POST]],
  244. '/group' => [
  245. '[/]' => [Module\Group::class, [R::GET, R::POST]],
  246. '/{group:\d+}' => [Module\Group::class, [R::GET, R::POST]],
  247. '/none' => [Module\Group::class, [R::GET, R::POST]],
  248. '/new' => [Module\Group::class, [R::GET, R::POST]],
  249. '/drop/{group:\d+}' => [Module\Group::class, [R::GET, R::POST]],
  250. '/{group:\d+}/{contact:\d+}' => [Module\Group::class, [R::GET, R::POST]],
  251. '/{group:\d+}/add/{contact:\d+}' => [Module\Group::class, [R::GET, R::POST]],
  252. '/{group:\d+}/remove/{contact:\d+}' => [Module\Group::class, [R::GET, R::POST]],
  253. ],
  254. '/hashtag' => [Module\Hashtag::class, [R::GET]],
  255. '/help[/{doc:.+}]' => [Module\Help::class, [R::GET]],
  256. '/home' => [Module\Home::class, [R::GET]],
  257. '/hcard/{profile}[/{action}]' => [Module\HoverCard::class, [R::GET]],
  258. '/inbox[/{nickname}]' => [Module\Inbox::class, [R::GET, R::POST]],
  259. '/invite' => [Module\Invite::class, [R::GET, R::POST]],
  260. '/install' => [
  261. '[/]' => [Module\Install::class, [R::GET, R::POST]],
  262. '/testrewrite' => [Module\Install::class, [R::GET]],
  263. ],
  264. '/item/{id:\d+}' => [
  265. '/activity/{verb}' => [Module\Item\Activity::class, [ R::POST]],
  266. '/follow' => [Module\Item\Follow::class, [ R::POST]],
  267. '/ignore' => [Module\Item\Ignore::class, [ R::POST]],
  268. '/pin' => [Module\Item\Pin::class, [ R::POST]],
  269. '/star' => [Module\Item\Star::class, [ R::POST]],
  270. ],
  271. '/localtime' => [Module\Debug\Localtime::class, [R::GET, R::POST]],
  272. '/login' => [Module\Security\Login::class, [R::GET, R::POST]],
  273. '/logout' => [Module\Security\Logout::class, [R::GET, R::POST]],
  274. '/magic' => [Module\Magic::class, [R::GET]],
  275. '/manifest' => [Module\Manifest::class, [R::GET]],
  276. '/friendica.webmanifest' => [Module\Manifest::class, [R::GET]],
  277. '/modexp/{nick}' => [Module\PublicRSAKey::class, [R::GET]],
  278. '/newmember' => [Module\Welcome::class, [R::GET]],
  279. '/nodeinfo/1.0' => [Module\NodeInfo110::class, [R::GET]],
  280. '/nodeinfo/2.0' => [Module\NodeInfo120::class, [R::GET]],
  281. '/nogroup' => [Module\Group::class, [R::GET]],
  282. '/noscrape' => [
  283. '/{nick}' => [Module\NoScrape::class, [R::GET]],
  284. '/{profile}/view' => [Module\NoScrape::class, [R::GET]],
  285. ],
  286. '/notifications' => [
  287. '/network[/json]' => [Module\Notifications\Notifications::class, [R::GET, R::POST]],
  288. '/system[/json]' => [Module\Notifications\Notifications::class, [R::GET, R::POST]],
  289. '/personal[/json]' => [Module\Notifications\Notifications::class, [R::GET, R::POST]],
  290. '/home[/json]' => [Module\Notifications\Notifications::class, [R::GET, R::POST]],
  291. '/intros[/json]' => [Module\Notifications\Introductions::class, [R::GET, R::POST]],
  292. '/intros/all[/json]' => [Module\Notifications\Introductions::class, [R::GET, R::POST]],
  293. '/intros/{contact:\d+}[/json]' => [Module\Notifications\Introductions::class, [R::GET, R::POST]],
  294. ],
  295. '/notification' => [
  296. '[/]' => [Module\Notifications\Notification::class, [R::GET]],
  297. '/mark/all' => [Module\Notifications\Notification::class, [R::GET]],
  298. '/{id:\d+}' => [Module\Notifications\Notification::class, [R::GET, R::POST]],
  299. ],
  300. '/oauth' => [
  301. '/acknowledge' => [Module\OAuth\Acknowledge::class, [R::GET, R::POST]],
  302. '/authorize' => [Module\OAuth\Authorize::class, [R::GET]],
  303. '/revoke' => [Module\OAuth\Revoke::class, [R::POST]],
  304. '/token' => [Module\OAuth\Token::class, [R::POST]],
  305. ],
  306. '/objects/{guid}[/{activity}]' => [Module\Objects::class, [R::GET]],
  307. '/oembed' => [
  308. '/b2h' => [Module\Oembed::class, [R::GET]],
  309. '/h2b' => [Module\Oembed::class, [R::GET]],
  310. '/{hash}' => [Module\Oembed::class, [R::GET]],
  311. ],
  312. '/outbox/{owner}' => [Module\Outbox::class, [R::GET]],
  313. '/owa' => [Module\Owa::class, [R::GET]],
  314. '/openid' => [Module\Security\OpenID::class, [R::GET]],
  315. '/opensearch' => [Module\OpenSearch::class, [R::GET]],
  316. '/parseurl' => [Module\ParseUrl::class, [R::GET]],
  317. '/permission/tooltip/{type}/{id:\d+}' => [Module\PermissionTooltip::class, [R::GET]],
  318. '/photo' => [
  319. '/{name}' => [Module\Photo::class, [R::GET]],
  320. '/{type}/{name}' => [Module\Photo::class, [R::GET]],
  321. '/{type}/{customize}/{name}' => [Module\Photo::class, [R::GET]],
  322. ],
  323. '/pretheme' => [Module\ThemeDetails::class, [R::GET]],
  324. '/probe' => [Module\Debug\Probe::class, [R::GET]],
  325. '/profile/{nickname}' => $profileRoutes,
  326. '/u/{nickname}' => $profileRoutes,
  327. '/~{nickname}' => $profileRoutes,
  328. '/proxy' => [
  329. '[/]' => [Module\Proxy::class, [R::GET]],
  330. '/{url}' => [Module\Proxy::class, [R::GET]],
  331. '/{sub1}/{url}' => [Module\Proxy::class, [R::GET]],
  332. '/{sub1}/{sub2}/{url}' => [Module\Proxy::class, [R::GET]],
  333. ],
  334. '/search' => [
  335. '[/]' => [Module\Search\Index::class, [R::GET]],
  336. '/acl' => [Module\Search\Acl::class, [R::GET, R::POST]],
  337. '/saved/add' => [Module\Search\Saved::class, [R::GET]],
  338. '/saved/remove' => [Module\Search\Saved::class, [R::GET]],
  339. ],
  340. '/receive' => [
  341. '/public' => [Module\Diaspora\Receive::class, [R::POST]],
  342. '/users/{guid}' => [Module\Diaspora\Receive::class, [R::POST]],
  343. ],
  344. '/settings' => [
  345. '/2fa' => [
  346. '[/]' => [Module\Settings\TwoFactor\Index::class, [R::GET, R::POST]],
  347. '/recovery' => [Module\Settings\TwoFactor\Recovery::class, [R::GET, R::POST]],
  348. '/app_specific' => [Module\Settings\TwoFactor\AppSpecific::class, [R::GET, R::POST]],
  349. '/verify' => [Module\Settings\TwoFactor\Verify::class, [R::GET, R::POST]],
  350. '/trusted' => [Module\Settings\TwoFactor\Trusted::class, [R::GET, R::POST]],
  351. ],
  352. '/delegation[/{action}/{user_id}]' => [Module\Settings\Delegation::class, [R::GET, R::POST]],
  353. '/display' => [Module\Settings\Display::class, [R::GET, R::POST]],
  354. '/profile' => [
  355. '[/]' => [Module\Settings\Profile\Index::class, [R::GET, R::POST]],
  356. '/photo[/new]' => [Module\Settings\Profile\Photo\Index::class, [R::GET, R::POST]],
  357. '/photo/crop/{guid}' => [Module\Settings\Profile\Photo\Crop::class, [R::GET, R::POST]],
  358. ],
  359. '/userexport[/{action}]' => [Module\Settings\UserExport::class, [R::GET, R::POST]],
  360. ],
  361. '/network' => [
  362. '[/]' => [Module\Conversation\Network::class, [R::GET]],
  363. '/archive/{from:\d\d\d\d-\d\d-\d\d}[/{to:\d\d\d\d-\d\d-\d\d}]' => [Module\Conversation\Network::class, [R::GET]],
  364. '/forum/{contact_id:\d+}' => [Module\Conversation\Network::class, [R::GET]],
  365. '/group/{group_id:\d+}' => [Module\Conversation\Network::class, [R::GET]],
  366. ],
  367. '/randprof' => [Module\RandomProfile::class, [R::GET]],
  368. '/register' => [Module\Register::class, [R::GET, R::POST]],
  369. '/remote_follow/{profile}' => [Module\RemoteFollow::class, [R::GET, R::POST]],
  370. '/robots.txt' => [Module\RobotsTxt::class, [R::GET]],
  371. '/rsd.xml' => [Module\ReallySimpleDiscovery::class, [R::GET]],
  372. '/smilies[/json]' => [Module\Smilies::class, [R::GET]],
  373. '/statistics.json' => [Module\Statistics::class, [R::GET]],
  374. '/toggle_mobile' => [Module\ToggleMobile::class, [R::GET]],
  375. '/tos' => [Module\Tos::class, [R::GET]],
  376. '/update_community[/{content}]' => [Module\Update\Community::class, [R::GET]],
  377. '/update_network' => [Module\Update\Network::class, [R::GET]],
  378. '/update_profile' => [Module\Update\Profile::class, [R::GET]],
  379. '/view/theme/{theme}/style.pcss' => [Module\Theme::class, [R::GET]],
  380. '/viewsrc/{item:\d+}' => [Module\Debug\ItemBody::class, [R::GET]],
  381. '/webfinger' => [Module\Debug\WebFinger::class, [R::GET]],
  382. '/xrd' => [Module\Xrd::class, [R::GET]],
  383. '/worker' => [Module\Worker::class, [R::GET]],
  384. ];