5

I am attempting to teach myself how to make a basic GetFeatureInfo request on a WMS (specifically from Geomet, GetCapabilities here). The following returns 400 Bad Request, and I'm not sure if it is a simple syntax error, or something more systematic.

Request:

http://geo.weather.gc.ca/geomet/?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&LAYERS=GDPS.ETA_GZ&STYLES=&SRS=EPSG%3A3857&BBOX=-20037508.342789244%2C5009377.085697313%2C-17532819.799940586%2C7514065.628545966&WIDTH=256&HEIGHT=256&QUERY_LAYERS=GDPS.ETA_GZ&X=100&Y=100

Parameters:

SERVICE:WMS VERSION:1.1.1 REQUEST:GetFeatureInfo LAYERS:GDPS.ETA_GZ STYLES: SRS:EPSG:3857 BBOX:-20037508.342789244,5009377.085697313,-17532819.799940586,7514065.628545966 WIDTH:256 HEIGHT:256 QUERY_LAYERS:GDPS.ETA_GZ X:100 Y:100 

On the other hand, the following similar GetMap request works:

Request:

http://geo.weather.gc.ca/geomet/?SERVICE=WMS&REQUEST=GetMap&VERSION=1.1.1&LAYERS=GDPS.ETA_GZ&STYLES=&FORMAT=image%2Fpng&TRANSPARENT=true&HEIGHT=256&WIDTH=256&SRS=EPSG%3A3857&BBOX=-17532819.799940586,5009377.085697313,-15028131.257091932,7514065.628545966

Parameters:

SERVICE:WMS REQUEST:GetMap VERSION:1.1.1 LAYERS:GDPS.ETA_GZ STYLES: FORMAT:image/png TRANSPARENT:true HEIGHT:256 WIDTH:256 SRS:EPSG:3857 BBOX:-17532819.799940586,5009377.085697313,-15028131.257091932,7514065.628545966 

The GetCapabilities document lists the GDPS.ETA_GZ layer's SRS as 4326, but I've attempted using lat/long coordinates, as well, to no avail.

1 Answer 1

3

It appears as though the INFO_FORMAT parameter was also required. The following works:

Request:

http://geo.weather.gc.ca/geomet/?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&LAYERS=GDPS.ETA_GZ&STYLES=&SRS=EPSG%3A3857&BBOX=-20037508.342789244%2C5009377.085697313%2C-17532819.799940586%2C7514065.628545966&WIDTH=256&HEIGHT=256&QUERY_LAYERS=GDPS.ETA_GZ&X=100&Y=100&INFO_FORMAT=text%2Fplain

Parameters:

SERVICE:WMS VERSION:1.1.1 REQUEST:GetFeatureInfo LAYERS:GDPS.ETA_GZ STYLES: SRS:EPSG:3857 BBOX:-20037508.342789244,5009377.085697313,-17532819.799940586,7514065.628545966 WIDTH:256 HEIGHT:256 QUERY_LAYERS:GDPS.ETA_GZ X:100 Y:100 INFO_FORMAT:text/plain 

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.