Still Map Image API

The Still Map Image API creates a map based on URL parameters sent through a standard HTTP request and returns the map as an image which you can display on your application. The API lets you embed MapmyIndia Maps image according to geo-position, pixel size and zoom level of the map on your application without requiring any dynamic page loading. The image can be a retina image and markers can be added to the image to indicate position of any object.

API URL

 

Request Parameters

Returns PNG data to draw map tile at position specified with coordinates (centre of the image), image size, scale factor and zoom level. The request parameters that specify what image

Note: All Mandatory parameters are marked with a “ * ”.

  1. *licence_key: the REST API licence key allocated to you by signing into our services and registering yourself as a developer (28 Char Alphanumeric).
  2. *centre: a WGS-84 position coordinate that specifies the centre of the image requested.

    e.g.
    http://apis.mapmyindia.com/advancedmaps/v1/<licence_key>/still_image?center=28.595939499830784,77.22556114196777
  3. zoom: The zoom level for which the image is requested. Ranges from 4 to 18 with 18 being the highest zoomed in level.

    e.g.
    http://apis.mapmyindia.com/advancedmaps/v1/<licence_key>/still_image?center=28.595939499830784,77.22556114196777&zoom=18
  4. size: the size of the image requested in pixels as <Width>x<Height>.

    e.g.
    http://apis.mapmyindia.com/advancedmaps/v1/<licence_key>/still_image?center=28.595939499830784,77.22556114196777&zoom=18&size=800x480
  5. ssf: scale factor indicating retina or non-retina tiles. 
    0→non-retina tiles. 
    1→retina tiles.

    e.g.
    http://apis.mapmyindia.com/advancedmaps/v1/<licence_key>/still_image?center=28.595939499830784,77.22556114196777&zoom=18&size=800x480&ssf=1
  6. markers: optional markers that you may want to add to the map tile.

    e.g. http://apis.mapmyindia.com/advancedmaps/v1/<licence_key>/still_image?center=28.595939499830784,77.22556114196777&zoom=18&size=800x480&ssf=1&markers=28.595939,77.225561|28.596000,77.225600>

Response Parameters

An 8-bit “.png” image.

Performance

Performance is dependent on WAN/LAN/WLAN speed.

Transaction Information

One Request (which returns one image) using the API link will be considered as one transaction.

Use Cases

  • To show a quick location point without having to dditionally add a Map Control.
  • To show multiple locations on map without the need to add a Map Control.

Example

Input:
http://apis.mapmyindia.com/advancedmaps/v1/<licence_key>/still_image?center=28.595939499830784,77.22556114196777&zoom=18&size=800x480&ssf=1&markers=28.595939,77.225561|28.596000,77.225600>

Output:

Sample Map

If the request was passed as src attribute of Image, browser would have shown the image.