1

Objective

I am trying to download the images (or the vector files if possible) from a map embedded in the following webpage https://www4.sii.cl/mapasui/internet/#/contenido/index.html

enter image description here

Context

To see the layers you need to click Catálogo Mapas enter image description here and then chose Region, City and layer, for example "XVIII DIRECCION REGIONAL DE ARICA Y PARINACOTA"->"ARICA"->"Predios".

Inspecting the webpage I realized it uses a WMS request, for example: "https://www4.sii.cl/mapasui/services/ui/wmsProxyService/call?service=WMS&request=GetMap&layers=sii:BR_CART_ARICA_WMS&styles=PREDIOS_WMS_V0&format=image/png&transparent=true&version=1.1.1&comuna=1101&eac=0&eacano=0&height=256&width=256&srs=EPSG:3857&bbox=-7825622.9558363445,-2093457.3306744064,-7825317.2023204,-209351.5825612664"

My first attempt was trying to connect to the WMS from QGIS, but I couldn't figure out the correct URL (there is no documentation either). Secondly, I tried to change the parameters of the request, but the image doesn't show when anything is changed.

Question

Any ideas of how to download this layers? I think the easiest way would be to infer the WMS URL but maybe there are other options.

2

The URL to append request parameters is just:

https://www4.sii.cl/mapasui/services/ui/wmsProxyService/call?

Normally, you would expect a GetCapabilities request to work

like:

https://www4.sii.cl/mapasui/services/ui/wmsProxyService/call?service=WMS&requst=GetCapabilities&

or for specific versions like:

https://www4.sii.cl/mapasui/services/ui/wmsProxyService/call?service=WMS&requst=GetCapabilities&version=1.1.1

but neither of these work, so it may be that the service provider has switched these responses off; possibly they weren't intending anybody else to use the service in their own software clients. Clients like QGIS need a working GetCapabilities response to know what they can offer to the user; so I think it's unlikely you'll find anything to work with QGIS.

The service is working though to give images, your example request gives:

GetMap request

So possibly you can hand crank some requests for your needs by changing the image size (height=256&width=256&) and bounding box (bbox=-7825622.9558363445,-2093457.3306744064,-7825317.2023204,-209351.5825612664&)

like (bbox=-7825317.2023204,-2093457.3306744064,-7825011.448804455,-209351.5825612664):

changing bounding box

2
  • thank you @nmtoken ! Just to know, did you try to change the image size or the bounding box? because when I try changing any number I get a white image... Sep 30 '21 at 18:32
  • Without the capabilities response it'll be difficult to determine what's allowed. Changing bbox does work for me
    – nmtoken
    Oct 1 '21 at 8:39
0

Try with https://www.npmjs.com/package/wms-downloader with following parameters: https://www4.sii.cl/mapasui/services/ui/wmsProxyService/call

{
"service":"WMS",
"request":"GetMap",
"layers":"sii",
"styles":"",
"format":"image%2Fpng",
"transparent":"true",
"version":"1.1.0",
"name":"Cadastre",
"height":"256",
"width":"256",
"srs":"EPSG%3A3857"
}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.