1

I'm having some trouble understanding the Dropbox JS api for node.js

after I create an authDriver, how do I route my client to a dropbox access dialog? Suppose they get a route '/applogin' that my express app handles, how do I pass the client to dropbox?

Thanks!

    var Dropbox = require("dropbox");
    var client = new Dropbox.client({
        key: "mykey", secret: "mysecret", sandbox: true
    });
    client.authDriver(new Dropbox.Drivers.NodeServer(8081));
//what comes next?

1 Answer 1

2

After setting up an OAuth driver, authenticating the user is one method call away.

client.authenticate(function(error, client) {
  if (error) {
    return showError(error);
  }
  doSomethingCool(client);
});
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.