{"id":28709224,"url":"https://github.com/freayd/osrm","last_synced_at":"2025-06-14T20:01:58.592Z","repository":{"id":24326969,"uuid":"27723934","full_name":"freayd/osrm","owner":"freayd","description":"Ruby API to request Mapbox and other Open Source Routing Machine servers","archived":false,"fork":false,"pushed_at":"2018-07-05T03:54:01.000Z","size":59,"stargazers_count":6,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-04-26T15:21:56.454Z","etag":null,"topics":["directions","mapbox","openstreetmap","osrm","routing","ruby"],"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/freayd.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2014-12-08T16:30:47.000Z","updated_at":"2021-07-07T10:27:01.000Z","dependencies_parsed_at":"2022-08-02T19:45:23.325Z","dependency_job_id":null,"html_url":"https://github.com/freayd/osrm","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/freayd/osrm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freayd%2Fosrm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freayd%2Fosrm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freayd%2Fosrm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freayd%2Fosrm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/freayd","download_url":"https://codeload.github.com/freayd/osrm/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freayd%2Fosrm/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259875185,"owners_count":22925125,"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":["directions","mapbox","openstreetmap","osrm","routing","ruby"],"created_at":"2025-06-14T20:00:51.428Z","updated_at":"2025-06-14T20:01:58.558Z","avatar_url":"https://github.com/freayd.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"## OSRM Gem\n\nOSRM Gem is a Ruby API that allows you to request [Open Source Routing Machine](http://project-osrm.org/) servers.\nYou can [run your own server](https://github.com/Project-OSRM/osrm-backend/wiki), use the [OSRM demo server](https://github.com/Project-OSRM/osrm-backend/wiki/Demo-server) or the [Mapbox server](https://www.mapbox.com/developers/).\n\n## Usage\n\n1. Install OSRM Gem\n\n        gem install osrm\n\n2. Configure\n\n        require 'osrm'\n        OSRM.configure(\n\n          # Connection\n          server:       'example.com',      # Must be specified\n          port:         8080,               # Default: 80 or 443 if SSL\n          use_ssl:      true,               # Default: false\n          path_prefix:  '/optional/path',   # Default: ''\n          ## OSRM demo server connection\n          # server:     :demo,\n          ## Mapbox server connection\n          # server:     :mapbox,\n          # api_key:    'access-token',\n\n          # Connection (advanced)\n          timeout:        10,                               # Default: 3\n          user_agent:     'MyScript/1.1',                   # Default: 'OSRMRubyGem/{version}'\n          before_request: -\u003e { sleep 1 },                   # Default: nil\n          after_request:  -\u003e { puts 'Request performed!' }, # Default: nil\n\n          # Caching\n          # The cache can be any object providing [] and []= methods.\n          # The cache key must contain the {url} pattern.\n          cache:      {},                 # Default: nil (no cache)\n          cache_key:  'my-script:{url}',  # Default: 'osrm:{url}'\n\n          # Requests\n          # Specify the precision of the overview geometries returned\n          overview: :full                 # Possible values: false, :simplified (default), :full\n\n        )\n\n3. Request\n\n        OSRM.routes('50.202712,8.582738', '50.20232,8.574447')\n        OSRM.route('50.202712,8.582738', '50.20232,8.574447', '50.2099431,8.5710665')\n        OSRM.route_by_cycling('45.734818,7.3219649', '45.868829,7.1533417')\n\n## License\n\nOSRM Gem is released under [MIT License](https://opensource.org/licenses/MIT).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffreayd%2Fosrm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffreayd%2Fosrm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffreayd%2Fosrm/lists"}