DocuSign v0.1.2 DocuSign.OAuth View Source

This module implements an oauth2 strategy for DocuSign.

Examples

client = DocuSign.OAuth2Strategy.get_token! {:ok, user_info } = OAuth2.Client.get(client, “/oauth/userinfo”)

Link to this section Summary

Functions

Create new API client

Retrieve access token and return a client

Retrieve a new time to auto refresh token

Check expiration of token return true if token is expired

Link to this section Types

Link to this type headers() View Source
headers() :: [{binary(), binary()}]
Link to this type param() View Source
param() :: binary() | %{optional(binary()) => param()} | [param()]
Link to this type params() View Source
params() :: %{optional(binary()) => param()} | Keyword.t()

Link to this section Functions

Link to this function authorize_url(client, params) View Source

Create new API client

Link to this function get_token!(client, params \\ [], headers \\ [], opts \\ []) View Source

Retrieve access token and return a client

Link to this function get_token(client, params, headers) View Source
get_token(OAuth2.Client.t(), Keyword.t(), Keyword.t()) :: binary()
Link to this function interval_refresh_token(client) View Source
interval_refresh_token(OAuth2.Client.t()) :: integer()

Retrieve a new time to auto refresh token.

Link to this function refresh_token!(client, force \\ false) View Source
refresh_token!(OAuth2.Client.t(), boolean()) :: OAuth2.Client.t()

Refresh token

Link to this function token_expired?(token) View Source
token_expired?(OAuth2.AccessToken.t() | nil | OAuth2.Client.t()) :: boolean()

Check expiration of token return true if token is expired