cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Want to know what we learned at IBC? Check out our learnings on media, remote working and more right here.

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

The usage returned by get_space_usage is not updated

The usage returned by get_space_usage is not updated

synology_support
Explorer | Level 4
Below is the response of get_space usage. The used field (eg. 70850370743139) used to update whenever a file is uploaded, but it stopped updating even the file is uploaded, is there a problem in dropbox server now?
{
    "used"70850370743139,
    "allocation": {
        ".tag""team",
        "used"70850370743139,
        "allocated"124244813938688,
        "user_within_team_space_allocated"0,
        "user_within_team_space_limit_type": {
            ".tag""off"
        },
        "user_within_team_space_used_cached"70859152274418
    }
}
Best regards,
Ethan Fang
4 Replies 4

Здравко
Legendary | Level 20

Hi @synology_support,

To be clear what's going on with your account using your application, let's do a test. Wipe temporary all team scopes, if any, out of your application' permissions (and after the test, bring them back, again if any). Execute following commands one by one in the same order:

curl -X POST https://api.dropboxapi.com/2/users/get_space_usage -H 'Authorization: Bearer sl.<YOUR ACCESS TOKEN>' -H 'Content-Type: application/json' --data 'null'
curl -X POST https://content.dropboxapi.com/2/files/upload -H 'Authorization: Bearer sl.<YOUR ACCESS TOKEN>' -H 'Content-Type: application/octet-stream' -H 'Dropbox-API-Arg: {"path":"/some-dummy-file.txt"}' --data '0123456789'
curl -X POST https://api.dropboxapi.com/2/users/get_space_usage -H 'Authorization: Bearer sl.<YOUR ACCESS TOKEN>' -H 'Content-Type: application/json' --data 'null'
curl -X POST https://api.dropboxapi.com/2/files/delete_v2 -H 'Authorization: Bearer sl.<YOUR ACCESS TOKEN>' -H 'Content-Type: application/json' --data '{"path":"/some-dummy-file.txt"}'
curl -X POST https://api.dropboxapi.com/2/users/get_space_usage -H 'Authorization: Bearer sl.<YOUR ACCESS TOKEN>' -H 'Content-Type: application/json' --data 'null'

Replace sl.<YOUR ACCESS TOKEN> to actual access token generated on the application page. Post the result in your next post, so we able see what's going on. Mask the token you will use.

You can do the same test without changing permissions, but have  to add header with your member id to all calls.

Greg-DB
Dropbox Staff

@synology_support Thanks for the report! Здравко detailed some steps to follow to illustrate the issue if you can, which may be helpful. We'll also look into it regardless. I'll follow up here with any news on this.

Greg-DB
Dropbox Staff

@synology_support We've reproduced the issue and are working on a fix.

Greg-DB
Dropbox Staff

@synology_support This should be fixed now. Please let us know if you're still seeing any issues. Thanks!

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    Greg-DB Dropbox Staff
  • User avatar
    Здравко Legendary | Level 20
What do Dropbox user levels mean?