{"id":13425742,"url":"https://github.com/heremaps/xyz-hub","last_synced_at":"2025-04-05T18:09:16.394Z","repository":{"id":39972766,"uuid":"226364580","full_name":"heremaps/xyz-hub","owner":"heremaps","description":"XYZ Hub is a RESTful web service for the access and management of geospatial data.","archived":false,"fork":false,"pushed_at":"2024-10-29T14:55:37.000Z","size":10475,"stargazers_count":66,"open_issues_count":6,"forks_count":39,"subscribers_count":20,"default_branch":"master","last_synced_at":"2024-10-29T17:19:02.219Z","etag":null,"topics":["geojson","geospatial","restful-api"],"latest_commit_sha":null,"homepage":"","language":"Java","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/heremaps.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-12-06T16:05:33.000Z","updated_at":"2024-10-29T14:55:39.000Z","dependencies_parsed_at":"2024-02-05T11:05:55.758Z","dependency_job_id":"b73901b3-18fc-486e-8963-68a826c4be92","html_url":"https://github.com/heremaps/xyz-hub","commit_stats":null,"previous_names":[],"tags_count":342,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heremaps%2Fxyz-hub","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heremaps%2Fxyz-hub/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heremaps%2Fxyz-hub/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heremaps%2Fxyz-hub/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/heremaps","download_url":"https://codeload.github.com/heremaps/xyz-hub/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247378149,"owners_count":20929297,"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":["geojson","geospatial","restful-api"],"created_at":"2024-07-31T00:01:17.819Z","updated_at":"2025-04-05T18:09:16.372Z","avatar_url":"https://github.com/heremaps.png","language":"Java","funding_links":[],"categories":["Java"],"sub_categories":[],"readme":"![XYZ Hub](xyz.svg)\n---\n\n[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)\n[![Run XYZ Hub tests](https://github.com/heremaps/xyz-hub/workflows/Run%20XYZ%20Hub%20tests/badge.svg)](https://github.com/heremaps/xyz-hub/actions?query=workflow%3A%22Run+XYZ+Hub+tests%22)\n\nXYZ Hub is a RESTful web service for the access and management of geospatial data.\n\n# Overview\nSome of the features of XYZ Hub are:\n* Organize geo datasets in _spaces_\n* Store and manipulate individual geo features (points, linestrings, polygons)\n* Retrieve geo features as vector tiles, with or without clipped geometries\n* Search for geo features spatially using a bounding box, radius, or any custom geometry\n* Explore geo features by filtering property values\n* Retrieve statistics for your _spaces_\n* Analytical representation of geo data as hexbins with statistical information\n* Connect with different data sources\n* Build a real-time geodata pipeline with processors\n* Attach listeners to react on events\n\nXYZ Hub uses [GeoJSON](https://tools.ietf.org/html/rfc79460) as the main geospatial data exchange format. Tiled data can also be provided as [MVT](https://github.com/mapbox/vector-tile-spec/blob/master/2.1/README.md).\n\n# Prerequisites\n\n * Java 17\n * Maven 3.9+\n * Postgres 15+ with PostGIS 3+\n * Redis 7+ (optional)\n * Docker 18+ (optional)\n * Docker Compose 1.24+ (optional)\n\n# Getting started\nClone and install the project using:\n\n```bash\ngit clone https://github.com/heremaps/xyz-hub.git\ncd xyz-hub\nmvn clean install\n```\n\n### With docker\n\nThe service and all dependencies could be started locally using Docker compose.\n```bash\ndocker-compose up -d\n```\n\nAlternatively, you can start freshly from the sources by using this command after cloning the project:\n```bash\nmvn clean install -Pdocker\n```\n\n*Hint: Postgres with PostGIS will be automatically started if you use 'docker-compose up -d' to start the service.*\n\n### Without docker\n\nThe service could also be started directly as a fat jar. In this case Postgres and the other optional dependencies need to be started separately.\n\n```bash\njava [OPTIONS] -jar xyz-hub-service/target/xyz-hub-service.jar\n```\n\nExample:\n\n```bash\njava -DHTTP_PORT=8080 -jar xyz-hub-service/target/xyz-hub-service.jar\n```\n\n### Configuration options\nThe service start parameters could be specified by editing the [default config file](./xyz-hub-service/src/main/resources/config.json), using environment variables or system properties. See the default list of  [configuration parameters](https://github.com/heremaps/xyz-hub/wiki/Configuration-parameters) and their default values.\n\n# Usage\n\nStart using the service by creating a _space_:\n\n```bash\ncurl -H \"content-type:application/json\" -d '{\"title\": \"my first space\", \"description\": \"my first geodata repo\"}' http://localhost:8080/hub/spaces\n```\n\nThe service will respond with the space definition including the space ID:\n\n```json\n{\n    \"id\": \"pvhQepar\",\n    \"title\": \"my first space\",\n    \"description\": \"my first geodata repo\",\n    \"storage\": {\n        \"id\": \"psql\",\n        \"params\": null\n    },\n    \"owner\": \"ANONYMOUS\",\n    \"createdAt\": 1576601166681,\n    \"updatedAt\": 1576601166681,\n    \"contentUpdatedAt\": 1576601166681,\n    \"autoCacheProfile\": {\n        \"browserTTL\": 0,\n        \"cdnTTL\": 0,\n        \"serviceTTL\": 0\n    }\n}\n```\n\nYou can now add _features_ to your brand new space:\n```bash\ncurl -H \"content-type:application/geo+json\" -d '{\"type\":\"FeatureCollection\",\"features\":[{\"type\":\"Feature\",\"geometry\":{\"type\":\"Point\",\"coordinates\":[-2.960847,53.430828]},\"properties\":{\"name\":\"Anfield\",\"@ns:com:here:xyz\":{\"tags\":[\"football\",\"stadium\"]},\"amenity\":\"Football Stadium\",\"capacity\":54074,\"description\":\"Home of Liverpool Football Club\"}}]}' http://localhost:8080/hub/spaces/pvhQepar/features\n```\n\nThe service will respond with the inserted geo features:\n```json\n{\n    \"type\": \"FeatureCollection\",\n    \"etag\": \"b67016e5dcabbd5f76b0719d75c84424\",\n    \"features\": [\n        {\n            \"type\": \"Feature\",\n            \"id\": \"nf36KMsQAUYoM5kM\",\n            \"geometry\": {\n                \"type\": \"Point\",\n                \"coordinates\": [ -2.960847, 53.430828 ]\n            },\n            \"properties\": {\n                \"@ns:com:here:xyz\": {\n                    \"space\": \"pvhQepar\",\n                    \"createdAt\": 1576602412218,\n                    \"updatedAt\": 1576602412218,\n                    \"tags\": [ \"football\", \"stadium\" ]\n                },\n                \"amenity\": \"Football Stadium\",\n                \"name\": \"Anfield\",\n                \"description\": \"Home of Liverpool Football Club\",\n                \"capacity\": 54074\n            }\n        }\n    ],\n    \"inserted\": [\n        \"nf36KMsQAUYoM5kM\"\n    ]\n}\n```\n\n### OpenAPI specification\n\nThe OpenAPI specification files are accessible under the following URIs:\n* Stable: `http://\u003chost\u003e:\u003cport\u003e/hub/static/openapi/stable.yaml`\n* Experimental: `http://\u003chost\u003e:\u003cport\u003e/hub/static/openapi/experimental.yaml`\n\n# Acknowledgements\n\nXYZ Hub uses:\n\n* [Vertx](http://vertx.io/)\n* [Geotools](https://github.com/geotools/geotools)\n* [JTS](https://github.com/locationtech/jts)\n* [Jackson](https://github.com/FasterXML/jackson)\n\nand [others](./pom.xml#L177-L479).\n\n# Contributing\n\nYour contributions are always welcome! Please have a look at the [contribution guidelines](CONTRIBUTING.md) first.\n\n# License\nCopyright (C) 2017-2024 HERE Europe B.V.\n\nThis project is licensed under the Apache License, Version 2.0 - see the [LICENSE](./LICENSE) file for details.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheremaps%2Fxyz-hub","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fheremaps%2Fxyz-hub","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheremaps%2Fxyz-hub/lists"}