IAuthenticationManager

Interface

Authentication can be supplied to request via UserSession or ApplicationSession. Both classes extend IAuthenticationManager.

const session = new UserSession({
  username: "jsmith",
  password: "123456",
  // optional
  portal: "https://[yourserver]/arcgis/sharing/rest"
})

request(url, { authentication: session })

Properties

Property Type Notes
portal string

Defaults to 'https://www.arcgis.com/sharing/rest'.

Methods

Method Returns Notes
Promise<string>
RequestCredentials

getToken

Interface Method

Parameters

Parameter Type Default Notes
url Required string
requestOptions Optional ITokenRequestOptions

Returns

Promise<string>

getDomainCredentials

Optional Interface Method

  • getDomainCredentials(url: string) : RequestCredentials

Parameters

Parameter Type Default Notes
url Required string

Returns

RequestCredentials

Interface defined in packages/arcgis-rest-request/src/utils/IAuthenticationManager.ts:15