Security News
PyPI Now Supports iOS and Android Wheels for Mobile Python Development
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Bark is a Ruby Gem wrapper on the Open Tree of Life API. It was written over the course of the OpenTree hackathon At present it seeks to provide a simple (level 1 in terms of hackathon speak) wrapper over all of the API calls available, returning a native json object for each response. It also acts as a sanity checker on the API calls themselves, running a suite of unit tests shared by related wrappers in Python and R.
Bark is written targetting Ruby 2.1.x.
Add this line to your application's Gemfile:
gem 'bark'
And then execute:
$ bundle
Or install it yourself as:
$ gem install bark
Bark is broken down into Request and Response objects. These are additionally wrapped with a set of helper methods that map 1:1 with the Open Tree URLs. Binding method names follow a convention adopted by the related Python and R frameworks.
In your script:
require 'bark' # => true
Bark.tol_about # => { big hash }
Pass parameters like so:
Bark.get_study(params: {:study_id => '2113'}) # => {big json response}
Parameter keys can be symbols or strings. Available methods are listed here.
request = Bark::Request::Studies.new(method: :get_study, params: {study_id: '2113'}) # => #<Bark::Request::Studies:0x0000010310d340 @method=:get_study, @params={:study_id=>"2113"}, @uri=#<URI::HTTP:0x0000010310c508 URL:http://devapi.opentreeoflife.org/v2/study/2113>>
Pre-check the validity of the requst (NOTE: mapping/checking is in development)
request.valid? # => true
Get a response:
response = Bark::Response.new(request: request) # => #<Bark::Response:0x0000010334c138 @json={ ... big response ... }
response.json # => { ... big response ... }
Documentation is autogenerated at RubyDoc.info
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)Bark is open source, it is available under the BSD licence.
FAQs
Unknown package
We found that bark demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.