Skip to content

sparkartgroup/omniauth-piryx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Omniauth Automatic Strategy

Build Status

Piryx omniauth OAuth2 strategy.

Installation

gem 'omniauth-piryx'
bundle

Usage

Sign up for Piryx and create an application. Once you have the client id and client secret associate them with the OmniAuth strategy.

Example Integration

Rails.application.config.middleware.use OmniAuth::Builder do
  provider :piryx, ENV["PIRYX_CLIENT_ID"], ENV["PIRYX_CLIENT_SECRET"], scope: "never_expire,create_payment,payment_details,payment_summary", sandbox: !Rails.env.production?
end

If a value for sandbox is not passed in the production API will always be used instead.

Scopes

You can change the permissions by selecting from the scopes available and passing them into the configuration above. The default scopes set by this middleware are create_payment and payment_details.