Xero.Auth.Token (Xero v1.0.0)

Copy Markdown View Source

Represents a Xero OAuth 2.0 token pair.

Summary

Types

t()

@type t() :: %Xero.Auth.Token{
  access_token: String.t(),
  expires_at: DateTime.t(),
  id_token: String.t() | nil,
  refresh_token: String.t() | nil,
  scopes: [String.t()],
  token_type: String.t()
}

Functions

auth_header(token)

@spec auth_header(t()) :: {String.t(), String.t()}

from_response(resp)

@spec from_response(map()) :: t()