{"id":15887927,"url":"https://github.com/iwpnd/detectr","last_synced_at":"2025-03-17T15:31:05.557Z","repository":{"id":159720502,"uuid":"415327243","full_name":"iwpnd/detectr","owner":"iwpnd","description":"minimal geofencing application","archived":false,"fork":false,"pushed_at":"2024-11-12T18:45:02.000Z","size":2987,"stargazers_count":16,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-15T15:39:39.055Z","etag":null,"topics":["geofence-api","geofencing","gofiber","rtree","tile38"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/iwpnd.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2021-10-09T14:09:30.000Z","updated_at":"2024-11-12T18:44:10.000Z","dependencies_parsed_at":null,"dependency_job_id":"5255b32f-dd45-41e5-8352-6fda5117b66c","html_url":"https://github.com/iwpnd/detectr","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/iwpnd%2Fdetectr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iwpnd%2Fdetectr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iwpnd%2Fdetectr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iwpnd%2Fdetectr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/iwpnd","download_url":"https://codeload.github.com/iwpnd/detectr/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243865657,"owners_count":20360480,"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":["geofence-api","geofencing","gofiber","rtree","tile38"],"created_at":"2024-10-06T06:05:43.510Z","updated_at":"2025-03-17T15:31:05.232Z","avatar_url":"https://github.com/iwpnd.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# detectr\n\nA minimal geofencing application build with [gofiber](https://github.com/gofiber/fiber), using an embedded\n[rtree](https://github.com/tidwall/rtree) and [geoindex](https://github.com/tidwall/geoindex) for fast\ngeospatial lookups.\n\nBring your own data, pass a location and receive the geofences that your location\nis currently in.\n\n## Installation\n\n### cli\n\n```bash\ngo install github.com/iwpnd/detectr/cmd/detectr-server@latest\n```\n\n```bash\n➜ detectr --help\nNAME:\n   detectr - geofence application\n\nUSAGE:\n   detectr [global options] command [command options] [arguments...]\n\nCOMMANDS:\n   help, h  Shows a list of commands or help for one command\n\nGLOBAL OPTIONS:\n   --port value       define port (default: 3000)\n   --require-key      use keyauth (default: false)\n   --log-level value  set loglevel (default: \"error\")\n   --data value       path to dataset to load with app\n   --help, -h         show help (default: false)\n```\n\n## Usage\n\n```bash\n# start up\n\ndetectr --data my_featurecollection.geojson\n```\n\n```bash\n# send a location\n\ncurl -X POST -H \"Content-Type: application/json\" -d '{\"lng\":13.4042367,\"lat\":52.473091}' http://localhost:3000/location\n\n\u003e\u003e {\n  \"data\": {\n    \"elapsed\": \"150.75µs\",\n    \"request\": {\n      \"lat\": 52.473091,\n      \"lng\": 13.4042367\n    },\n    \"matches\": [\n        {\n          \"type\": \"Feature\",\n          \"properties\": {\"id\":\"my geofence\"},\n          \"geometry\": {\n            \"coordinates\": [\n              [\n                [\n                  13.41493887975497,\n                  52.47961028115867\n                ],\n                [\n                  13.393534522441712,\n                  52.47961028115867\n                ],\n                [\n                  13.393534522441712,\n                  52.466572160399664\n                ],\n                [\n                  13.41493887975497,\n                  52.466572160399664\n                ],\n                [\n                  13.41493887975497,\n                  52.47961028115867\n                ]\n              ]\n            ],\n            \"type\": \"Polygon\"\n          }\n        }\n    ]\n  }\n}\n```\n\n## License\n\nMIT\n\n## Acknowledgement\n\n- Triggered by this article on the UBER engineering blog\n  about [UBERs highest query per second service](https://www.uber.com/en-DE/blog/go-geofence-highest-query-per-second-service/).\n- Heavily inspired by [Tile38](https://github.com/tidwall/tile38) and build because\n  I wanted to understand how Tile38 works under the hood.\n\n## Maintainer\n\nBenjamin Ramser - [@iwpnd](https://github.com/iwpnd)\n\nProject Link: [https://github.com/iwpnd/detectr](https://github.com/iwpnd/detectr)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiwpnd%2Fdetectr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiwpnd%2Fdetectr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiwpnd%2Fdetectr/lists"}