dropbox-api

Locally calculate dropbox hash of files

瘦欲@ 提交于 2019-12-05 05:57:31
Dropbox rest api, in function metatada has a parameter named "hash" https://www.dropbox.com/developers/reference/api#metadata Can I calculate this hash locally without call any remote api rest function? I need know this value to reduce upload bandwidth. https://www.dropbox.com/developers/reference/content-hash explains how Dropbox computes their file hashes. A Python implementation of this is below: import hashlib import math import os DROPBOX_HASH_CHUNK_SIZE = 4*1024*1024 def compute_dropbox_hash(filename): file_size = os.stat(filename).st_size num_chunks = int(math.ceil(file_size/DROPBOX

using dropbox as a server for my django app

[亡魂溺海] 提交于 2019-12-05 05:53:02
I dont know if at all i make any sense, but this popped up in my mind. Can we use the 2gb free hosting of dropbox to put our django app over there and do some hacks to run our app? The point you need to understand is: can you run django without djagno installed? Can django be installed on a usb-drive? Dropbox is but a cloud storage service NOT cloud hosting service. To store you do not require RAM and processors while for hosting you do. Hence the answer is NO. If you are okay with configuring apache etc. you can go for VPS. If not try some managed servers. If you dont want to spend much and

Evaluation of a strategy to sync Core Data with Dropbox

主宰稳场 提交于 2019-12-05 02:06:28
问题 This question is about using Dropbox to sync an sqlite Core Data store between multiple iOS devices. Consider this arrangement: An app utilizes a Core Data store, call it local.sql , saved in the app's own NSDocumentDirectory The app uses the Dropbox Sync API to observe a certain file in the user's Dropbox, say, user/myapp/synced.sql The app observes NSManagedObjectContextDidSaveNotification , and on every save it copies local.sql to user/myapp/synced.sql , thereby replacing the latter. When

Dropbox file unique identifier - RESTful API

狂风中的少年 提交于 2019-12-04 23:55:01
Is there any unique identifier associated with a Dropbox file that doesn't change with revisions/changes/renaming, that can be accessed via the RESTful API? I want to store it in the database and keep track of some operations on the file. Unfortunately, no, the Dropbox API does not currently expose any sort of file ID or hash like this. Edit: The Dropbox API v2 does now offer file IDs that persist across moves/renames. You can find more information under "Path formats" in the documentation . The file ID is available as the id field on the FileMetadata object, e.g., as returned by /files/get

upload file to dropbox with google app script using save_url from Dropbox API

一个人想着一个人 提交于 2019-12-04 22:06:40
I'm trying to implement what is described here in a google app script. But i don't have enough experience so see what is wrong. So any help will be appreciated. function Gmail2Dropbox() { var dropboxTOKEN = 'XXXxxx'; var folderName = "Folder"; var folder = DriveApp.getFoldersByName(folderName).next(); var files = folder.getFiles(); while (files.hasNext()){ var file = files.next(); var fileName = file.getName(); var fileid = file.getId(); var path = 'path/'+fileName; var dropboxurl = 'https://api.dropboxapi.com/1/save_url/auto/'+path; var fileurl = 'https://drive.google.com/uc?export=download

ShinyApp - Dropbox authentication with rdrop2

瘦欲@ 提交于 2019-12-04 22:01:57
I stored files on my dropbox and I am accessing them through rdrop2 on a shinyapp hosted at shinyapps.io. The following code works great on my laptop but aborts when I deploy my app on shinyapp.io and freezes an opaque screen. Any clues on why and how to troubleshoot? Thanks a bunch! - stephane Here is the code I am using (from https://github.com/karthik/rdrop2 ): token<-drop_auth() saveRDS(token, "droptoken.rds") token <- readRDS("droptoken.rds") ZIPFile<-drop_read_csv(as.character(ZIPCode),sep="",dtoken=token) And the ShinyApp log : 2015-10-16T17:55:46.965850+00:00 shinyapps[64206]: Warning:

Use of dropbox with core APIs, but avoiding login page

允我心安 提交于 2019-12-04 21:40:10
I want to use Dropbox for my file share application, using Core Dropbox APIs. I am using OAuth 2.0 APIs for authentication (Implicit Grant Method). The issue is, In order to obtain the access token, I need to be logged-in to dropbox account or it redirects me to Dropbox login page. I don't want my users to enter the login crediantials. Is there any way to avoid login process, and directly get access token?? Or Alternatively can I do login using some login api in backend, without user iteraction?? here I am considering a single Dropbox account, whose all necessary crediantials are with me.

Integrate Dropbox in ios app, but without login pop

痴心易碎 提交于 2019-12-04 21:09:26
I want to integrate Dropbox in my app. I have made one sample example using Dropbox document and sample code. But the issue is, I don't want to open login popup. So is there any way so that I can use dropbox without login or some where I can set default login ID Password and automatically do login. so that I can use dropbox directly. Thanks, Hardik Shah Well you could put the files in Dropbox and then share them and use the shared URLs as resources to call. We actually do this for some of our developer blog assets . Hope that helps. Careful not to move the files otherwise the links will break.

How to play streaming video using Dropbox API?

时光总嘲笑我的痴心妄想 提交于 2019-12-04 19:54:22
Now I develope application that play video streaming. My video fild uploaded at dropbox and using Dropbox Core API and media method. Media method , Core API What I made code is this. @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); AndroidAuthSession session = buildSession(); mDBApi = new DropboxAPI<AndroidAuthSession>(session); checkAppKeySetup(); btn_con=(Button)findViewById(R.id.con_btn); btn_con.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { if (mLoggedIn) {

Can Dropbox Saver accept data from createObjectURL()?

こ雲淡風輕ζ 提交于 2019-12-04 16:48:08
The Dropbox Chooser and Saver tools seem very cool for these two tasks: Let the user pick a file from their Dropbox, and the page can download it (i.e., Dropbox-to-client). Let the user choose a destination in their Dropbox to which to save a file sitting at some URL on a server (i.e., server-to-Dropbox). That's asymmetrical. This StackOverflow question asks if it's possible to send a file to Dropbox Saver directly from the client. (This is especially handy if one is writing a client-side-only app, wanting Dropbox to stand in for the server.) A comment in one answer says that the Core API or