Skip to content

Attribution

Example
Use dark colors for code blocksCopy
1
2
3
{
  "attribution": "Sources: Esri, Vantor, GeoEye, Earthstar Geographics, CNES/Airbus DS, USDA, USGS, AeroGRID, IGN, © OpenStreetMap contributors, TomTom, Garmin, FAO, NOAA, and the GIS User Community"
}

The map's attribution information.

Please note that the ArcGIS Basemap style attribution statement must be displayed every time the static map is visible. It must be positioned very close to the static map, or it can be provided via a popup or menu if the static map is embedded in an application or website. The relevant attribution statement for an ArcGIS Basemap style is available from the /static-maps/arcgis/{arcgis-style}/attribution endpoint. For more information see the ArcGIS Location Platform Agreement on the Terms of use.

Properties

NameTypeRequired
attributionstring

CoordGeometry

Example
Use dark colors for code blocksCopy
1
2
3
4
[
  -117.1957,
  34.0561
]

The x (longitude) and y (latitude) coordinate pair in the WGS84 spatial reference.

  • longitude in the range -179.99 to 179.99 representing the east/west or x-axis
  • latitude in the range -85.05 to 85.05 representing the north/south or y-axis

CustomMarkerSymbol

Example
Use dark colors for code blocksCopy
1
2
3
4
{
  "customSymbolId": "campground",
  "scale": 1
}

The custom marker symbol can display an SVG image that is stored in the CustomSymbols dictionary.

To use a custom SVG symbol, store the base64‑encoded data URL string representing the SVG image in the customSymbols property. This property is a dictionary, where the key is a unique string, such as campground, and the value is a base64‑encoded data URL string representing the SVG image. To symbolize a specific geometry with a custom symbol, pass the key to the customSymbolId.

Properties

NameTypeRequiredDescription
customSymbolIdstring

The key to a base64-encoded data url string for an SVG image in the CustomSymbols dictionary.

scaleSymbolScale

The scale of the marker symbol as a multiplier of the symbol's dimensions.

A scale value less than 1.0 indicates that the symbol is scaled down, while a value greater than 1.0 indicates that the symbol is scaled up. For example, a scale of 0.5 will reduce the symbol's dimensions to half its original size. A scale of 2.0 will double the symbol's dimensions.

The minimum scale is 0.1 and the maximum scale is 4.0.

CustomSymbols

Example
Use dark colors for code blocksCopy
1
2
3
4
{
  "parkEntrance": "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMSAyMSI+PHBhdGggZD0iTTE4IDkuOTk4di0xbC03LjUtNi03LjUgNnYxaDF2NkgzdjFoMTV2LTFoLTF2LTZoMXptLTEyIDBoM3YzSDZ2LTN6bTYgNnYtNmgzdjZoLTN6Ii8+PC9zdmc+",
  "campground": "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMSAyMSI+PHBhdGggZD0iTTEyLjQwMiAxNi45NzZIMTlMMTAuNTAzIDIuOTk4IDIgMTYuOTc2aDYuNjI2bDEuODg4LTguOTR6Ii8+PC9zdmc+"
}

customSymbols is a dictionary of key-value pairs, where each pair defines a custom symbol to be added to the map.

The key is a unique string, such as campground or parkEntrance, and the value is a base64‑encoded data URL string representing the SVG image. To symbolize a specific geometry with a custom symbol, pass the key to the customSymbolId.

The general format of a base64‑encoded data URL string is data:[<mediatype>][;base64],<data>, as specified here.

To construct the data URL for an SVG image follow these steps:

  1. Obtain the XML string from the SVG file.
  2. Encode the XML string into base64 format.
  3. Append the base64-formatted string to data:image/svg+xml;base64,.

There is a range of SVG symbols from ESRI available from the Calcite point symbols repository or the Esri developer Place icons site.

The maximum length of the base64‑encoded data URL string is 4000 characters.

Unsupported SVG Features

  • SVG images must not reference external resources using URLs.
  • Embedded raster images, such as PNG, JPG, and WebP formats, are not supported.
  • SVG images that contain font-based text elements are not supported.
  • It is recommend that text is converted into vector paths so that it can be rendered in custom symbols.

Error

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
{
  "error": {
    "code": 400,
    "message": "string",
    "details": [
      "string"
    ],
    "restInfoUrl": "https://static-maps-api.arcgis.com/arcgis/rest/info"
  }
}

Properties

NameTypeRequiredDescription
errorobject

Error information

error properties

NameTypeRequiredDescription
codeinteger

A code identifying the type of error, either an HTTP error code, 498 (signifying invalid or expired token), or 499 (signifying missing token).

messagestring

A message describing the error.

details[string]

List of details about the error.

restInfoUrlstring

URL that provides the static maps service information.

Enumerated values

code
400
Click to copy
401
Click to copy
403
Click to copy
404
Click to copy
498
Click to copy
499
Click to copy
500
Click to copy

HexColor

Example
Use dark colors for code blocksCopy
1
"007AC2"

The hexadecimal color code for the marker symbol.

It has the format RRGGBB.

  • RR is the red value
  • GG is the green value
  • BB is the blue value

The default color is a medium-dark shade of blue (007AC2).

Type
string
Required
false
Restrictions
none
Default value
007AC2
Minimum length
6
Maximum length
6

LineStyle

Example
Use dark colors for code blocksCopy
1
"solid"

The style, or stroke, to apply to the line symbol.

The default line style is solid.

Type
string
Required
false
Restrictions
none
Default value
solid

Enumerated values

anonymous
solid
Click to copy
dash
Click to copy
dot
Click to copy

LineSymbol

Example
Use dark colors for code blocksCopy
1
2
3
4
5
{
  "width": 2,
  "style": "solid",
  "color": "007AC2"
}

The properties that define the width, style, and color of a line.

Properties

NameTypeRequiredDescription
widthLineWidth

The width of the line in device-independent pixels.

The minimum width is 1 and the maximum width is 16.

styleLineStyle

The style, or stroke, to apply to the line symbol.

The default line style is solid.

colorHexColor

The hexadecimal color code for the marker symbol.

It has the format RRGGBB.

  • RR is the red value
  • GG is the green value
  • BB is the blue value

The default color is a medium-dark shade of blue (007AC2).

LineWidth

Example
Use dark colors for code blocksCopy
1
2

The width of the line in device-independent pixels.

The minimum width is 1 and the maximum width is 16.

Type
integer
Required
false
Restrictions
none
Default value
2
Minimum
1
Maximum
16

ManyPoints

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
{
  "manyPoints": [
    {
      "geometry": {
        "x": -117.1957,
        "y": 34.0561,
        "spatialReference": {
          "wkid": 4326
        }
      },
      "symbol": {
        "customSymbolId": "campground",
        "scale": 1
      }
    }
  ]
}

An array x,y coordinate pairs in the WGS84 spatial reference along with their associated symbol definitions.

The symbol can be a simple marker symbol or a custom marker symbol.

To use a custom SVG symbol, store the base64‑encoded data URL string representing the SVG image in the customSymbols property. This property is a dictionary, where the key is a unique string, such as campground, and the value is a base64‑encoded data URL string representing the SVG image. To symbolize a specific geometry with a custom symbol, pass the key to the customSymbolId.

Properties

NameTypeRequiredDescription
manyPoints[PointAndSymbol]

An array x,y coordinate pairs in the WGS84 spatial reference along with a symbol for the point.

The array can contain from 1 to 10 coordinate pairs and symbols.

MapImageFormat

Example
Use dark colors for code blocksCopy
1
"webp"

The format of the map image, such as png, jpg, webp.

Type
string
Required
false
Restrictions
none
Default value
webp

Enumerated values

anonymous
png
Click to copy
jpg
Click to copy
webp
Click to copy

MapImageHeight

Example
Use dark colors for code blocksCopy
1
200

The height of the requested map image in pixels at 96 DPI between 64 and 1024 pixels.

Type
integer
Required
false
Restrictions
none
Default value
200
Minimum
64
Maximum
1024

MapImageWidth

Example
Use dark colors for code blocksCopy
1
200

The width of the requested map image in pixels at 96 DPI between 64 and 1024 pixels.

Type
integer
Required
false
Restrictions
none
Default value
200
Minimum
64
Maximum
1024

MultiPoint

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
[
  [
    -117.1957,
    34.0561
  ],
  [
    -117.1942,
    34.0569
  ],
  [
    -117.1964,
    34.05685
  ],
  [
    -117.1945,
    34.0573
  ]
]

An array x,y coordinate pairs in the WGS84 spatial reference.

The array can contain from 1 to 10 coordinate pairs.

Padding

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
[
  10,
  0,
  10,
  20
]

The padding applied to the static map adds extra map content between the static map's extent and the edge of the image.

Padding value is a % of the static map image's width and/or height. It is applied to the static map image, according to the table below:

Number of values in the arrayDescriptionExample
OneThe same padding % is applied to all four sides.[10]
TwoThe first value applies padding to the top and bottom, the second to the left and right sides.[10, 5 ]
ThreeThe first value applies padding to the top, the second to the left and right sides, and the third to the bottom.[10, 20, 10]
FourThe four values apply padding to the top, right, bottom, and left in a clockwise order.[10, 5, 5, 20]

