routes.php 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. <?php
  2. /**
  3. * SPDX-FileCopyrightText: 2016 Nextcloud GmbH and Nextcloud contributors
  4. * SPDX-License-Identifier: AGPL-3.0-or-later
  5. */
  6. return [
  7. 'routes' => [
  8. [
  9. 'name' => 'Theming#updateAppMenu',
  10. 'url' => '/ajax/updateAppMenu',
  11. 'verb' => 'PUT',
  12. ],
  13. [
  14. 'name' => 'Theming#updateStylesheet',
  15. 'url' => '/ajax/updateStylesheet',
  16. 'verb' => 'POST'
  17. ],
  18. [
  19. 'name' => 'Theming#undo',
  20. 'url' => '/ajax/undoChanges',
  21. 'verb' => 'POST'
  22. ],
  23. [
  24. 'name' => 'Theming#undoAll',
  25. 'url' => '/ajax/undoAllChanges',
  26. 'verb' => 'POST'
  27. ],
  28. [
  29. 'name' => 'Theming#uploadImage',
  30. 'url' => '/ajax/uploadImage',
  31. 'verb' => 'POST'
  32. ],
  33. [
  34. 'name' => 'Theming#getThemeStylesheet',
  35. 'url' => '/theme/{themeId}.css',
  36. 'verb' => 'GET',
  37. ],
  38. [
  39. 'name' => 'Theming#getImage',
  40. 'url' => '/image/{key}',
  41. 'verb' => 'GET',
  42. ],
  43. [
  44. 'name' => 'Theming#getManifest',
  45. 'url' => '/manifest/{app}',
  46. 'verb' => 'GET',
  47. 'defaults' => ['app' => 'core']
  48. ],
  49. [
  50. 'name' => 'Icon#getFavicon',
  51. 'url' => '/favicon/{app}',
  52. 'verb' => 'GET',
  53. 'defaults' => ['app' => 'core'],
  54. ],
  55. [
  56. 'name' => 'Icon#getTouchIcon',
  57. 'url' => '/icon/{app}',
  58. 'verb' => 'GET',
  59. 'defaults' => ['app' => 'core'],
  60. ],
  61. [
  62. 'name' => 'Icon#getThemedIcon',
  63. 'url' => '/img/{app}/{image}',
  64. 'verb' => 'GET',
  65. 'requirements' => ['image' => '.+']
  66. ],
  67. [
  68. 'name' => 'userTheme#getBackground',
  69. 'url' => '/background',
  70. 'verb' => 'GET',
  71. ],
  72. [
  73. 'name' => 'userTheme#setBackground',
  74. 'url' => '/background/{type}',
  75. 'verb' => 'POST',
  76. ],
  77. [
  78. 'name' => 'userTheme#deleteBackground',
  79. 'url' => '/background/custom',
  80. 'verb' => 'DELETE',
  81. ],
  82. ],
  83. 'ocs' => [
  84. [
  85. 'name' => 'userTheme#enableTheme',
  86. 'url' => '/api/v1/theme/{themeId}/enable',
  87. 'verb' => 'PUT',
  88. ],
  89. [
  90. 'name' => 'userTheme#disableTheme',
  91. 'url' => '/api/v1/theme/{themeId}',
  92. 'verb' => 'DELETE',
  93. ],
  94. ]
  95. ];