We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
mrivera
5 years agoExplorer | Level 4
Dropbox v2 api. Javascript app installed in Windows Server behind proxy
Hi all,
I have this app which was built in Javascript (Meteor). Basically, the user saves some Word documents in Dropbox, using the DB web interfase. Then, users use the app to pass some data ...
Здравко
5 years agoLegendary | Level 20
mrivera wrote:...
Does the api works through an specific address?
...
Hi mrivera,
While the words are going on about network API, there is always some kind of address (either domain name or IP). In particular case addresses are pointed by domain names.
mrivera wrote:
...Can I ask the network admin people to open some IP or Port or both?
I mean, can I configure (or ask the appropiate person) the proxy to allow making such calls?
...
🤔 Does your proxy restrict you to make external connection? If there is some firewall and the settings are restrictive for external connections (for some reason, which is something unusual), then you should ask for access. Are you restricted to access Dropbox site on the particular machine? If not, most likely you don't have to do anything. 😉
mrivera wrote:
...FetchError: request to https://api.dropboxapi.com/2/files/list_folder failed, reason: connect ETIMEDOUT 162.125.5.19:443
So, there can be some way to config the proxy so those api calls go through?
...
🙂 Don't think for "way to config the proxy"! On first place you should think for way to connect to the proxy. The error, you get, shows 2 things: the application successfully resolve the domain name to IP (i.e. your DNS works) and outbound connections are restricted when skipping proxy (something expected). The pointed IP and port here (something which confuses you most probably) represent address of target Dropbox server. That is NOT your machine/network address or port! 😉 Again, if your firewall (if any) doesn't restrict access to this address (most likely), you shouldn't worry about this address and the proxy config. The only thing you have to do is, as Greg-DB mentioned, make the proxy connection possible, either yourself or wait for new SDK release dealing with this. That's it.
Hope this clarifies matter.
mrivera
5 years agoExplorer | Level 4
Hi (again),
I was just watching this reply in an Stack Overflow thread:
def get_my_proxy():
""" Static method to get proxy
"""
proxy = '134.245.32.30:80'
http_proxy = "http://" + proxy
https_proxy = "https://" + proxy
ftp_proxy = "ftp://" + proxy
proxyDict = {
"http": http_proxy,
"https": https_proxy,
"ftp": ftp_proxy
}
return proxyDict
import dropbox
access_token = 'myawesomeaccesstoken'
mysesh = dropbox.create_session(1,get_my_proxy())
dbx = dropbox.Dropbox(access_token,session=mysesh)
# Test the connection
dbx.users_get_current_account()I was wondering ... isn't something like this what I am after, *but* in JavaScript, not Python??
Why is this possible in Python and not in JS?
Many thanks for your help ...
- Greg-DB5 years ago
Dropbox Community Moderator
mrivera The API v2 Python and JavaScript SDKs are different code bases and may offer different features like this. I can't offer insight on why one may have something like this implemented and the other doesn't, but I've sent this along as a feature request.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!