Typetalk v0.1.2 Typetalk.AuthorizationCode

Function to get an access token using an authorization code.

You use this module when you offer a web service to other people.

Summary

Functions

access_token(client_id, client_secret, redirect_uri, code)
access_token(String.t, String.t, String.t, String.t) ::
  {:ok, Typetalk.AccessToken.t} |
  {:error, HTTPoison.Response}

Returns an access token and related information.

Example

{:ok, auth} = Typetalk.AuthorizationCode.access_token("your-client-id",
                                                      "your-client-secret",
                                                      "https://example.com/oauth_callback",
                                                      "code-returned-by-server")

API Doc

API Doc

authorization_url(client_id, redirect_url, scope \\ "my,topic.read,topi.post")
authorization_url(String.t, String.t, String.t) :: String.t

Returns a URL for the authorization

API Doc

API Doc