{"id":20851656,"url":"https://github.com/emsk/resas_kit","last_synced_at":"2025-05-12T04:32:13.921Z","repository":{"id":56891875,"uuid":"74594492","full_name":"emsk/resas_kit","owner":"emsk","description":"Ruby wrapper for the RESAS API.","archived":false,"fork":false,"pushed_at":"2021-06-11T14:40:18.000Z","size":68,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-01T00:43:31.970Z","etag":null,"topics":["api-client","gem","resas","ruby"],"latest_commit_sha":null,"homepage":null,"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/emsk.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-11-23T16:26:26.000Z","updated_at":"2021-06-11T14:40:21.000Z","dependencies_parsed_at":"2022-08-21T01:20:12.672Z","dependency_job_id":null,"html_url":"https://github.com/emsk/resas_kit","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emsk%2Fresas_kit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emsk%2Fresas_kit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emsk%2Fresas_kit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emsk%2Fresas_kit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/emsk","download_url":"https://codeload.github.com/emsk/resas_kit/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253675616,"owners_count":21945945,"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":["api-client","gem","resas","ruby"],"created_at":"2024-11-18T03:14:28.593Z","updated_at":"2025-05-12T04:32:13.558Z","avatar_url":"https://github.com/emsk.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ResasKit\n\n[![Gem Version](https://badge.fury.io/rb/resas_kit.svg)](https://badge.fury.io/rb/resas_kit)\n[![Build Status](https://github.com/emsk/resas_kit/actions/workflows/build.yml/badge.svg)](https://github.com/emsk/resas_kit/actions/workflows/build.yml)\n[![Build Status](https://travis-ci.org/emsk/resas_kit.svg?branch=main)](https://travis-ci.org/emsk/resas_kit)\n[![Build status](https://ci.appveyor.com/api/projects/status/fovsqoa5omgfsard?svg=true)](https://ci.appveyor.com/project/emsk/resas-kit)\n[![Build Status](https://dev.azure.com/emsk/resas_kit/_apis/build/status/emsk.resas_kit?branchName=main)](https://dev.azure.com/emsk/resas_kit/_build/latest?definitionId=6\u0026branchName=main)\n[![Codecov](https://codecov.io/gh/emsk/resas_kit/branch/main/graph/badge.svg)](https://codecov.io/gh/emsk/resas_kit)\n[![Code Climate](https://codeclimate.com/github/emsk/resas_kit/badges/gpa.svg)](https://codeclimate.com/github/emsk/resas_kit)\n[![Inline docs](http://inch-ci.org/github/emsk/resas_kit.svg?branch=main)](http://inch-ci.org/github/emsk/resas_kit)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE.txt)\n\nRuby wrapper for the [RESAS API](https://opendata.resas-portal.go.jp).\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'resas_kit'\n```\n\nAnd then execute:\n\n```sh\n$ bundle\n```\n\nOr install it yourself as:\n\n```sh\n$ gem install resas_kit\n```\n\n## Usage\n\n```ruby\nrequire 'resas_kit'\n\nclient = ResasKit::Client.new(api_key: '1234567890ABCDEFGHIJ1234567890abcdefghij')\n\nresponse = client.get('prefectures')\nresponse.body # get body\nresponse.headers # get headers\nresponse.status # get status\n\nclient.get('tourism/foreigners/forFrom', year: 2016, pref_code: '32', purpose: 2, add_area: '31,33') # underscored key\nclient.get('tourism/foreigners/forFrom', year: 2016, prefCode: '32', purpose: 2, addArea: '31,33') # camelized key\nclient.get_tourism__foreigners__for_from(year: 2016, pref_code: '32', purpose: 2, add_area: '31,33') # ghost method\n\nclient.get('prefectures').body.result[0].pref_name # method chaining\n```\n\n## ENV\n\n| ENV Variable | Description |\n| :----------- | :---------- |\n| `RESAS_API_KEY` | Your RESAS API KEY |\n| `RESAS_API_VERSION` | Target RESAS API VERSION |\n\nYou can create instance more easily.\n\n```ruby\nclient = ResasKit::Client.new\n```\n\n## Supported RESAS API Version\n\nResasKit supports RESAS API [v1](https://opendata.resas-portal.go.jp/docs/api/v1/index.html).\n\nResasKit's API documentation is [here](http://www.rubydoc.info/gems/resas_kit).\n\n## Supported Ruby Versions\n\nRuby 2.0.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7\n\n## Contributing\n\n1. Fork it ( https://github.com/emsk/resas_kit/fork )\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Add some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create a new Pull Request\n\n## License\n\n[MIT](LICENSE.txt)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femsk%2Fresas_kit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Femsk%2Fresas_kit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femsk%2Fresas_kit/lists"}