aboutsummaryrefslogtreecommitdiffstats
path: root/apps/provisioning_api/appinfo
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2016-09-19 19:43:47 +0200
committerJoas Schilling <coding@schilljs.com>2016-10-21 09:09:23 +0200
commit0b1fb180a53fc4e533e2f194977293bc509c5df3 (patch)
treed28abeb617a3eaf2bee8d97bd284fab126d4cd3f /apps/provisioning_api/appinfo
parent50b6ee67cb025332f1ec7012d3705150ef5a165a (diff)
downloadnextcloud-server-0b1fb180a53fc4e533e2f194977293bc509c5df3.tar.gz
nextcloud-server-0b1fb180a53fc4e533e2f194977293bc509c5df3.zip
Make AppConfig part of the public API
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'apps/provisioning_api/appinfo')
-rw-r--r--apps/provisioning_api/appinfo/routes.php17
1 files changed, 9 insertions, 8 deletions
diff --git a/apps/provisioning_api/appinfo/routes.php b/apps/provisioning_api/appinfo/routes.php
index a7366a32a06..04a34fba903 100644
--- a/apps/provisioning_api/appinfo/routes.php
+++ b/apps/provisioning_api/appinfo/routes.php
@@ -26,12 +26,7 @@
*
*/
-use OCA\Provisioning_API\Apps;
-use OCA\Provisioning_API\Users;
-use OCP\API;
-
-$app = new \OCA\Provisioning_API\AppInfo\Application();
-$app->registerRoutes($this, [
+return [
'ocs' => [
// Apps
['root' => '/cloud', 'name' => 'Apps#getApps', 'url' => '/apps', 'verb' => 'GET'],
@@ -46,7 +41,7 @@ $app->registerRoutes($this, [
['root' => '/cloud', 'name' => 'Groups#deleteGroup', 'url' => '/groups/{groupId}', 'verb' => 'DELETE'],
['root' => '/cloud', 'name' => 'Groups#getSubAdminsOfGroup', 'url' => '/groups/{groupId}/subadmins', 'verb' => 'GET'],
- //Users
+ // Users
['root' => '/cloud', 'name' => 'Users#getUsers', 'url' => '/users', 'verb' => 'GET'],
['root' => '/cloud', 'name' => 'Users#addUser', 'url' => '/users', 'verb' => 'POST'],
['root' => '/cloud', 'name' => 'Users#getUser', 'url' => '/users/{userId}', 'verb' => 'GET'],
@@ -61,5 +56,11 @@ $app->registerRoutes($this, [
['root' => '/cloud', 'name' => 'Users#addSubAdmin', 'url' => '/users/{userId}/subadmins', 'verb' => 'POST'],
['root' => '/cloud', 'name' => 'Users#removeSubAdmin', 'url' => '/users/{userId}/subadmins', 'verb' => 'DELETE'],
+ // Config
+ ['name' => 'AppConfig#getApps', 'url' => '/api/v1/config/apps', 'verb' => 'GET'],
+ ['name' => 'AppConfig#getKeys', 'url' => '/api/v1/config/apps/{app}', 'verb' => 'GET'],
+ ['name' => 'AppConfig#getValue', 'url' => '/api/v1/config/apps/{app}/{key}', 'verb' => 'GET'],
+ ['name' => 'AppConfig#setValue', 'url' => '/api/v1/config/apps/{app}/{key}', 'verb' => 'POST'],
+ ['name' => 'AppConfig#deleteKey', 'url' => '/api/v1/config/apps/{app}/{key}', 'verb' => 'DELETE'],
],
-]);
+];