Dropbox API / Dropbox Paper

Hello! I’m trying to set up a new action that will export the contents of a draft into a new Dropbox Paper entry. I’m a big fan of this service, primarily because it has a nice interface and a web app that I can use across multiple devices (read: a PC).

I’ve been trying to get an HTTP request setup to send my files over, using their API:

But I’m finding I’m having issues getting JSON to properly render and send in a way that Dropbox’s API (via the “Dropbox-API-Arg” header) can interpret.

Has anyone had success in getting something like this going, with another HTTP service?

Thanks so much!

Could you share a sample script/action of what you’ve got so far?

1 Like

Hi there,

I’ve actually been trying to build an HTTP request in Postman first before throwing it into a Drafts action. The component parts are:

URL: https://api.dropboxapi.com/2/paper/docs/create?


Content-Type: application/octet-stream
Dropbox-API-ARG: {“input_format”: “markdown”}
Authorization: Bearer

I’m seeing various 500 errors and errors asking about my invalid JSON. I’m modulating between using a Body field and leaving it blank, mostly because Dropbox’s API docs don’t explicitly state how to formulate body content, only that it’s allowed in the POST request.

Thanks for your time on this!


Dropbox-API-ARG: {\“input_format\”: \“markdown\”}

That may not be quite right, but I think it has to be an escaped JSON string (and, if it has any characters that need it - ASCII encoded).

Thanks, Greg. I tried escaping the special characters and I’m still getting the error. I saw some similar posts on Dropbox’s dev forums but it doesn’t look like it’s working for me. I think the main problem is, my title and body aren’t proper JSON syntax (because I’m not a developer!).

You may want to circle back on this in a month or two. I plan to add a request method to the Dropbox scripting object that lets you make arbitrary call to their API, similar to the one that is already on the Twitter object. This will handle the OAuth and encoding of params and likely make this a lot easier.

1 Like

Thanks so much! I’ll be excited to see that come to life. I will still use Drafts every single day ‘til then. :slight_smile:

FYI, Dropbox Paper support is now pretty straight forward with access to the entire Dropbox API in v5.4 or greater. Example: