ERROR

Invalid min scale in the specified source item

Last Published: April 25, 2020

Error Message

When attempting to update an existing hosted tile service in ArcGIS Online with a new tile package (.tpk) using the Import Tiles operation through the REST endpoint, the following error message is returned.

Error:   
Invalid min scale in the specified source item

Cause

The tile package used to update the hosted tile service does not contain minimum and maximum scale values in the mapserver.json file. This only occurs if the tile package is created using the Create Map Tile Package tool. The Create Map Tile Package tool does not apply values for the minimum and maximum scale in the mapserver.json file of the created tile package. For more information, refer to BUG-000104517.

Solution or Workaround

Set the minimum and maximum scale of the tile package in the mapserver.json file to be the same as the hosted tile service before updating the tile service using the Import Tiles operation in ArcGIS Online.

  1. In ArcGIS Online, delete the tile package used to publish the hosted tile service to avoid duplicating the tile package in later steps.
  2. Copy the minimum and maximum scale values of the hosted tile service to update.
    1. In ArcGIS Online, open the item details page of the hosted tile service.
    2. Scroll to the URL section, and click View. The Services Directory page of the tile service is opened.
    3. Scroll to the Min Scale and Max Scale section, and copy the Min Scale and Max Scale values.
An image of the Min Scale and Max Scale of a hosted tile service.
  1. Extract the tile package containing the updates and edit the mapserver.json file to paste the copied minimum and maximum scale values.
    1. In ArcMap, extract the tile package using the Extract Package tool. The contents of the extracted tile package are located in the specified output folder.
    2. Locate the extracted tile package folder, navigate to servicedescriptions > mapserver, and open the mapserver.json file in a text editor.
    3. Locate the minScale and maxScale parameters and replace their values with the values copied in Step 2(c).
An image of the minscale and maxscale values in the JSON file.
  1. Save the JSON file.
  1. Repackage or compress (zip) the contents of the extracted tile package folder.
    1. Set the Archive name to be the same as the hosted tile service, and add a .tpk extension.
    2. Set the Archive format to ZIP, and the Compression level as Store.
    3. Click OK. The compressed file is in .tpk format.
An image of the archive dialog box.
  1. Upload the tile package to ArcGIS Online and copy its item ID.
    1. In ArcGIS Online, click Add Item > From my computer, and select the tile package.
    2. Uncheck the checkbox for Publish this file as a hosted layer.
    3. Enter the Title and Tags of the tile package and click Add Item. Ensure the title is the same as the hosted tile service to update.
    4. In the item details page of the uploaded tile package, copy the item ID in the URL.
An image of the tile package URL containing the item ID.
  1. Update the hosted tile service with the uploaded tile package using the Import Tiles operation. The hosted tile service is updated with new tiles from the tile package. The status of the import operation can be viewed in the Tile Service Jobs Summary section in the Services Directory page.
An image of the Tile Service Jobs Summary page.
  1. In the item details page of the hosted tile service, scroll to the URL section, and click View to open the REST page of the tile service.
  2. In the URL of the tile service REST page, type admin/ after rest/ as shown below, and press Enter.
https://tiles.arcgis.com/tiles/Wl7Y1m92PbjtJs5n/arcgis/rest/admin/services/19971_tilelayer/MapServer?token...
  1. Scroll to the bottom of the page and click Import. Log in using the ArcGIS Online credentials if prompted.
  2. In the Source Item Id parameter, paste the copied tile package item ID, and click Import.
An image of the Import Tiles operation.

Article ID:000019971

Software:
  • ArcGIS Online
  • ArcMap

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options