Create Buffers

A buffer is an area that covers a given distance from a point, line, or area feature.

Buffers are typically used to create areas that can be further analyzed using other tools such as Aggregate Points. For example, if asking the question "What buildings are within one mile of the school?", the answer can be found by creating a one-mile buffer around the school and overlaying the buffer with the layer containing building footprints. The end result is a layer of those buildings within one mile of the school.

Request URL

http://<analysis url>/CreateBuffers/submitJob

Request parameters

Parameter

Description

inputLayer

(Required)

The point, line, or polygon features to be buffered.

Syntax: As described in detail in the Feature input topic, this parameter can be one of the following:

A URL to a feature service layer with an optional filter to select specific features

A URL to a big data catalog service layer with an optional filter to select specific features

A feature collection

Examples:

{"url": <feature service layer url>, "filter": <where clause>}

{"layerDefinition": {}, "featureSet": {}, "filter": <where clause>}

distance

(Required if field is not provided)

A double value used to buffer the input features. You must supply a value for either the distance or field parameter. You can only enter a single distance value. The units of the distance value are supplied by the distanceUnit parameter.

Examples:

"distance" : 4

"distance" : 53.4

distanceUnit

(Required if distance is used)

The linear unit to be used with the value specified in distance.

Values: Meters | Kilometers | Feet | Miles | NauticalMiles | Yards

The default is Meters.

Example: "distanceUnit" : "Miles"

field

(Required if distance not provided)

A field on the inputLayer containing a buffer distance or a field expression.

Examples:

"field": "Setback"

"field": "= Setback * 3 + TreeCoverage"

A buffer expression must begin with an equal sign (=). To learn more about buffer expressions see: Buffer Expressions

method

(Required)

The method used to apply the buffer with. There are two methods to choose from:

Planar—This method applies a Euclidean buffers and is appropriate for local analysis on projected data. This is the default.

Geodesic—This method is appropriate for
large areas and any geographic coordinate system.

Example: "method" : "Geodesic"

dissolveOption

Determines how output polygon attributes are processed.

Values: All | List|None

Value

Description

All— All features are dissolved into one feature.

You can calculate summary statistics and determine if you want multipart or single part features.

List— Features with the same value in the specified field will be dissolve together.

You can calculate summary statistics and determine if you want multipart or single part features.

None— No features are dissolved. This is the default.

There are no additional dissolve options.

Example: "dissolveOption": "All"

dissolveFields

(Required if dissolveOption is List)

Specifies the fields to dissolve on. Multiple fields may be provided.

Examples:

"dissolveFields": "Setback"

"dissolveFields": "Setback, Tree Coverage"

multipart

Determines if output features are multipart or single part. Default is single part. This option is only available if a dissolveOption is applied.

Values: true| false

Example: multipart = False.

summaryFields

A list of field names and statistical summary
types that you want to calculate for resulting polygons. Summary statistics are only available if dissolveOption = List or All. By default, all statistics are returned.

Output spatial reference (outSR)—The features will be projected into this coordinate system after the analysis to be saved. The output spatial reference for the spatiotemporal big data store is always WGS84.

Data store (dataStore)— Results will be saved to the specified data store. The default is the spatiotemporal big data store.

Response

When you submit a request, the service assigns a unique job ID for
the transaction.

Syntax:

{"jobId":"<unique job identifier>","jobStatus":"<job status>"}

After the initial
request is submitted, you can use jobId to periodically check the status of the job and messages as described in Checking job status.
Once the job has successfully completed, use
the jobId to retrieve the results. To track the status, you can make a request of the following form:

http://<analysis url>/CreateBuffers/jobs/<jobId>

Accessing results

When the status of the job request is esriJobSucceeded, you can access the results of the analysis by making a request of the following form:

output returns the buffered features as polygons. Is a summaryFields parameter is specified in the task request, the layer will compute the Count statistics, as well as anything in the summaryFields. These statistics are only calculated on the dissolved fields.

The result has properties for parameter name, data type, and value. The contents of value depend on the outputName parameter provided in the initial request. The value contains the URL of the feature service layer.