From 1af5fbaec578d11ec7df069e157f95397107e652 Mon Sep 17 00:00:00 2001 From: Morris Jobke Date: Thu, 23 Feb 2017 22:36:16 -0600 Subject: [PATCH 1/3] document user metadata Signed-off-by: Morris Jobke --- developer_manual/client_apis/OCS/index.rst | 67 ++++++++++++++++++++++ developer_manual/client_apis/index.rst | 7 +++ 2 files changed, 74 insertions(+) create mode 100644 developer_manual/client_apis/OCS/index.rst diff --git a/developer_manual/client_apis/OCS/index.rst b/developer_manual/client_apis/OCS/index.rst new file mode 100644 index 000000000..cf59d49bb --- /dev/null +++ b/developer_manual/client_apis/OCS/index.rst @@ -0,0 +1,67 @@ +.. _webdavindex: + +========= +OCS API's +========= + +This document provides a quick overview of the OCS API endpoints supported in Nextcloud. + +All requests need to provide authentication information, either as a Basic Auth header or by passing a set of valid session cookies, if not stated otherwise. + + +---- +Testing requests with curl +---- + +All OCS requests can be easily tested out using :code:`curl` by specifying the request method (:code:`GET`, :code:`PUT`, etc) and setting a request body where needed. + +For example: you can perform a :code:`GET` request to get information about a user: + + +.. code-block:: bash + + curl -u username:password -X GET 'https://cloud.example.com/ocs/v1.php/...' -H "OCS-APIRequest: true" + + +------------- +User metadata +------------- + +Since: 11.0.2, 12.0.0 + +This request returns the available metadata of a user. Admin users can see the information of all users, while a default user only can access it's own metadata. + +.. code:: + + GET /ocs/v1.php/cloud/users/USERID + + +.. code:: xml + + + + + ok + 100 + OK + + + + + true + + 338696790016 + 7438874 + 338704228890 + 0 + -3 + + user@foo.de + admin + +
+ + schiessle +
+
+ diff --git a/developer_manual/client_apis/index.rst b/developer_manual/client_apis/index.rst index 41dbf60f3..74960c0b2 100644 --- a/developer_manual/client_apis/index.rst +++ b/developer_manual/client_apis/index.rst @@ -14,9 +14,16 @@ WebDAV is the main api for file related operations, it supports listing director An overview of how to use the various WebDAV api's can be found at :doc:`WebDAV/index` +--- +OCS +--- + +The OCS API provides all information that are not available via the DAV endpoints. This contains endpoints for user data or sharing capabilities for example. See :doc:`OCS/index` for more details. + .. toctree:: :maxdepth: 2 :hidden: webdav/index + ocs/index From 397c0fa843f3ff1c1a209a4a13ecfe37eb95c4c7 Mon Sep 17 00:00:00 2001 From: Morris Jobke Date: Thu, 23 Feb 2017 22:41:15 -0600 Subject: [PATCH 2/3] notifications API Signed-off-by: Morris Jobke --- developer_manual/client_apis/index.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/developer_manual/client_apis/index.rst b/developer_manual/client_apis/index.rst index 74960c0b2..fa8021217 100644 --- a/developer_manual/client_apis/index.rst +++ b/developer_manual/client_apis/index.rst @@ -20,6 +20,11 @@ OCS The OCS API provides all information that are not available via the DAV endpoints. This contains endpoints for user data or sharing capabilities for example. See :doc:`OCS/index` for more details. +Other OCS API documentations: + +* `Notifications API `_ + + .. toctree:: :maxdepth: 2 :hidden: From acb9988493e51873647dbe303c20be8f0f1c1831 Mon Sep 17 00:00:00 2001 From: Morris Jobke Date: Fri, 24 Feb 2017 12:28:58 -0600 Subject: [PATCH 3/3] add proper links Signed-off-by: Morris Jobke --- developer_manual/client_apis/index.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/developer_manual/client_apis/index.rst b/developer_manual/client_apis/index.rst index fa8021217..bc9aff355 100644 --- a/developer_manual/client_apis/index.rst +++ b/developer_manual/client_apis/index.rst @@ -22,7 +22,8 @@ The OCS API provides all information that are not available via the DAV endpoint Other OCS API documentations: -* `Notifications API `_ +* `Notifications API `_ +* `Notifications API - Register a device for push notifications `_ .. toctree::