WardrikDaemon.Config.OAuth (wardrik_daemon v0.1.0-rc.1)

Copy Markdown

Reads config.yaml's oauth: the providers people connect accounts with.

oauth:
  providers:
    github:
      issuer: https://github.com/login/oauth
      client_id: ${GITHUB_CLIENT_ID}
      client_secret: ${GITHUB_CLIENT_SECRET}
      scopes: [repo]
      flow: device

Each provider is named like the credential it grants. It takes issuer, resource, client_id, client_secret, authorization_endpoint, token_endpoint, scopes, flow (browser or device) and client_auth (post or basic). See WardrikOAuth.Provider.

Summary

Functions

Returns the providers section names, as WardrikOAuth takes them, or the key that doesn't read.

Functions

read(section)

@spec read(map() | nil) :: {:ok, keyword()} | {:error, String.t()}

Returns the providers section names, as WardrikOAuth takes them, or the key that doesn't read.