Skip to content

Commit

Permalink
Improve text and sample code
Browse files Browse the repository at this point in the history
  • Loading branch information
deeplook committed Sep 12, 2020
1 parent f878e3a commit 671e3df
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
[![commits since](https://img.shields.io/github/commits-since/heremaps/xyz-spaces-python/latest.svg)](https://github.com/heremaps/xyz-spaces-python/commits/master)
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/heremaps/xyz-spaces-python/master)

Manage your [XYZ Hub](https://github.com/heremaps/xyz-hub) or [HERE Data Hub](https://developer.here.com/products/data-hub) from Python.
Manage your [XYZ Hub](https://github.com/heremaps/xyz-hub) or [HERE Data Hub](https://developer.here.com/products/data-hub) spaces from Python.

The GIF below is a short recording of an interaction with the notebook in [docs/notebooks/building_numbers.ipynb](https://github.com/heremaps/xyz-spaces-python/blob/master/docs/notebooks/building_numbers.ipynb),
which demonstrates how to use a spatial search on a big public dataset, loaded from the HERE [Data Hub](https://here.xyz).
Expand Down Expand Up @@ -120,10 +120,10 @@ xyz = xyzspaces.XYZ(credentials="MY_XYZ_TOKEN")

# Create a New Space
title = "My Demo Space"
description = "Description as markdown"
description = "My Description"
space = xyz.spaces.new(title=title, description=description)

# Add a Feature to a Space
# Define a New Feature
feature = {
"type": "Feature",
"properties": {"party": "Republican"},
Expand All @@ -139,6 +139,7 @@ feature = {
}
}

# Save it to a Space and get its ID
feature_id = space.add_features(features=geojson.FeatureCollection([feature]))["features"][0]["id"]

# Read a Feature from a Space
Expand Down

0 comments on commit 671e3df

Please sign in to comment.