Giter Club home page Giter Club logo

dropbox-sdk-ruby's Introduction

Dropbox Core SDK for Ruby

A Ruby library that for Dropbox's HTTP-based Core API.

   https://www.dropbox.com/developers/core/docs

----------------------------------
Setup

You can install this package using 'gem':

   # gem install dropbox-sdk

----------------------------------
Getting a Dropbox API key

You need a Dropbox API key to make API requests.
- Go to: https://dropbox.com/developers/apps
- If you've already registered an app, click on the "Options" link to see the
  app's API key and secret.
- Otherwise, click "Create an app" to register an app.  Choose "Full Dropbox" or
  "App Folder" depending on your needs.
  See: https://www.dropbox.com/developers/reference#permissions

----------------------------------
Using the Dropbox API

Full documentation: https://www.dropbox.com/developers/core/

Before your app can access a Dropbox user's files, the user must authorize your
application using OAuth 2.  Successfully completing this authorization flow
gives you an "access token" for the user's Dropbox account, which grants you the
ability to make Dropbox API calls to access their files.

- Authorization example for a web app: web_file_browser.rb
- Authorization example for a command-line tool:
  https://www.dropbox.com/developers/core/start/ruby

Once you have an access token, create a DropboxClient instance and start making
API calls.

You only need to perform the authorization process once per user.  Once you have
an access token for a user, save it somewhere persistent, like in a database.
The next time that user visits your app, you can skip the authorization process
and go straight to making API calls.

----------------------------------
Running the Examples

There are example programs included in the tarball.  Before you can run an
example, you need to edit the ".rb" file and put your Dropbox API app key and
secret in the "APP_KEY" and "APP_SECRET" constants.

----------------------------------
Running the Tests

# gem install bundler

# bundle install
# cd test
# DROPBOX_RUBY_SDK_ACCESS_TOKEN=<oauth2-access-token> bundle exec ruby sdk_test.rb

dropbox-sdk-ruby's People

Contributors

3zcurdia avatar anoopr avatar cakoose avatar christiangenco avatar gkopylov avatar goooooouwa avatar jackdanger avatar leah avatar northnose avatar seanreid avatar smangelsdorf avatar spike01 avatar timpetricola avatar varenc avatar yadomi avatar yatish27 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.