{"id":19368996,"url":"https://github.com/pieropatron/demo_geo_proxy","last_synced_at":"2026-04-12T17:38:49.388Z","repository":{"id":173872548,"uuid":"649634072","full_name":"pieropatron/demo_geo_proxy","owner":"pieropatron","description":"proxy services for Nominatim, OSRM, GeoTZ","archived":false,"fork":false,"pushed_at":"2023-06-09T06:36:14.000Z","size":36,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-06T22:52:35.634Z","etag":null,"topics":["basic-authentication","cache","expressjs","geo-tz","jwt","node-cluster","nominatim","osrm","redis"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/pieropatron.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-06-05T09:57:05.000Z","updated_at":"2023-06-09T06:40:54.000Z","dependencies_parsed_at":null,"dependency_job_id":"2e4af969-d58c-4027-badf-8e070250d746","html_url":"https://github.com/pieropatron/demo_geo_proxy","commit_stats":null,"previous_names":["pieropatron/demo_geo_proxy"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pieropatron%2Fdemo_geo_proxy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pieropatron%2Fdemo_geo_proxy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pieropatron%2Fdemo_geo_proxy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pieropatron%2Fdemo_geo_proxy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pieropatron","download_url":"https://codeload.github.com/pieropatron/demo_geo_proxy/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240491826,"owners_count":19809977,"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":["basic-authentication","cache","expressjs","geo-tz","jwt","node-cluster","nominatim","osrm","redis"],"created_at":"2024-11-10T08:09:26.578Z","updated_at":"2026-04-12T17:38:44.355Z","avatar_url":"https://github.com/pieropatron.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# demo_geo_proxy\n\nDemo project for create proxy server to get geo data from OSM API's (Nominatim, OSRM) and for get information about timezone by location.\n\nSometimesProblems, which project suppose to solve:\n1. As I know, Nominatim and OSRM doesn't have authorization \"out of the box\". Also, they haven't built-in cache. This service allows to use Basic and JWT authorization and Cache, based on Redis.\n2. Geo-tz (https://github.com/evansiroky/node-geo-tz) is a beautiful tool for get information regarding IANA timezones by geo locations. But, as it has a lot of data and requires periodical updates of timezones settings, it is not comfortable to have it imported to the project, which is supposed to be used even at few of servers. Instead of that, in my opinion, better to have single server with RESTAPI to get this information. This should allow actualize tz data only for this server and to avoid dependency from this lib for another projects.\n\n\n# Installation:\n``` bash\ngit clone https://github.com/pieropatron/demo_geo_proxy\nnpm install\n```\n\nFor work service uses configuration files. After install, please, create file \"local-config.js\" at dist folder and fill it with following options:\n\n``` ts\nexports.default = {\n\trestapi: {\n\t\tport: 3000, // port of appication\n\t\tworker_count: 0 // amount of cluster workers\n\t},\n\t// settings for Basic Auth\n\tbasic_auth: {\n\t\tuser: 'user',\n\t\tpass: 'pass'\n\t},\n\t// settings for JWT authorization\n\tjwt_auth: {\n\t\tkey: 'key',\n\t\tiss: 'iss',\n\t\texpires: '1m'\n\t},\n\tredis: {\n\t\t// url for redis client\n\t\turl: \"redis://127.0.0.1:6379/0\",\n\t\t// time-to-live of cached responses, in seconds\n\t\tttl_seconds: 60\n\t},\n\tnominatim: {\n\t\t// base url for Nominatim\n\t\turl: \"https://nominatim.openstreetmap.org/\"\n\t},\n\tosrm: {\n\t\t// base url for OSRM\n\t\turl: \"http://router.project-osrm.org/\"\n\t}\n};\n```\n\nNB: At example above you can see default values of options\n\n# Start\n\nAfter that, service could be started by:\n``` bash\nnpm start\n```\n\nIf you need to generate JWT token with TTL for 3 year, you can use following command:\n``` bash\nnpm run jwt\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpieropatron%2Fdemo_geo_proxy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpieropatron%2Fdemo_geo_proxy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpieropatron%2Fdemo_geo_proxy/lists"}