cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Want to learn about updates that we've made to the Search experience on the Android and iOS apps?Well, you can learn from Luke on the Mobile App team 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: 
1
Ask
2
Comments

How do i integrate Dropbox chooser with Angular app?

How do i integrate Dropbox chooser with Angular app?

gauravsc
Explorer | Level 3

I am using angular v 7 which is currently stable angular version. I would like to use angular chooser in my application. I have used it with JavaScript/AngularJS . There i can import script with my app key. Here in angular 7, i need it to work with typescript. How do i do that? If chooser is not available in this scenario, how can i mimic it's functionality?

1 Accepted Solution

Accepted Solutions

Re: How do i integrate Dropbox chooser with Angular app?

Greg-DB
Dropboxer

The Dropbox Chooser isn't officially supported in Angular unfortunately, but I'll pass this along as a feature request. 

If you wanted to replicate the functionality using the Dropbox API, you could do so using the following endpoints (or corresponding methods in an SDK/library), but it would be substantially more work:

View solution in original post

6 Replies 6

Re: How do i integrate Dropbox chooser with Angular app?

Greg-DB
Dropboxer

The Dropbox Chooser isn't officially supported in Angular unfortunately, but I'll pass this along as a feature request. 

If you wanted to replicate the functionality using the Dropbox API, you could do so using the following endpoints (or corresponding methods in an SDK/library), but it would be substantially more work:

Re: How do i integrate Dropbox chooser with Angular app?

gauravsc
Explorer | Level 3

Thanks @Greg-DB for quick reply.

What i need is link of users file, which is returned by chooser. i will try to find alternative way to do it. 

Re: How do i integrate Dropbox chooser with Angular app?

Greg-DB
Dropboxer

If you use the Dropbox API, the /2/sharing/create_shared_link_with_settings and /2/files/get_temporary_link endpoints can be used to retrieve links equivalent to "preview" or "direct" links from the Chooser, respectively.

Re: How do i integrate Dropbox chooser with Angular app?

gauravsc
Explorer | Level 3

Hi Greg, 

Thanks for reverting.

I would like to share more info for my usecase. May be you can suggest the best way to achive what i need. 

Is there any way i can send private message?So i can share more details.

Re: How do i integrate Dropbox chooser with Angular app?

Greg-DB
Dropboxer

Yes, if you would like to request API support privately, you can do so here.

Re: How do i integrate Dropbox chooser with Angular app?

dbrw
New member | Level 2

this works... somewhere in your component.ts: (remember the script tag in index.html or wherever)

const options = {

  success: (files) => {

    // do something

  },

};

const dropbox = (window as any).Dropbox;

const dropboxBtn = dropbox.createChooseButton(options);

document.getElementById('<your div id>').appendChild(dropboxBtn);

 

Who's talking

Top contributors to this post

  • User avatar
    dbrw New member | Level 2
  • User avatar
    Greg-DB Dropboxer
  • User avatar
    gauravsc Explorer | Level 3
What do Dropbox user levels mean?
Need more support?