Sha256: 4cb6586ed2524b1f259b26f216ad50b558ef9c21fbfd78505045d34267667b70

Contents?: true

Size: 983 Bytes

Versions: 4

Compression:

Stored size: 983 Bytes

Contents

# frozen_string_literal: true

require 'oauth2'

module MicrosoftKiotaAuthenticationOAuth
    # Module that can be optionally implemented for supporting custom token grant flows.
    # To use a cutsom token grant flow, implement the functions below and 
    # use MicrosoftKiotaAuthenticationOAuth::OAuthContext.new as your token_request_context
    # object for the use by the MicrosoftKiotaAuthenticationOAuth::OAuthAccessTokenProvider
    module OAuthCustomFlow
        # Function that returns an oauth client using the oauth2 gem 
        def self.get_oauth_provider
            raise NotImplementedError.new
        end

        # Function that returns a space seperated string of scopes, beginning with 
        # the offline_access scope if relevant
        def self.get_scopes
            raise NotImplementedError.new
        end

        # Function that returns the access token 
        def self.get_token 
            raise NotImplementedError.new
        end
    end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
microsoft_kiota_authentication_oauth-0.8.0 lib/microsoft_kiota_authentication_oauth/contexts/oauth_custom_flow.rb
microsoft_kiota_authentication_oauth-0.7.0 lib/microsoft_kiota_authentication_oauth/contexts/oauth_custom_flow.rb
microsoft_kiota_authentication_oauth-0.6.0 lib/microsoft_kiota_authentication_oauth/contexts/oauth_custom_flow.rb
microsoft_kiota_authentication_oauth-0.5.0 lib/microsoft_kiota_authentication_oauth/contexts/oauth_custom_flow.rb