Sha256: 14ffe3d8af0eb47af46b3aee41ef373c5fba9598c88c35a869fec77e6f13ba56
Contents?: true
Size: 537 Bytes
Versions: 10
Compression:
Stored size: 537 Bytes
Contents
module Oauth class AuthorizationController < ApplicationController def authorize url = Services::Authorization::GetAuthorizationUri.new(request: request).call redirect_to url end def callback tokens = Services::Authorization::Tokens::Generate.new( code: params[:code], request: request ).call Token.instance.update!(tokens) session['tokens'] = tokens Services::Authorization::AuthorizeHubspot.new(tokens: tokens).call redirect_to '/events' end end end
Version data entries
10 entries across 10 versions & 1 rubygems