{"id":16748707,"url":"https://github.com/marcandre/libraries_io","last_synced_at":"2025-07-01T22:34:14.680Z","repository":{"id":56881125,"uuid":"148848196","full_name":"marcandre/libraries_io","owner":"marcandre","description":"API wrapper for libraries.io","archived":false,"fork":false,"pushed_at":"2018-12-21T22:04:53.000Z","size":163,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-18T23:22:23.713Z","etag":null,"topics":["librariesio","wrapper-api"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/marcandre.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-14T22:34:53.000Z","updated_at":"2024-05-27T11:25:42.000Z","dependencies_parsed_at":"2022-08-20T13:00:39.322Z","dependency_job_id":null,"html_url":"https://github.com/marcandre/libraries_io","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/marcandre/libraries_io","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcandre%2Flibraries_io","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcandre%2Flibraries_io/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcandre%2Flibraries_io/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcandre%2Flibraries_io/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/marcandre","download_url":"https://codeload.github.com/marcandre/libraries_io/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcandre%2Flibraries_io/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261335478,"owners_count":23143526,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["librariesio","wrapper-api"],"created_at":"2024-10-13T02:13:27.344Z","updated_at":"2025-07-01T22:34:14.572Z","avatar_url":"https://github.com/marcandre.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Build Status](https://travis-ci.org/marcandre/libraries_io.svg?branch=master)](https://travis-ci.org/marcandre/libraries_io) [![Gem Version](https://badge.fury.io/rb/libraries_io.png)](https://rubygems.org/gems/libraries_io)\n\n\n# LibrariesIO\n\nThis is a wrapper for [Libraries.io](https://libraries.io/api#project-dependencies)'s API.\n\nIt implements it in about 100 lines, thanks to the [`tlaw` gem](https://github.com/molybdenum-99/tlaw).\n\n## Installation\n\n1) Add this line to your application's Gemfile:\n\n```ruby\ngem 'libraries_io'\n```\n\nAnd then execute:\n\n    $ bundle\n\n2) Get an API key [from Libraries.io](https://libraries.io/account). [A section below](#api-key) lists the different way to specify it.\n\n## Usage\n\nExample:\n\n```\napi = LibrariesIO.new(api_key: 'your_key')\n\napi.search('some_name') # =\u003e results\n\napi.platform('rubygems').project('rails').contributors # =\u003e list of contributors\n\n# Shortcut to platforms provided:\napi.rubygems.project('rails') # ... same\n```\n\nThanks to the `tlaw` gem, the mapping should be pretty obvious and you can check the API source for details, or use `inspect` or `describe`:\n\n```\napi.platform('rubygems').project('rails')\n# =\u003e #\u003cproject(id: \"rails\") endpoints: info, dependencies, dependents, dependent_repositories, contributors, sourcerank, usage; docs: .describe\n\napi.platform('rubygems').project('rails').describe\n# =\u003e .project(id: \"rails\")\n#  @param id\n#\n#  Endpoints:\n#\n#  .info()\n#    Get information about a package and it's versions\n#\n#  .dependencies(version=\"latest\")\n#    Get a list of dependencies for a version of a project\n#\n#  .dependents()\n#    Get packages that have at least one version that depends on a given project\n#\n#  .dependent_repositories()\n#    Get repositories that depend on a given project\n#\n#  .contributors()\n#    Get users that have contributed to a given project\n#\n#  .sourcerank()\n#    Get breakdown of SourceRank score for a given project\n#\n#  .usage()\n#    Get breakdown of version usage for a given project\n\napi.platform('rubygems').project('rails').endpoints[:dependents].describe\n# =\u003e .dependents()\n#  Get packages that have at least one version that depends on a given project\n#\n#  Docs: https://libraries.io/api#project-dependents\n```\n\n### API implemented\n\nAll documented calls are implemented (except \"subscriptions\"):\n\n* [api.platforms](https://libraries.io/api#platforms)\n* [api.search(q, sort: nil, languages: nil, licenses: nil, keywords: nil, platforms: nil)](https://libraries.io/api#project-search)\n* [api.platform(platform_id=nil).project(id=nil).info](https://libraries.io/api#project)\n* [api.platform(platform_id=nil).project(id=nil).dependencies(version=\"latest\")](https://libraries.io/api#project-dependencies)\n* [api.platform(platform_id=nil).project(id=nil).dependents](https://libraries.io/api#project-dependents)\n* [api.platform(platform_id=nil).project(id=nil).dependent_repositories](https://libraries.io/api#project-dependent-repositories)\n* [api.platform(platform_id=nil).project(id=nil).contributors](https://libraries.io/api#project-contributors)\n* [api.platform(platform_id=nil).project(id=nil).sourcerank](https://libraries.io/api#project-sourcerank)\n* [api.platform(platform_id=nil).project(id=nil).usage](https://libraries.io/api#project-usage)\n* [api.repository(owner:, name:, host: \"github\").info](https://libraries.io/api#repository)\n* [api.repository(owner:, name:, host: \"github\").dependencies](https://libraries.io/api#repository-dependencies)\n* [api.repository(owner:, name:, host: \"github\").projects](https://libraries.io/api#repository-projects)\n* [api.user(name, host: \"github\").info](https://libraries.io/api#user)\n* [api.user(name, host: \"github\").repositories](https://libraries.io/api#user-repositories)\n* [api.user(name, host: \"github\").projects](https://libraries.io/api#user-projects)\n* [api.user(name, host: \"github\").repository_contributions](https://libraries.io/api#user-repository-contributions)\n* [api.user(name, host: \"github\").dependencies(platform: nil)](https://libraries.io/api#user-dependencies)\n\n*Note*: All API endpoints accept parameters `page` and `per_page`.\n\n### API Key\n\nYou can specify the API key in various ways:\n\n* providing it when instantiating an API: `LibrariesIO.new(api_key: 'your_key')`\n* as an environment variable `LIBRARIES_IO_API_KEY`\n* setting the global `LibrariesIO.api_key = \"your_key\"` after the library is loaded\n* writing it in a local file `.libraries_io_api_key`\n\n## Development\n\nAfter checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.\n\nTo install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/marcandre/libraries_io. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.\n\n## License\n\nThe gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).\n\n## Code of Conduct\n\nEveryone interacting in the LibrariesIO project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/marcandre/libraries_io/blob/master/CODE_OF_CONDUCT.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarcandre%2Flibraries_io","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmarcandre%2Flibraries_io","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarcandre%2Flibraries_io/lists"}