I have spent a lot of time trying to figure out the correct WMTS call to make to my GeoServer to get vector tiles (from my Leaflet web app), which I eventually found from the GetCapabilities: http://localhost:8000/geoserver/gwc/service/wmts?REQUEST=getcapabilities
, where I was able to Ctrl+F to find ".pbf" which led me to this line:
<ResourceURL format="application/json" resourceType="TileJSON" template="localhost:8000/geoserver/gwc/service/wmts/rest/city:roads/{style}/tilejson/pbf?format=application/json"/>
Following the "template" value given here, it gave me 2 new URLs:
http://localhost:8000/geoserver/gwc/service/wmts/rest/city:roads/{style}/EPSG:4326/EPSG:4326:{z}/{y}/{x}?format=application/vnd.mapbox-vector-tile
, while the other URL just had EPSG:900913 instead of 4326.
My process was similar for the TMS server to find something with the format, but then I saw that the additional /{z}/{x}/{-y}.pbf
values needed to be added from this post online:
http://localhost:8000/geoserver/gwc/service/tms/1.0.0/city:roads@EPSG:900913@pbf/{z}/{x}/{-y}.pbf
How are you properly supposed to find the URLs to WMTS and TMS services usually? I feel like I just stumbled upon this. New to this area.