Sha256: 1ff1e3914b8c8906ee254fc85479ce1f904c6531104267219d680bb08adead8e
Contents?: true
Size: 700 Bytes
Versions: 136
Compression:
Stored size: 700 Bytes
Contents
module Services module Authorization module Tokens class Generate < Tokens::Base def initialize(code:, request:) @code = code @request = request end def call default_api = ::Hubspot::OAuth::DefaultApi.new tokens = default_api.create_token( grant_type: :authorization_code, code: @code, redirect_uri: redirect_uri, client_id: ENV['HUBSPOT_CLIENT_ID'], client_secret: ENV['HUBSPOT_CLIENT_SECRET'], return_type: 'Object' ) tokens[:expires_at] = expires_at(tokens[:expires_in]) tokens end end end end end
Version data entries
136 entries across 20 versions & 1 rubygems