Skip to content

lininglink/sb

Repository files navigation

Sb

This is a Ruby gem can call Social Blade Business API.

Installation

Install the gem and add to the application's Gemfile by executing:

bundle add sb --github=lininglink/sb

This gem is NOT on rubygems.org. Do not run gem install sb or bundle add sb (there is a name of this gem for a different gem)

Usage

Environment Variable: SB_CLIENT_ID, SB_CLIENT_TOKEN

With that, you may try following.

params = { query: 'subscribers', page: 0 }
request = Sb::HTTPRequest.new path: "/b/youtube/top", params: params
request.run.body

Or

params = { query: 'UCEWha6SK0hfU9Mqoo9vNwwA', history: 'archive', 'allow-stale' => false }
request = Sb::HTTPRequest.new path: "/b/youtube/statistics", params: params
request.run.body

Development

After checking out the repo, run bin/setup to install dependencies. Then, run rake test to run the tests. You can also run bin/console for an interactive prompt that will allow you to experiment.

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/lininglink/sb. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the code of conduct.

License

The gem is available as open source under the terms of the MIT License.

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published