{"id":13697511,"url":"https://github.com/techgaun/ex_google","last_synced_at":"2025-04-12T11:52:13.676Z","repository":{"id":57506746,"uuid":"68246984","full_name":"techgaun/ex_google","owner":"techgaun","description":"Google Cloud SDK for Elixir","archived":false,"fork":false,"pushed_at":"2019-09-03T05:27:56.000Z","size":37,"stargazers_count":10,"open_issues_count":2,"forks_count":7,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-26T06:34:36.040Z","etag":null,"topics":["elixir","google-cloud-sdk"],"latest_commit_sha":null,"homepage":null,"language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/techgaun.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":"2016-09-14T22:03:40.000Z","updated_at":"2023-09-05T12:37:08.000Z","dependencies_parsed_at":"2022-08-29T20:01:24.528Z","dependency_job_id":null,"html_url":"https://github.com/techgaun/ex_google","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/techgaun%2Fex_google","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/techgaun%2Fex_google/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/techgaun%2Fex_google/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/techgaun%2Fex_google/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/techgaun","download_url":"https://codeload.github.com/techgaun/ex_google/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248565015,"owners_count":21125414,"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":["elixir","google-cloud-sdk"],"created_at":"2024-08-02T18:00:59.571Z","updated_at":"2025-04-12T11:52:13.652Z","avatar_url":"https://github.com/techgaun.png","language":"Elixir","funding_links":[],"categories":["Uncategorized"],"sub_categories":["Uncategorized"],"readme":"# ExGoogle\n\n[![Build Status](https://semaphoreci.com/api/v1/techgaun/ex_google/branches/master/badge.svg)](https://semaphoreci.com/techgaun/ex_google) [![Hex version](https://img.shields.io/hexpm/v/ex_google.svg \"Hex version\")](https://hex.pm/packages/ex_google) ![Hex downloads](https://img.shields.io/hexpm/dt/ex_google.svg \"Hex downloads\")\n\n\u003e Google Cloud SDK for Elixir\n\nThis is a work in progress. Currently, it supports google places and maps API.\n\n## Installation\n\nIf [available in Hex](https://hex.pm/docs/publish), the package can be installed as:\n\n1. Add `ex_google` to your list of dependencies in `mix.exs`:\n\n```elixir\ndef deps do\n  [{:ex_google, \"~\u003e 0.1.1\"}]\nend\n```\n\nOr from github (recommended for now):\n\n```elixir\ndef deps do\n  [{:ex_google, github: \"techgaun/ex_google\"}]\nend\n```\n\n2. Ensure `ex_google` is started before your application:\n\n```elixir\ndef application do\n  [applications: [:ex_google]]\nend\n```\n\n## Configuration\n\n1. Configure `ex_google` using the appropriate api key and output format. Currently, only json output is supported. Other formats parser are more than welcome.\n\n2. Now, you can use the places and maps api.\n\n```elixir\nconfig :ex_google, api_key: System.get_env(\"GOOGLE_API_KEY\"),\n                   output: \"json\"\n```\n\n## Usage\n\nYou can import and use the google places and maps api as below. Also, note that you can pass any query parameter that google apis support.\n\n### [Google Maps](https://developers.google.com/maps/documentation/geocoding/intro)\n\n```elixir\nalias ExGoogle.Maps.Api, as: Maps\n# google maps reverse geocoding\nMaps.search(%{latlng: \"40.714224,-73.961452\"})\n\n# google maps geocoding\nMaps.search(%{address: \"1600 Amphitheatre Parkway, Mountain View, CA\"})\n\n# Advanced parameters\nMaps.search(%{latlng: \"40.714224,-73.961452\", location_type: \"ROOFTOP|RANGE_INTERPOLATED|GEOMETRIC_CENTER\", result_type: \"street_address\"})\n```\n\n### [Google Places](https://developers.google.com/places/web-service/)\n\n```elixir\nalias ExGoogle.Places.Api, as: Places\n# place detail search\nPlaces.search(%{placeid: \"ChIJL_zTW3FdvIcR2qmNStcaCdA\"})\n\n# text search\nPlaces.search(%{query: \"Restaurant\"}, :text)\n\n# nearby search\nPlaces.search(%{location: \"38,-94\", radius: 1000}, :nearby)\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftechgaun%2Fex_google","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftechgaun%2Fex_google","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftechgaun%2Fex_google/lists"}