Find answers and key resources for successfully building apps with ArcGIS REST JS.
General
This guide is for:
- New developers interested in building mapping applications using ArcGIS REST JS.
- Open source developers who want to combine ArcGIS REST JS along with their library of choice to access ArcGIS services.
The ArcGIS Maps SDK for JavaScript is Esri's flagship product for building web applications to visualize, edit, map and analyze geospatial data. It is a feature complete client side API for working with ArcGIS Location Services. The ArcGIS Maps SDK for JavaScript includes significant client side functionality including smart mapping, 3D rendering, geometric analysis and feature editing, as well as full support for working with web maps and web scenes.
However, the goal of ArcGIS REST JS is to provide a convenient and light-weight binding to the ArcGIS Location Services REST APIs for developers who need to work directly with it using JavaScript or TypeScript. This includes functional equivalents of the low-level request methods, identity management, server federation, along with additional thin wrappers to assist developers in scripting against the ArcGIS REST APIs directly in Node.js and browser applications.
| ArcGIS REST JS | ArcGIS Maps SDK for JavaScript | |
|---|---|---|
| Display maps and layers | ||
| Complete mapping library | ||
| Support for a wide variety of ArcGIS services | 1 | |
| Support for additional authentication options | ||
| Geometry engine | ||
| Light-weight package footprint |
- 1. Not all ArcGIS Location Services are currently supported
This project is similar to the ArcGIS API for Python in many ways. Like the ArcGIS API for Python, this library aims to be a scripting tool that simplifies interacting with ArcGIS services. However, the ArcGIS API for Python highlights integration with dataframes and Jupyter Notebooks for visualization and sharing, whereas ArcGIS REST JS provides APIs for TypeScript or JavaScript applications running on a server, CLI, in a browser, or as a script.
ArcGIS REST JS attempts for as few tradeoffs as possible over making requests with tools like fetch. ArcGIS REST JS automatically handles proper parameter encoding for ArcGIS REST APIs, has error handling, token management and more.
Before tree shaking, all of this logic is ~8kb. Additional methods are around 1kb each or less, making the cost of adding ArcGIS REST JS to your application low.
You need either an ArcGIS Location Platform account or ArcGIS Online account to access ArcGIS Location Services. This will give you the ability to access the portal, create developer credentials, and manage your data.
You can not use an ArcGIS Enterprise account to access ArcGIS Location Services.
The table below shows the account types you can use to access each service:
You can find the official community at Esri Community.
Go to the GitHub repo, post issues and review the contributing guidelines.
Visit the Mapping and location services guide.
Go to the Glossary.
ArcGIS services
ArcGIS services are software that support an ArcGIS REST API and provides geospatial functionality or data. ArcGIS provides many types of services, such as location services
ArcGIS REST JS has built in functionality to access the following ArcGIS services:
- ArcGIS GeoEnrichment service
- ArcGIS Routing service
- ArcGIS Geocoding service
- ArcGIS Elevation service
- ArcGIS Places service
- Vector tile service
- Map tile service
- Map service
- Feature service
If you need to work with other capabilities, such as the spatial analysis servicerequest method from the @esri/arcgis-rest-request package.
You need either an ArcGIS Location Platform account or ArcGIS Online account to access ArcGIS Location Services. This will give you the ability to access the portal, create developer credentials, and manage your data.
You can not use an ArcGIS Enterprise account to access ArcGIS Location Services.
The table below shows the account types you can use to access each service:
ArcGIS Location Services
Yes, you need to provide an API key or implement another type of authentication to access ArcGIS Location Services
ArcGIS Enterprise services
For services that are private, yes, you need to provide authentication to access ArcGIS Enterprise services. You typically implement OAuth 2.0 to do so. Public services do not require authentication.
To learn more about the different types of authentication, go to Types of authentication.
To learn more about ArcGIS Location Services and capabilities, go to the Mapping and location services guide.
To learn more about ArcGIS Enterprise services and capabilities, go to the REST API documentation.
Data services
Data services
-
Feature services
A feature service is a data service that provides access to spatial and non-spatial data in feature layers, feature layer views, and tables. -
Vector tile services
A vector tile service is a data service that provides access to vector tile data and a style definition. -
Map tile services
A map tile service, formerly known as image tile service, is a data service that provides access to static, pre-rendered mao tiles. The tiles are typical in PNG format. Map tiles are typically retrieved by specifying a specific level, row, and column value. -
Image services
An image service is a data service that can store, process, analyze, and share raster data.
Data services are typically created by importing data with the data management tools
The type of data service you use depends on the product you have, the format of your existing data, storage and output data format requirements, the size and complexity of the data, and the service functionality required.
Below is an overview of the main services and the data type each supports.
| Data service | Data type | Data output | Use cases |
|---|---|---|---|
| Feature service | Feature (geometry and/or attributes) | JSON, PBF, GeoJSON | Display, visualization, editing, updating, accessing geometry, accessing attributes |
| Vector tile service | Vector tile | PBF | Display, styling, accessing attributes |
| Map tile service | Map tile | PNG32 | Display |
| Image service | Static and dynamic tiles | JPEG, PNG, LERC | Display, visualization, anlaysis, mosaicking images |
Yes, Esri offers data hosting through ArcGIS Location Platform
ArcGIS Location Platform
With ArcGIS Enterprise
You can import and host many different types of geographic data as data services
To learn more about supported data types, go to Portal and data services > Data services.
No, your data is your data. You retain complete ownership of your content.
Service usage and billing
The cost to access ArcGIS location services
-
If you have an ArcGIS Location Platform account
An ArcGIS Location Platform account, formerly known as an ArcGIS Developer account, is an identity associated with an ArcGIS Location Platform subscription. , you are billed in US dollars. To determine the cost of accessing different services, go to Pricing. A free tier of access is available for some services. -
If you have an ArcGIS Online account
An ArcGIS Online account, also known as an ArcGIS Organization account, is an identity associated with an ArcGIS Online subscription. It can be used to access ArcGIS tools and develop applications with ArcGIS location services for an organization. , you are billed in creditsCredits are the currency used by ArcGIS Online Organization accounts to account for data storage and location service consumption. Credits are consumed for specific transactions, such as accessing location services, and types of storage, such as storing features, performing analytics, and using premium content. . To determine the cost of accessing different services, go to Understanding credits.
If you have ArcGIS Enterprise, there is no cost for accessing your own ArcGIS services.
To find the Esri Terms of Use, go to Terms of use.