diff options
author | Bjoern Schiessle <schiessle@owncloud.com> | 2014-11-24 15:31:52 +0100 |
---|---|---|
committer | Bjoern Schiessle <schiessle@owncloud.com> | 2014-12-04 13:18:13 +0100 |
commit | 698ecbf308d1eae950138bff9edbb0d542c391d0 (patch) | |
tree | 3f6ab525053f56c01f2fcef4792a9756f882ab7d /ocs/routes.php | |
parent | f0e6876f2ec8ec4576ca0ce8bbfee5bd8082dc1f (diff) | |
download | nextcloud-server-698ecbf308d1eae950138bff9edbb0d542c391d0.tar.gz nextcloud-server-698ecbf308d1eae950138bff9edbb0d542c391d0.zip |
OCS API for server-to-server sharing
Diffstat (limited to 'ocs/routes.php')
-rw-r--r-- | ocs/routes.php | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/ocs/routes.php b/ocs/routes.php index 845ee49a46d..567f9ccb23d 100644 --- a/ocs/routes.php +++ b/ocs/routes.php @@ -81,3 +81,33 @@ OC_API::register( 'core', OC_API::USER_AUTH ); + +// Server-to-Server Sharing +$s2s = new \OCA\Files_Sharing\API\Server2Server(); +OC_API::register('post', + '/cloud/shares', + array($s2s, 'createShare'), + 'files_sharing', + OC_API::GUEST_AUTH +); + +OC_API::register('post', + '/cloud/shares/{id}/accept', + array($s2s, 'acceptShare'), + 'files_sharing', + OC_API::GUEST_AUTH +); + +OC_API::register('post', + '/cloud/shares/{id}/decline', + array($s2s, 'declineShare'), + 'files_sharing', + OC_API::GUEST_AUTH +); + +OC_API::register('post', + '/cloud/shares/{id}/unshare', + array($s2s, 'unshare'), + 'files_sharing', + OC_API::GUEST_AUTH +); |