GSS.Registry (elixir_google_spreadsheets v0.4.0)

Google spreadsheets core authorization. Automatically updates access token after expiration.

Summary

Types

State of Google Cloud API

Functions

Returns a specification to start this module under a supervisor.

Callback implementation for GenServer.init/1.

Add or replace Google Spreadsheet in a registry.

Fetch Google Spreadsheet proccess by it's id in the registry.

Get account authorization token.

Types

state()

@type state() :: map()

State of Google Cloud API :

%{
    auth: %Goth.Token{
        expires: 1453356568,
        token: "ya29.cALlJ4HHWRvMkYB-WsAR-CZnexE459yA7QPqKg3nei1y2T7-iqmbcgxb8XrTATNn_Blim",
        type: "Bearer"
    }
}

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

init(state)

@spec init(state()) :: {:ok, state()}

Callback implementation for GenServer.init/1.

new_spreadsheet(spreadsheet_id, pid, opts \\ [])

@spec new_spreadsheet(String.t(), pid(), Keyword.t()) :: :ok

Add or replace Google Spreadsheet in a registry.

spreadsheet_pid(spreadsheet_id, opts \\ [])

@spec spreadsheet_pid(String.t(), Keyword.t()) :: pid() | nil

Fetch Google Spreadsheet proccess by it's id in the registry.

start_link(args \\ [])

@spec start_link(any()) :: {:ok, pid()}

token()

@spec token() :: String.t()

Get account authorization token.