tentwentyfour / nextcloud-link

Javascript/Typescript client that communicates with Nextcloud's WebDAV and OCS APIs
MIT License
56 stars 7 forks source link

Added OCS API support #5

Closed rvsteen closed 4 years ago

rvsteen commented 4 years ago

Initial version supporting only a few API calls. As OCS has several methods for each category (users/groups/activity etc.) I have created the method names. For Example, Users will (eventually) have: list, get, enable/disable, delete, add. Alternatively, we could create the methods as put: (sanePath: string, content: Webdav.ContentType) => Promise<void>; get: (sanePath: string) => Promise<string>; users: { get => Promise; list => Promise; delete => Promise; }.

Added new method getProperties to get the properties of a Folder (though it can be used for files as well).

kwisatz commented 4 years ago

You might want to squash those commits before we merge this onto master.

rvsteen commented 4 years ago

@floriansimon1 I fixed the naming. Please let me know a better way if you know one. I've tried several ways, @kevinley had a quick look as well. Curry is not an option due to optional parameters.

floriansimon1 commented 4 years ago

Looks good to me! Excellent work!

rvsteen commented 4 years ago

Closed because @kevinley and I did a manual merge after introducing git flow.