I am attempting to manage our nextcloud users from a seperate PHP app. I wanted to test this provisioning API from the command line using curl. I attempted to following curl command but I get a status code 997. I understand this is possibly to do with the “admin” user in the command not being logged in or maybe how nextcloud handles CSF tokens.
Any tips on where to go to from here. I’m not all that advanced on this sort of integration but I will keep attempting to get it to work.
Thanks for any examples / advice.
# curl http://admin:email@example.com/nextcloud/ocs/v1.php/cloud/users -H “OCS-APIRequest: true”
Response:<?xml version="1.0"?> failure 997 Current user is not logged in