API for other apps?
Hello - would it be possible to use this app to provide API access to notes from (web)apps?.
Context: I am currently experimenting with Svelte / Node reading/writing notes. I have tried via the native Nextcloud WebDAV API. There are issues with CORS headers - I understand the native Nextcloud API was not designed for the 'front end', though it does works OK from a 'backend' node server.
It works perfectly fine to directly use webdav on the frontend. Key is authentication to the Nextcloud server. I wrote https://apps.nextcloud.com/apps/webapppassword to generate temporary tokens for web-apps, there is a link to an example on the page.
Thanks for the pointers. I am always still getting CORS issues in the browser context, but same code suceeds in the backend (i.e. node server). I added in the WebAppPassword 'Allowed origins' - though not working so far. I am using the following node library https://www.npmjs.com/package/webdav. Will try your example maybe next.
Did you configure the origins, that should be able to access the nextcloud server?
Hi - yes, - currently just development addresses: http://localhost:3000,http://localhost:3003
You might have issues accessing https (your nextcloud server) from http.