Class: Webhookdb::Oauth::Provider

Inherits:
Object
  • Object
show all
Defined in:
lib/webhookdb/oauth.rb

Instance Method Summary collapse

Instance Method Details

#app_nameString

Returns Name of the app to present to users.

Returns:

  • (String)

    Name of the app to present to users.

Raises:

  • (NotImplementedError)


19
# File 'lib/webhookdb/oauth.rb', line 19

def app_name = raise NotImplementedError

#authorization_url(state:) ⇒ String

Returns The Oauth URL to send users to to begin OAuth.

Returns:

  • (String)

    The Oauth URL to send users to to begin OAuth.

Raises:

  • (NotImplementedError)


28
# File 'lib/webhookdb/oauth.rb', line 28

def authorization_url(state:) = raise NotImplementedError

#build_marketplace_integrations(organization:, tokens:) ⇒ Webhookdb::ServiceIntegration

Create the actual service integrations for the given org.

Parameters:

Returns:

Raises:

  • (NotImplementedError)


38
# File 'lib/webhookdb/oauth.rb', line 38

def build_marketplace_integrations(organization:, tokens:) = raise NotImplementedError

#exchange_authorization_code(code:) ⇒ Webhookdb::Oauth::Tokens

Exchange the access code (from the authorization url) for access and/or refresh tokens.

Returns:

Raises:

  • (NotImplementedError)


32
# File 'lib/webhookdb/oauth.rb', line 32

def exchange_authorization_code(code:) = raise NotImplementedError

#keyString

Returns Unique key to identify the provider.

Returns:

  • (String)

    Unique key to identify the provider.

Raises:

  • (NotImplementedError)


16
# File 'lib/webhookdb/oauth.rb', line 16

def key = raise NotImplementedError

#supports_webhooks?Boolean

This is similar to ‘supports_webhooks` in the Replicator descriptors, except that this is used to make the success page dynamic. True if this provider’s integrations support webhooks (real-time or user-built webhook payloads).

Returns:

  • (Boolean)

Raises:

  • (NotImplementedError)


25
# File 'lib/webhookdb/oauth.rb', line 25

def supports_webhooks? = raise NotImplementedError