Sha256: dcd67a569c3c04e86d6600867d700a30572e3378cd8b41cefc1206bbf22e56ec

Contents?: true

Size: 554 Bytes

Versions: 11

Compression:

Stored size: 554 Bytes

Contents

# frozen_string_literal: true

module SolidusPaypalCommercePlatform
  class AccessTokenAuthorizationRequest
    attr_accessor :verb, :path, :headers, :body

    def initialize(environment:, auth_code:, nonce:)
      @verb = "POST"
      @path = "/v1/oauth2/token"
      @headers = {
        "Content-Type" => "application/x-www-form-urlencoded",
        "Authorization" => environment.authorization_string,
      }
      @body = {
        grant_type: "authorization_code",
        code: auth_code,
        code_verifier: nonce,
      }
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
solidus_paypal_commerce_platform-1.0.3 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-1.0.2 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-0.7.1 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-1.0.1 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-1.0.0 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-0.7.0 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-1.0.0.beta3 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-1.0.0.beta2 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-1.0.0.beta1 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-0.6.0 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb
solidus_paypal_commerce_platform-0.5.0 lib/solidus_paypal_commerce_platform/access_token_authorization_request.rb