Map Image API
Fresh, geolocated street-level imagery from around the globe
Overview
Bee Maps designed the Map Image API to allow developers and enterprises to easily access imagery from the Hivemapper Network.

1. API Key Provisioning
Log in to Bee Maps
Go to Developers tabs
On Map Data API Keys click Generate API Key
Copy and save the Map API Key securely — it will only be shown once
Copy and save the Org ID.

2. Encoding and Authorization
Routes requiring Basic authorization
Encode the orgID and Map API Key in base64
The encoding format is OrgID:MapAPIKey
3. Image API Documentation
Query imagery contained by a GeoJSON (Multi)Polygon for a given week
YYYY-mm-dd of a day in the week to query
2023-10-31
Polygon or MultiPolygon
Polygon
Successful operation
Invalid GeoJSON Polygon/MultiPolygon
Forbidden (couldn't extract valid API key)
const url = 'https://hivemapper.com/api/developer/imagery/poly'
const resp = await fetch(url,
{
method: 'post',
body: JSON.stringify({
coordinates: [
[
[-122.41927011115149,37.775414437036275],
[-122.41605628337065,37.7763 86631642566],
[-122.41597692959819,37.77889546188183],
[-122.42299973845249,37.7772647319 11615],
[-122.41927011115149,37.775414437036275]
]
],
type: 'Polygon'
}),
headers: {
'content-type': 'application/json',
authorization: 'Basic XXXYYYZZZ'
}
});
const data = await resp.json();
const frames = data.frames;
{
"frames": [
{
"url": "https://www.cdn.com/image?signed=yoursdearly",
"timestamp": "2023-11-09T02:30:48.974Z",
"sequence": "60cb39e7cce2931a8cd2fa2d",
"idx": 0,
"device": "hdc",
"position": {
"lat": 37.76910370072376,
"lat_ref": "n",
"lon": -122.48185591741223,
"lon_ref": "e",
"gdop": 0.123,
"hdop": 0.123,
"pdop": 0.123,
"eph": 0.123
},
"width": 2028,
"height": 1024,
"imu": {
"acc_x": 0.123,
"acc_y": 0.123,
"acc_z": 0.123,
"gyro_x": 0.123,
"gyro_y": 0.123,
"gyro_z": 0.123
}
}
],
"creditsUsed": 42,
"creditsRemaining": 1000000
}
Fetch history of API queries
Max results to return
100
Results to skip
0
Paginated API transactions
GET /api/developer/history HTTP/1.1
Host: hivemapper.com
Authorization: Basic username:password
Accept: */*
Paginated API transactions
{
"history": [
{
"area": 101.123,
"credits": 4,
"payload": {
"type": "Polygon",
"coordinates": [
[
[
-122.48185591741223,
37.76910370072376
]
]
]
},
"timestamp": "2023-11-09T03:09:40.131Z",
"weeks": [
"2023-10-31"
]
}
]
}
Additional API Tools
Hive-Py is a Python wrapper for the Map Image API, see GitHub here.
Example query Python query using Hive-Py
> python -m imagery.query
usage: query.py [-h] -i INPUT_FILE [-s START_DAY] [-e END_DAY] [-L] [-x] [-d MAX_DIST] [-l MAX_LAG] [-z MAX_ANGLE] -o OUTPUT_DIR [-g] [-w WIDTH] [-M]
[-I CUSTOM_ID_FIELD] [-S CUSTOM_MIN_DATE_FIELD] [-k] [-E] [-K SKIP_GEO_FILE] [-P IMAGE_POST_PROCESSING] -a AUTHORIZATION [-c NUM_THREADS] [-v]
[-C] [-b] [-N]
API Billing
Cost
$1 per road km per week. For example, requesting imagery for the same 1 km of road over 3 weeks costs $3.
Billing Cycle
Charges are billed every two weeks to the credit card on file. If usage reaches $500 before the cycle ends, the card is charged immediately.
Sample Map Image API data
Before using the API, you can quickly evaluate a large set of sample imagery.
Imagery specs
Forward facing (interior or exterior mounted)
1080p
Lane-level positional accuracy
Frames collected and uploaded every 6 to 8 meters — can be dynamically adjusted in certain regions.
Last updated