1
0

routes.php 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. <?php
  2. /**
  3. * @copyright Copyright (c) 2016, ownCloud, Inc.
  4. *
  5. * @author Joas Schilling <coding@schilljs.com>
  6. * @author Jörn Friedrich Dreyer <jfd@butonic.de>
  7. * @author Morris Jobke <hey@morrisjobke.de>
  8. * @author Robin Appelman <robin@icewind.nl>
  9. * @author Robin McCorkell <robin@mccorkell.me.uk>
  10. * @author Roeland Jago Douma <roeland@famdouma.nl>
  11. * @author Ross Nicoll <jrn@jrn.me.uk>
  12. * @author Vincent Petry <vincent@nextcloud.com>
  13. *
  14. * @license AGPL-3.0
  15. *
  16. * This code is free software: you can redistribute it and/or modify
  17. * it under the terms of the GNU Affero General Public License, version 3,
  18. * as published by the Free Software Foundation.
  19. *
  20. * This program is distributed in the hope that it will be useful,
  21. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  22. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  23. * GNU Affero General Public License for more details.
  24. *
  25. * You should have received a copy of the GNU Affero General Public License, version 3,
  26. * along with this program. If not, see <http://www.gnu.org/licenses/>
  27. *
  28. */
  29. $this->create('files_external_oauth1', 'apps/files_external/ajax/oauth1.php')
  30. ->actionInclude('files_external/ajax/oauth1.php');
  31. $this->create('files_external_oauth2', 'apps/files_external/ajax/oauth2.php')
  32. ->actionInclude('files_external/ajax/oauth2.php');
  33. $this->create('files_external_list_applicable', '/apps/files_external/applicable')
  34. ->actionInclude('files_external/ajax/applicable.php');
  35. return [
  36. 'resources' => [
  37. 'global_storages' => ['url' => '/globalstorages'],
  38. 'user_storages' => ['url' => '/userstorages'],
  39. 'user_global_storages' => ['url' => '/userglobalstorages'],
  40. ],
  41. 'routes' => [
  42. [
  43. 'name' => 'Ajax#getSshKeys',
  44. 'url' => '/ajax/public_key.php',
  45. 'verb' => 'POST',
  46. 'requirements' => [],
  47. ],
  48. [
  49. 'name' => 'Ajax#saveGlobalCredentials',
  50. 'url' => '/globalcredentials',
  51. 'verb' => 'POST',
  52. ],
  53. ],
  54. 'ocs' => [
  55. [
  56. 'name' => 'Api#getUserMounts',
  57. 'url' => '/api/v1/mounts',
  58. 'verb' => 'GET',
  59. ],
  60. [
  61. 'name' => 'Api#askNativeAuth',
  62. 'url' => '/api/v1/auth',
  63. 'verb' => 'GET',
  64. ],
  65. ],
  66. ];