{"id":19715780,"url":"https://github.com/davidesantangelo/restcountry","last_synced_at":"2025-09-03T18:38:52.406Z","repository":{"id":30067976,"uuid":"33617439","full_name":"davidesantangelo/restcountry","owner":"davidesantangelo","description":"This is a Ruby wrapper library around the API provided by REST Countries http://restcountries.eu","archived":false,"fork":false,"pushed_at":"2021-03-22T11:21:48.000Z","size":128,"stargazers_count":36,"open_issues_count":1,"forks_count":8,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-05T19:03:39.831Z","etag":null,"topics":["rest-countries","ruby","rubygem"],"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/davidesantangelo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-04-08T16:05:38.000Z","updated_at":"2024-08-01T20:05:00.000Z","dependencies_parsed_at":"2022-08-20T16:00:59.273Z","dependency_job_id":null,"html_url":"https://github.com/davidesantangelo/restcountry","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidesantangelo%2Frestcountry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidesantangelo%2Frestcountry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidesantangelo%2Frestcountry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidesantangelo%2Frestcountry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/davidesantangelo","download_url":"https://codeload.github.com/davidesantangelo/restcountry/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251089408,"owners_count":21534512,"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":["rest-countries","ruby","rubygem"],"created_at":"2024-11-11T22:39:23.209Z","updated_at":"2025-04-29T20:30:40.871Z","avatar_url":"https://github.com/davidesantangelo.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Restcountry\n\nThis is a [RubyGem](https://rubygems.org/gems/restcountry) wrapper library around the API provided by\n[Restcountries](https://restcountries.eu).\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'restcountry'\n```\n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install restcountry\n\n## Usage\n\n```ruby\nrequire 'restcountry'\n\n# Find all countries\ncountries = Restcountry::Country.all\n\n# Find a country by name\ncountry = Restcountry::Country.find_by_name('italy')\n\n# Access the country's attributes\ncountry.capital\n#=\u003e Rome\n\ncountry.region\n#=\u003e Europe\n\ncountry.callingCodes\n#=\u003e \"39\"\n\n# Find a country by capital\ncountry = Restcountry::Country.find_by_capital('Rome')\n\ncountry.name\n#=\u003e Italy\n\ncountries = Restcountry::Country.find_by_lang('it')\n\ncountries.first\n#=\u003e Holy See\n\n```\n## Attributes\n\nname, \ncapital, \naltSpellings, \nrelevance, \nregion, \nsubregion, \ntranslations, \npopulation, \nlatlng, \ndemonym, \narea, \ngini, \ntimezones, \nborders, \nnativeName, \ncallingCodes, \ntopLevelDomain, \nalpha2Code, \nalpha3Code, \ncurrencies, \nlanguages\n\n## Credits\nMany thanks to Fayder Florez for his implementation of the API.\n\n## Contributors\n\u003ca href=\"https://github.com/davidesantangelo/restcountry/contributors\"\u003eAll Contributors\u003c/a\u003e\n\n## Related projects\n\n[gocountries](https://github.com/alediaferia/gocountries).\n\n## License\nThe restcountry GEM is released under the MIT License.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavidesantangelo%2Frestcountry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdavidesantangelo%2Frestcountry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavidesantangelo%2Frestcountry/lists"}