Ueberauth Spotify Strategy v0.0.1 Ueberauth.Strategy.Spotify.OAuth View Source

OAuth2 for Spotify.

Add client_id and client_secret to your configuration:

config :ueberauth, Ueberauth.Strategy.Spotify.OAuth,
  client_id: System.get_env("SPOTIFY_CLIENT_ID"),
  client_secret: System.get_env("SPOTIFY_CLIENT_SECRET")

Link to this section Summary

Functions

Provides the authorize url for the request phase of Ueberauth. No need to call this usually

Construct a client for request to Spotify

Helper method to query Spotify API endpoints

Gets the Access Token from Spotify

Link to this section Functions

Link to this function authorize_url!(params \\ [], opts \\ []) View Source

Provides the authorize url for the request phase of Ueberauth. No need to call this usually.

Examples:

iex> Ueberauth.Strategy.Spotify.OAuth.authorize_url!() =~ ~r/^https:\/\/accounts.spotify.com\/authorize/
true

Construct a client for request to Spotify.

This will be setup automatically for youi n Ueberauth.Strategy.Spotify.

These options are only usefule for usage outside the normal callback phase of Ueberauth.

Examples:

iex> Ueberauth.Strategy.Spotify.OAuth.client().__struct__
OAuth2.Client
Link to this function get(token, url, headers \\ [], opts \\ []) View Source

Helper method to query Spotify API endpoints

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

Gets the Access Token from Spotify