# Class DefaultArcGISRequestHelper

A utilities/RequestHelper!RequestHelper for making requests to ArcGIS services.

The request helper supports caching of responses. To control how long responses are cached, set the ttl option when making requests.

#### Implements

- ArcGISRequestHelper

#####
Index

### Constructors

constructor

### Properties

batchLayerRequests
ttl

### Methods

createSocket
request

##
Constructors

### constructor

- new DefaultArcGISRequestHelper(properties?): DefaultArcGISRequestHelper

- #### Parameters

  - `Optional` properties: ArcGISRequestOptions

  #### Returns DefaultArcGISRequestHelper

##
Properties

### batchLayerRequests

batchLayerRequests: boolean

If true, the first request for a single layer in a MapServer will cause all layers to be fetched at once.

Implementation of ArcGISRequestHelper.batchLayerRequests

### ttl

ttl: number

The amount of time (in milliseconds) to cache the response for. The default is 30 seconds.

Implementation of ArcGISRequestHelper.ttl

##
Methods

### createSocket

- createSocket(url): WebSocket

- Creates and returns a WebSocket object.

  #### Parameters

  - url: string

    The web socket URL.

  #### Returns WebSocket

### request

- request<T>(url, options?): Promise<ArcGISRequestHelperResponse<T>>

- Makes a request to a url and returns a response.

  #### Type Parameters

  - T = unknown

  #### Parameters

  - url: string

    The URL at which to send the request.

  - `Optional` options: ArcGISRequestOptions

    The options for the request.

  #### Returns Promise<ArcGISRequestHelperResponse<T>>

  Implementation of ArcGISRequestHelper.request