Skip to content

Quota missing in "get user" API request before the user logged in first #7212

@dachinat

Description

@dachinat

When having user created from Nextcloud web interface a response from API request

curl --http1.1 -u myuser:mypass -X GET 'https://myhost.com/ocs/v1.php/cloud/users/myuser' -H "OCS-APIRequest: true"

contains

<quota>
   <free>53687091200</free>
   <used>0</used>
   <total>53687091200</total>
   <relative>0</relative>
   <quota>53687091200</quota>
</quota>

However, if I create an user with CLI

curl --http1.1 -u myuser:mypass -X POST 'https://myhost.com/ocs/v1.php/cloud/users' -d 'userid=myuser1&password=somePwd!1' -H "OCS-APIRequest: true"

and update quota

curl --http1.1 -u myuser:mypass -X PUT 'https://myhost.com/ocs/v1.php/cloud/users/myuser1' -d 'key=quota&value=10GB' -H "OCS-APIRequest: true"

Then quota in the response when retrieving user is

<quota/>

It is being changed if viewed with web interface, though.

I have tried this with v2.php API as well.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions