RingCentral.OAuth.authorize

You're seeing just the function authorize, go back to RingCentral.OAuth module for more information.
Link to this function

authorize(ringcentral, params \\ %{})

View Source

Specs

authorize(RingCentral.t(), map()) ::
  {:error, RingCentral.Error.t()} | {:ok, String.t()}

Get the URL for initializing the OAuth 2.0 authorizaiton flow.

params is a map contains the options described in the official documentation

Example

ringcentral = %RingCentral{
  client_id: "the-client-id",
  client_secret: "the-client-secret",
  http_client: RingCentral.HTTPClient.DefaultClient,
  server_url: "https://platform.ringcentral.com",
  token_info: nil
}

{:ok, authorization_url} = RingCentral.OAuth.authorize(ringcentral, %{
  response_type: "code",
  redirect_uri: "https://ringcentral-elixir.test"
})
# {:ok, "https://service.ringcentral.com/..."}