Remote sources (Google Drive, Dropbox, OneDrive, -

Pull files straight from cloud storage - no local copy needed

Six built-in cloud sources. AjaxUploader ships first-class pickers for Google Drive, OneDrive, Dropbox, Box, Unsplash, and the Companion broker - browser OAuth implicit flow for the direct pickers, or server-side OAuth via the Companion broker when the browser should never see a token. Each picked file's download URL flows into the server-side importFromUrl() pipeline, streamed through your provider with the same NDJSON live-progress contract as URL import. Extend further via AjaxUploader.registerRemoteSource(name, source) for any custom file portal (SharePoint, Egnyte, internal DMS).

Registering a custom source
AjaxUploader.registerRemoteSource('dropbox', {
 title: 'Dropbox',
 icon: '<svg viewBox=...>...</svg>', // SVG markup or img URL ready: function () { return !!window.Dropbox; },

 pick: function (uploader) {
 return new Promise(function (resolve, reject) {
 window.Dropbox.choose({
 multiselect: true,
 linkType: 'direct',
 success: function (files) {
 resolve(files.map(function (f) {
 return { url: f.link, fileName: f.name, fileSize: f.bytes };
 }));
 },
 cancel: function () { reject(new Error('cancelled')); }
 });
 });
 }
});

AjaxUploader.create('#uploader', {
 remoteSources: ['googledrive', 'dropbox']
});
RemoteFile shape returned from pick()
{
 url: 'https://www.googleapis.com/drive/v3/files/abc?alt=media',
 fileName: 'quarterly-report.pdf',
 fileSize: 2_457_600, // optional contentType: 'application/pdf', // optional headers: { 'Authorization': 'Bearer ya29...' } // optional
}
Wire flow
  1. User clicks the source button rendered in the uploader chrome.
  2. Adapter's pick() runs - typically opens an OAuth popup + provider's native file picker.
  3. On select -> resolves with a RemoteFile (or array).
  4. Each item is handed to uploader.importFromUrl(url, { fileName, contentType, headers }).
  5. The server /import-url endpoint fetches the URL (using any provided Authorization header) and streams through your IUploaderProvider with live NDJSON progress.
Built-in: Google Drive (no server broker needed)

Uses Google Picker + Identity Services. The browser opens the OAuth popup, gets an access token, passes it to Picker, then forwards the token as Authorization when the server fetches the file from Drive's REST API. The token never goes to your server - just the URL + the bearer.

Also available
  • Companion broker - a self-hosted Node OAuth broker for Dropbox, Box, Drive, and OneDrive. Tokens stay server-side and never reach the browser; supports proxy and server-to-destination modes.
  • Unsplash source - search and import royalty-free imagery directly into the queue.
  • Per-source MIME / size filters at picker-time via options.