ClemensFischer / XAML-Map-Control

XAML Map Control Library
Microsoft Public License
205 stars 61 forks source link

Bing maps API request a session ID? #61

Closed alexhopeoconnor closed 4 years ago

alexhopeoconnor commented 4 years ago

Hello,

I am trying to get the bing maps usage down against my API key and while reading their billing information here: https://docs.microsoft.com/en-us/bingmaps/getting-started/bing-maps-dev-center-help/understanding-bing-maps-transactions

I came across this: "Bing Maps service requests originating from a Bing Maps control that use a session ID instead of the Bing Maps key are non-billable up to 25 requests per session. The 26th transaction and every transaction thereafter will be billable. For example, if you make a Bing Maps REST Services request to geocode an address from the Bing Maps V8 web control and use the Map.getCredentials method to get the session ID for authentication, the resulting transaction is recorded as non-billable even though it is listed as a billable transaction in the table below."

I was wondering how I could go about making the BingMapsTileLayer or a custom tile layer use a session ID instead of just using the API key? Is this even necessary or am I misunderstanding the information from Microsoft?

Thanks, Alex.

ClemensFischer commented 4 years ago

I'm sorry, but I have never used this session ID, I only ever used the API key.

In case it is somehow possible to acquire the ID via an API - in a similar way as how the BingMapsTileLayer acquires its request URL - you might certainly be able to write a MapLayer that uses it.