Skip to content

Commit

Permalink
Merge 1a813c9 into 8eb5f6e
Browse files Browse the repository at this point in the history
  • Loading branch information
jgravois committed Jul 23, 2018
2 parents 8eb5f6e + 1a813c9 commit 8885c80
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/arcgis-rest-auth/src/UserSession.ts
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ export interface IUserSessionOptions {
* ```
* Used to manage the authentication of ArcGIS Online and ArcGIS Enterprise users
* in `request`. This class also includes several
* helper methods for authenticating users with OAuth 2.0 in both browser and
* helper methods for authenticating users with [OAuth 2.0](https://developers.arcgis.com/documentation/core-concepts/security-and-authentication/browser-based-user-logins/) in both browser and
* server applications.
*
*/
Expand Down
2 changes: 1 addition & 1 deletion packages/arcgis-rest-items/src/items.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export interface IItemCrudRequestOptions extends IUserRequestOptions {
*/
owner?: string;
/**
* Folder to house the item.
* Id of the folder to house the item.
*/
folder?: string;
}
Expand Down
16 changes: 16 additions & 0 deletions packages/arcgis-rest-request/src/request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,23 @@ import { encodeQueryString } from "./utils/encode-query-string";
import { requiresFormData } from "./utils/process-params";
import { ArcGISRequestError } from "./utils/ArcGISRequestError";

/**
* Authentication can be supplied to `request` via [`UserSession`](../../auth/UserSession/) or [`ApplicationSession`](../../auth/ApplicationSession/). Both classes extend `IAuthenticationManager`.
* ```js
* const session = new UserSession({
* username: "jsmith",
* password: "123456",
* // optional
* portal: "https://[yourserver]/arcgis/sharing/rest"
* })
*
* request(url, { authentication: session })
* ```
*/
export interface IAuthenticationManager {
/**
* Defaults to 'https://www.arcgis.com/sharing/rest'.
*/
portal: string;
getToken(url: string): Promise<string>;
}
Expand Down

0 comments on commit 8885c80

Please sign in to comment.