add

fun add(arcGISCredential: ArcGISCredential)

Adds the specified credential to the ArcGISCredentialStore. The credential's server context is used to determine what services the credential can be shared with. If a credential for the same server context is already in the store, then it will be replaced.

Since

200.1.0

See also


fun add(arcGISCredential: ArcGISCredential, url: String): Result<Unit>

Adds a specified credential to the store for a given URL. The URL must be shareable with the server context of the credential. Otherwise, this method throws an ErrorType.AuthenticationCredentialCannotBeShared. When the credential is added to the store with this function, for the credential to be shared with a secured service endpoint, the service endpoint must begin with the specified URL passed to this function call. For example, if you were to specify a store URL of https://www.server.net/arcgis/rest/services/service1/ when calling this function, then the specified credential would be shared with an endpoint such as https://www.server.net/arcgis/rest/services/service1/query, but not for https://www.server.net/arcgis/rest/services/service2/query. If a credential was already stored for the same URL then it will be replaced.

Since

200.1.0

See also

(ArcGISCredential)