> For the complete documentation index, see [llms.txt](https://deskpro.gitbook.io/deskpro-apps/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://deskpro.gitbook.io/deskpro-apps/app-client-dpapp/using-dpapp/oauth.md).

# oauth

### settings

`settings(provides, options)`

Returns a map of settings required to register a client with `provider`. If `protocolVersion` is not specified in `options` then it defaults to `2.0`

### register

`register(provider, properties)`

Registers an oauth connection for a specific provider

### requestAccess

`requestAccess(provider, options)`

Requests an access token. If `protocolVersion` is not specified in `options` then it defaults to `2.0`if `options` has an object property named `query`, it will be used as additional query parameters appended to the authorization url

### refreshAccess

`refreshAccess(provider, options)`

Refresh an access token. If `protocolVersion` is not specified in `options` then it defaults to `2.0` if `options` has an object property named `query`, it will be used as additional query parameters appended to the token url

Note: the provider must explicitly support the refresh token flow
