cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Back again with another edition of 'How we use Dropbox', so find out how Emma uses to-do lists to get it all done 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: 

sharing folders using api

sharing folders using api

Mark S.115
New member | Level 1

About a month ago I implemented sharing files via Dropbox in my app. Now I am trying to enable sharing a pair of files via Dropbox (a file and an image). I mention this only because I can currently share a file and then have the app upload the file from the link automatically and it's working great.

When trying to upload from a shared folder... not so great.

Couple of things I noted about the link to a folder, it has /sh/ instead of /s/. Also, it has 2 codes after the /sh/ separated by a "/":
/sh/8r3m3mfhh56qcba/AADjD4x_TJlPTNXpqn5MQ_Lfa

Here is the url I attempted to use to extract a file from this shared folder:
https://www.dropbox.com/sh/8r3m3mfhh56qcba/AADjD4x_TJlPTNXpqn5MQ_Lfa/QuickList.skchar?dl=1

Dropbox threw back an error that said:

Error: Error Domain=NSCocoaErrorDomain Code=3000 "no valid 'aps-environment' entitlement string found for application" UserInfo=0x156aaeb0 {NSLocalizedDescription=no valid 'aps-environment' entitlement string found for application}

Can you offer any advice on this?

3 Replies 3

Re: sharing folders using api

Greg-DB
Dropboxer

When you get a shareable link to a folder, instead of a file, you are expected to get a link /sh/ instead of /s/. When you use dl=1 on a shared link for a folder (/sh/) you should get a zip download of that folder.

Regarding the trouble you're having here, first, is this a sample of an actual link you're trying to us? When I try to access it, using either dl=0 or dl=1, I get a 404 error, e.g., meaning that there isn't anything at the path for the link anymore. If this is the actual link you're trying, that may be related to the issue you're seeing.

Regarding the error message you posted, "no valid 'aps-environment' entitlement string found for application", that isn't something that comes from Dropbox, but rather seems to be an Objective-C error message, e.g.:

https://stackoverflow.com/questions/13432203/no-valid-aps-environment-entitlement-string-found-for-a...

If you're still having trouble with this, can you post your code and output?

Re: sharing folders using api

Greg-DB
Dropboxer

I see, thanks for clarifying. Unfortunately, you can't index files inside a folder via a shared link like that. (That is, you can't add the file name for file in the folder to the original link to get a link to that particular file.) I'm sending this along as a request for a proper way to do this though.

Re: sharing folders using api

Mark S.115
New member | Level 1

Thank you. I can work around it now that I know to stop beating my head against the wall.

Who's talking

Top contributors to this post

  • User avatar
    Mark S.115 New member | Level 1
  • User avatar
    Greg-DB Dropboxer
What do Dropbox user levels mean?
Need more support?