Home

Awesome

buffer

buffer is a Buffer API Wrapper written in Ruby. It provides more thorough API coverage than the existing gem.

Installation

Coverage Status Build Status Code Climate

For now please git clone git@github.com:bufferapp/buffer-ruby.git the repo

Or

Add this line to your application's Gemfile to include HEAD code:

gem 'buffer', :github => 'bufferapp/buffer-ruby'

And then execute:

$ bundle

Or install RubyGems version, which will receive more attention to stability:

$ gem install buffer

Usage

export BUFFER_ACCESS_TOKEN="1/jjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj" # (BufferApp OAuth Access Token)
export BUFFER_PROFILE_ID="0"                                    # (default of 0)

If you wish to post to multiple ids from the commandline, BUFFER_PROFILE_ID accepts a comma delimited array of integers, ie BUFFER_PROFILE_ID="0,1". This will post to both 0 and 1 index in your profiles list.

Access Token Instructions

How to Get Started:

Example

The example below will use your Buffer account and schedule an update to be posted on your connected profiles with the specified IDs.

client = Buffer::Client.new(ACCESS_TOKEN)
client.create_update(
  body: {
    text:
      "Today's artist spotlight is on #{artist_name}.
      Check out the track, #{track_title}.",
    profile_ids: [
      '...',
      '...',
    ]
  },
)

TODO:

Future versions will integrate with Buffer-OAuth system.

Raise error if message is beyond the character limit.

API Coverage

Implemented

Further Details API Coverage

Not Implemented

Supported Ruby Implementations

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

Issues, refactoring, and feedback are all welcome.

Also, this project is newcomer friendly!! We'd love to be your first Open Source Software contribution and would be happy to assist in that process.

Crafted with care by Zander. Reach out and say hi at @_ZPH or civet.ws