PathGeometry

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
[
  [
    -117.1957,
    34.0561
  ],
  [
    -117.1957,
    34.0561
  ]
]

A path is an array of x,y coordinate pairs in the WGS84 spatial reference.

PathGeometryGet

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
[
  [
    -117.247325,
    34.100934
  ],
  [
    -117.247506,
    34.104433
  ],
  [
    -117.247962,
    34.105095
  ]
]

An array x,y coordinate pairs in the WGS84 spatial reference that define a path.

The array can contain from 2 to 10 coordinate pairs.

Paths

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
[
  [
    [
      -117.247325,
      34.100934
    ],
    [
      -117.247506,
      34.104433
    ],
    [
      -117.247962,
      34.105095
    ]
  ],
  [
    [
      -117.247962,
      34.105095
    ],
    [
      -117.244321,
      34.106745
    ],
    [
      -117.209646,
      34.106204
    ],
    [
      -117.208757,
      34.105251
    ]
  ]
]

An array route paths.

When a route consists of more than one path, the route is contiguous only if the last point of each path matches the first point of the next path in the array.

The route paths can contain between 2 and 256 coordinate pairs across all paths.

PointAndSymbol

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
{
  "geometry": {
    "x": -117.1957,
    "y": 34.0561,
    "spatialReference": {
      "wkid": 4326
    }
  },
  "symbol": {
    "customSymbolId": "campground",
    "scale": 1
  }
}

The point geometry and its associated symbol. The symbol can be a simple marker symbol or a custom marker symbol.

To use a custom SVG symbol, store the base64‑encoded data URL string representing the SVG image in the customSymbols property. This property is a dictionary, where the key is a unique string, such as campground, and the value is a base64‑encoded data URL string representing the SVG image. To symbolize a specific geometry with a custom symbol, pass the key to the customSymbolId.

Properties

NameTypeRequiredDescription
geometryPointGeometry

An x,y coordinate pair in the WGS84 spatial reference.

symboloneOf: CustomMarkerSymbol, SimpleMarkerSymbol

The symbol can be a simple marker symbol or a custom marker symbol.

PointGeometry

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
{
  "x": -117.1957,
  "y": 34.0561,
  "spatialReference": {
    "wkid": 4326
  }
}

An x,y coordinate pair in the WGS84 spatial reference.

Properties

NameTypeRequiredDescription
xnumber

An x-coordinate, or longitude, in WGS84 decimal degrees.

ynumber

A y-coordinate, or latitude, in WGS84 decimal degrees.

spatialReferenceSpatialReference

The spatial reference of the geometry.

The spatial reference must always be WGS84 (wkid = 4326).

RadiusDistance

Example
Use dark colors for code blocksCopy
1
1000

The radius (in meters), defines the minimum geographical area around a specified point that is shown on the static map.

The radius value is used to define the real world radius of the area displayed in the map image. The area covered by the radius will always be displayed on the static map image.

If the image width and height are equal, the static map image will be square and the geographic extent displayed by the static map image will match that defined by the radius. However, if the image width is greater than the height, the geographic extent displayed by the static map image will be wider than that defined by the radius.

As a guide, the following radius values can be used for the following types of static maps.

Radius (meters)Type of usage (approximate)
10Building
100Streets
1000Town
10000County
100000State
1000000Country

The radius has a minimum value of 10 meters and a maximum value of 20,000,000 meters.

Type
number(float)
Required
false
Restrictions
none
Minimum
10
Maximum
20000000

Route

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
{
  "paths": [
    [
      [
        -117.247325,
        34.100934
      ],
      [
        -117.247506,
        34.104433
      ],
      [
        -117.247962,
        34.105095
      ]
    ],
    [
      [
        -117.247962,
        34.105095
      ],
      [
        -117.244321,
        34.106745
      ],
      [
        -117.209646,
        34.106204
      ],
      [
        -117.208757,
        34.105251
      ]
    ]
  ],
  "spatialReference": {
    "wkid": 4326
  }
}

The route is represented as a line that is displayed on a static map.

Each route can consist of one or more paths, where each path is an array of x,y coordinate pairs in the WGS84 spatial reference. When a route consists of more than one path, the route is contiguous only if the last point of each path matches the first point of the next path in the array.

The route starts at the first coordinate pair in the route's first path, and ends at the last coordinate pair in the route's last path. The route is displayed using the lineSymbol, while the start and end points are represented by the startSymbol and endSymbol, respectively.

The route can contain from 2 to 256 coordinate pairs that can be defined in one or more paths.

Properties

