The first URL it appears you are using a URL to retrieve map tiles from Azure Maps. The second URL you appear to be mixing options from the tile service API with the static map image API which are not supported. There is not pins
parameter available on the tile service API, that API servers map tiles from Azure Maps, it does not generate map images with pins drawn on it. Here are the docs:
Map tile service: https://learn.microsoft.com/en-us/rest/api/maps/render/get-map-tile?tabs=HTTP
Static map service: https://learn.microsoft.com/en-us/rest/api/maps/render/get-map-image?tabs=HTTP
The static map service can be used to retrieve a map with pins drawn on it, but note that is an image of a specific map for a specific location and not map tiles that can be used in a dynamic map control such as flutter maps.