diff options
author | Michael Gapczynski <mtgap@owncloud.com> | 2013-01-04 17:18:58 -0800 |
---|---|---|
committer | Michael Gapczynski <mtgap@owncloud.com> | 2013-01-04 17:18:58 -0800 |
commit | 0b13b411893c472ce3102ece5d63de34bf872a8d (patch) | |
tree | 9d85a64dcd50d395837837ba4d5424528e2f3fa4 /ocs/routes.php | |
parent | 934d9dcc42e2d7281e04c6acecdd53ae2a03b25f (diff) | |
parent | 3d23e983908d02fe72f305aeaabbdca05d167e8f (diff) | |
download | nextcloud-server-0b13b411893c472ce3102ece5d63de34bf872a8d.tar.gz nextcloud-server-0b13b411893c472ce3102ece5d63de34bf872a8d.zip |
Merge pull request #1053 from owncloud/ocs_api
External API for ownCloud based on OCS
Diffstat (limited to 'ocs/routes.php')
-rw-r--r-- | ocs/routes.php | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/ocs/routes.php b/ocs/routes.php new file mode 100644 index 00000000000..d77b96fc145 --- /dev/null +++ b/ocs/routes.php @@ -0,0 +1,20 @@ +<?php +/** + * Copyright (c) 2012, Tom Needham <tom@owncloud.com> + * This file is licensed under the Affero General Public License version 3 or later. + * See the COPYING-README file. + */ + +// Config +OC_API::register('get', '/config', array('OC_OCS_Config', 'apiConfig'), 'ocs', OC_API::GUEST_AUTH); +// Person +OC_API::register('post', '/person/check', array('OC_OCS_Person', 'check'), 'ocs', OC_API::GUEST_AUTH); +// Activity +OC_API::register('get', '/activity', array('OC_OCS_Activity', 'activityGet'), 'ocs', OC_API::USER_AUTH); +// Privatedata +OC_API::register('get', '/privatedata/getattribute', array('OC_OCS_Privatedata', 'get'), 'ocs', OC_API::USER_AUTH, array('app' => '', 'key' => '')); +OC_API::register('get', '/privatedata/getattribute/{app}', array('OC_OCS_Privatedata', 'get'), 'ocs', OC_API::USER_AUTH, array('key' => '')); +OC_API::register('get', '/privatedata/getattribute/{app}/{key}', array('OC_OCS_Privatedata', 'get'), 'ocs', OC_API::USER_AUTH); +OC_API::register('post', '/privatedata/setattribute/{app}/{key}', array('OC_OCS_Privatedata', 'set'), 'ocs', OC_API::USER_AUTH); +OC_API::register('post', '/privatedata/deleteattribute/{app}/{key}', array('OC_OCS_Privatedata', 'delete'), 'ocs', OC_API::USER_AUTH); +?> |