komoot / staticmap

A small, python-based library for creating map images with lines, markers and polygons.
https://www.komoot.com
Other
290 stars 65 forks source link

Custom Tile Server #21

Closed maxwell-oroark closed 4 years ago

maxwell-oroark commented 5 years ago

If we are fetching tiles from a server that requires we pass a Bearer {token} is there a way to pass this to the library so it can correctly supply it in the request?

yterletskyi commented 4 years ago

It looks like it is. StaticMap takes headers parameter in constructor. See https://github.com/komoot/staticmap/blob/master/staticmap/staticmap.py#L212

christophlingg commented 4 years ago

exactly, that is explained in the readme: https://github.com/komoot/staticmap#create-a-new-map-instance