The Open Collaboration Services (OCS) is an open and vendor-independent REST and WebDAV based API designed to make it easy to connect apps to a content collaboration platform.[1]
The OCS API provides basic file handling features such as file access, sharing, versioning and commenting. It also supports communication (chat, video calls), calendaring, tasks and more.
The OCS API allows for the integration of web communities and web-based services into desktop and mobile applications. It allows the exchange of relevant data from a social network between the site and clients such as other websites and applications or widgets running locally on the user's machine or mobile device. The protocol is designed so that all applications can access multiple services providing OCS APIs.
The initial API design was done by openDesktop.org as part of the Social Desktop, especially as a cross-desktop backend provider.[2] The API was standardised by freedesktop.org so that third-party providers are able to implement OCS API. Currently, Nextcloud implements and develops the OCS API, with parts also supported in various other projects and by many third party apps and tools.[3]
Non-KDE environments using the API in the past included the Maemo Downloads application store[4] and Apps for MeeGo.[5]
The OCS API documentation [6] lists several modules. Here are the key OCS modules:
The OCS API Viewer [7] is a Nextcloud app where you can interactively discover APIs and try them out on your own instance from the browser.
For example, if you wanted to update a (file) share, you can go to file_sharing –> shareapi –> update a share and add the file ID. Hit “Send API request” and you can see the response from the server, and how the share was created. On top of that, it shows you code snippets for many different programming languages for executing this request.