Overview
Mundi.ai has a developer API for creating, editing, and sharing maps and map data.
Mundi.ai Developer API (0.0.1)
Section titled “Mundi.ai Developer API (0.0.1)”Mundi is a customizable, open source web GIS and can be operated via API just like it can be used as a web app. You can programatically create maps, upload geospatial data (vectors, raster, point clouds), and share map links or embed maps in other web applications.
Mundi’s API is both available as a hosted cloud service or a self-hosted set of Docker images, open source under the AGPLv3 license.
To get started, create an account at Mundi.ai and create a new API key here.
When sending requests, set the Authorization
header to Bearer YOUR_API_KEY
. API keys start with sk-...
. Never share your API keys.
# 1. create a new map project
created_map = httpx.post(
"https://app.mundi.ai/api/maps/create",
json={"title": "US political boundaries"},
headers={"Authorization": f"Bearer {os.environ["MUNDI_API_KEY"]}"},
).json()
map_id, project_id = created_map["id"], created_map["project_id"]
# 2. upload a GeoJSON file as a layer on that map
with open("counties.geojson", "rb") as f:
upload = httpx.post(
f"https://app.mundi.ai/api/maps/{map_id}/layers",
files={"file": ("counties.geojson", f, "application/geo+json")},
data={"layer_name": "US Counties", "add_layer_to_map": True},
headers={"Authorization": f"Bearer {os.environ["MUNDI_API_KEY"]}"},
).json()
# 3. link to view the map with the uploaded layer
print(f"https://app.mundi.ai/project/{project_id}/{map_id}")
- Bunting Labs: https://buntinglabs.com/
- Terms of Service
- OpenAPI version: 3.1.0