We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
rajshree1996
7 years agoExplorer | Level 3
connect to dropbox in node
// connect with the help of developer token
function DropboxConnect() {
dropbox = DropboxV2Api.authenticate({
token: CONSTANTS.get('DBX_ACCESS_TOKEN')
});
}
DropboxConnect.prototype.getPreviewLink = () => {
dropbox({
resource: 'sharing/create_shared_link_with_settings',
parameters: {
path: "/test2/img1.png"
}
}, (err, result, response) => {
if (err) {
console.log(err);
}
console.log('file link folder', result.url);
return result
})
}
connection like this.
but when I am calling preview link it is not waiting for the dropbox call to get finished.
Is this the wrong way to connect?
1 Reply
- Greg-DB7 years ago
Dropbox Community Moderator
Based on the code you shared, it looks like you're using this third party dropbox-v2-api library. Since that's made by a third party, we can't provide support for it. You may wish to refer to the documentation for it or open an issue there for help using it.
About Discuss Dropbox Developer & API
Make connections with 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!