How to calcuate zoom level, x, and y based on a given lat and long

Hey guys I’m new to TOM TOM Api, I wanted to use the raster and vector flow tiles in my project. I notice the parameters to make a get request requires a zoom, x, and y. I have found the zoom level and tile page, but I am curious on how to calculate the zoom, x, and y based on a given latitude and longitude. I currently want to target probably the smallest tile, so highest level. Any help is appreciated.

Thanks!

1 Like

Hi.

You might want to check this thread: https://devforum.tomtom.com/t/convert-lat-lon-to-x-and-y/731/5.
The OSM Wiki also contains a lot of articles about that topic.

Regards,
Mateusz

2 Likes

Maybe you could consider using one of the SDKs instead - it makes a lot of things easier!

1 Like