NameTypeRequiredDescription
pathsPaths

An array route paths.

When a route consists of more than one path, the route is contiguous only if the last point of each path matches the first point of the next path in the array.

The route paths can contain between 2 and 256 coordinate pairs across all paths.

spatialReferenceSpatialReference

The spatial reference of the geometry.

The spatial reference must always be WGS84 (wkid = 4326).

RouteStyle

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
{
  "startSymbol": {
    "customSymbolId": "campground",
    "scale": 1
  },
  "endSymbol": {
    "customSymbolId": "campground",
    "scale": 1
  },
  "lineSymbol": {
    "width": 2,
    "style": "solid",
    "color": "007AC2"
  }
}

The symbols associated with the route's line, start, and end points.

The start and end symbols can either be simple marker symbols or custom marker symbols.

To use a custom SVG symbol, store the base64‑encoded data URL string representing the SVG image in the customSymbols property. This property is a dictionary, where the key is a unique string, such as campground, and the value is a base64‑encoded data URL string representing the SVG image. To symbolize a specific geometry with a custom symbol, pass the key to the customSymbolId.

Properties

NameTypeRequiredDescription
startSymboloneOf: CustomMarkerSymbol, SimpleMarkerSymbol

The symbol displayed at the start of the route. It can be a simple marker symbol or a custom marker symbol.

endSymboloneOf: CustomMarkerSymbol, SimpleMarkerSymbol

The symbol displayed at the start of the route. It can be a simple marker symbol or a custom marker symbol.

lineSymbolLineSymbol

The properties that define the width, style, and color of a line.

SimpleMarkerSymbol

Example
Use dark colors for code blocksCopy
1
2
3
4
5
6
{
  "style": "pin",
  "scale": 1,
  "color": "007AC2",
  "label": "A"
}

The simple marker symbol can have a colored pin or circle style. It can be labeled and scaled, as required.

Properties

NameTypeRequiredDescription
styleSymbolStyle

The style of the marker symbol can be pin or circle.

scaleSymbolScale

The scale of the marker symbol as a multiplier of the symbol's dimensions.

A scale value less than 1.0 indicates that the symbol is scaled down, while a value greater than 1.0 indicates that the symbol is scaled up. For example, a scale of 0.5 will reduce the symbol's dimensions to half its original size. A scale of 2.0 will double the symbol's dimensions.

The minimum scale is 0.1 and the maximum scale is 4.0.

colorHexColor

The hexadecimal color code for the marker symbol.

It has the format RRGGBB.

  • RR is the red value
  • GG is the green value
  • BB is the blue value

The default color is a medium-dark shade of blue (007AC2).

labelSymbolLabel

A label to be displayed on the marker symbol.

The label can be a maximum of two letters or numbers from a-z, A-Z, and 0-9.

SpatialReference

Example
Use dark colors for code blocksCopy
1
2
3
{
  "wkid": 4326
}

The spatial reference of the geometry.

The spatial reference must always be WGS84 (wkid = 4326).

Properties

NameTypeRequiredDescription
wkidWkid

The WKID (Well-Known ID) is a unique integer identifier used to define a specific spatial reference.

The wkid value of 4326, for WGS84, is currently the only supported WKID.

SymbolLabel

Example
Use dark colors for code blocksCopy
1
"A"

A label to be displayed on the marker symbol.

The label can be a maximum of two letters or numbers from a-z, A-Z, and 0-9.

Type
string
Required
false
Restrictions
none
Minimum length
1
Maximum length
2

SymbolScale

Example
Use dark colors for code blocksCopy
1
1

The scale of the marker symbol as a multiplier of the symbol's dimensions.

A scale value less than 1.0 indicates that the symbol is scaled down, while a value greater than 1.0 indicates that the symbol is scaled up. For example, a scale of 0.5 will reduce the symbol's dimensions to half its original size. A scale of 2.0 will double the symbol's dimensions.

The minimum scale is 0.1 and the maximum scale is 4.0.

Type
number(float)
Required
false
Restrictions
none
Default value
1
Minimum
0.1
Maximum
4

SymbolStyle

Example
Use dark colors for code blocksCopy
1
"pin"

The style of the marker symbol can be pin or circle.

Type
string
Required
false
Restrictions
none

Enumerated values

anonymous
pin
Click to copy
circle
Click to copy

Wkid

Example
Use dark colors for code blocksCopy
1
4326

The WKID (Well-Known ID) is a unique integer identifier used to define a specific spatial reference.

The wkid value of 4326, for WGS84, is currently the only supported WKID.

Type
integer
Required
false
Restrictions
none
Default value
4326

Enumerated values

anonymous
4326
Click to copy

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.