Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apple satellite: Don't url-encode accessKey url-param #63

Closed
jo-chemla opened this issue Jul 26, 2024 · 1 comment
Closed

Apple satellite: Don't url-encode accessKey url-param #63

jo-chemla opened this issue Jul 26, 2024 · 1 comment

Comments

@jo-chemla
Copy link
Contributor

jo-chemla commented Jul 26, 2024

In parallel to the error of validation of webp tiles preventing publishing, it seems that my apple satellite service is failing validation.

Importing the below GDAL_WMS xml does work inside qgis, but it seems that the accessKey url-param shall not be url-encoded for requests to go through - adding it as a XYZ layer source into qgis fails, but importing to qgis the below GDAL_WMS xml does work.

TMS url has the format: https://sat-cdn3.apple-mapkit.com/tile?style=7&size=1&scale=1&z={z}&x={x}&y={y}&v=9801&accessKey=1721982180_2825845599881494057_%2F_UvNg5jEboEb8eMslp86Eeymjt%2FfRcTunBvgsiAiEb6Q%3D

<GDAL_WMS>
    <Service name='TMS'>
        <ServerUrl>
            https://sat-cdn3.apple-mapkit.com/tile?style=7&amp;size=1&amp;scale=1&amp;z=${z}&amp;x=${x}&amp;y=${y}&amp;v=9801&amp;accessKey=1721982180_2825845599881494057_%2F_UvNg5jEboEb8eMslp86Eeymjt%2FfRcTunBvgsiAiEb6Q%3D
        </ServerUrl>
    </Service>
    <DataWindow>
        <UpperLeftX>-20037508.34</UpperLeftX>
        <UpperLeftY>20037508.34</UpperLeftY>
        <LowerRightX>20037508.34</LowerRightX>
        <LowerRightY>-20037508.34</LowerRightY>
        <TileLevel>18</TileLevel>
        <TileCountX>1</TileCountX>
        <TileCountY>1</TileCountY>
        <YOrigin>top</YOrigin>
    </DataWindow>
    <Projection>EPSG:3857</Projection>
    <BlockSizeX>256</BlockSizeX>
    <BlockSizeY>256</BlockSizeY>
    <BandsCount>3</BandsCount>
    <Cache />
</GDAL_WMS>

Also related side-note: the Yandex satellite does not use the standard EPSG:3857 CRS but EPSG:3395 psuedo-mercator, which means there is a displacement at high zoom levels - shift increases as the zoom level increases. Supporting GDAL_WMS xmls would allow to set the correct CRS for this yandex TMS:

<GDAL_WMS><Service name="TMS"><ServerUrl>https://core-sat.maps.yandex.net/tiles?l=sat&amp;x=${x}&amp;y=${y}&amp;z=${z}&amp;scale=1&amp;lang=ru_RU</ServerUrl></Service><DataWindow><UpperLeftX>-20037508.34</UpperLeftX><UpperLeftY>20037508.34</UpperLeftY><LowerRightX>20037508.34</LowerRightX><LowerRightY>-20037508.34</LowerRightY><TileLevel>20</TileLevel><TileCountX>1</TileCountX><TileCountY>1</TileCountY><YOrigin>top</YOrigin></DataWindow><Projection>EPSG:3395</Projection><BlockSizeX>256</BlockSizeX><BlockSizeY>256</BlockSizeY><BandsCount>3</BandsCount></GDAL_WMS>

@jo-chemla
Copy link
Contributor Author

Closing since apple API accessKey changes every other day. There is a workaround to get it but it cannot be embedded within the QMS frame.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant