PubNub Integration

Mapbox: Static Maps

Data Streaming & Dashboards

Data Streaming & Dashboards

Geolocation

Geolocation

Last Updated:

2016/09/29

Author:

PubNub

Mapbox Signup

Create a custom, embeddable static map with zoom, bearing, and pitch

Mapbox's Static Maps API creates an embedded, customizable map for web and mobile apps, without the interactivity.

The Static Maps block allows you to create these maps based on your data streams, and publish that map in realtime. This works great for apps that don't require realtime geolocation tracking, but still want to display an updated location to a user at a custom time, or based on a custom action.

Mapbox: Static Maps

Walkthrough

This block uses the Mapbox Static Map API to generate a visual static map using the provided latitude, longitude, and zoom values.

For more information, please review the Mapbox Static documentation on the API page.

Input

Input Channel: mapbox-static-channel (configurable)lat latitude of the center point of the maplng longitude of the center point of the mapzoom zoom value

{
    "lat": 70,
    "lng": 30,
    "zoom": 4
}

Output

The block appends the picture of the map returned by the Mapbox Static Map API into the message payload. Please refer to the Mapbox documentation for config information

{
    "lat": 70,
    "lng": 30,
    "zoom": 4,
    "map": "<map url>"
}

Feedback & Support

Need help? Contact PubNub Support.


Talk to an expert

Contact Sales