Skip to content

Rails Omniauth Strategy for Amazon Selling Partner API

Notifications You must be signed in to change notification settings

ethand91/omniauth-amazon-sp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Omniauth::AmazonSP


Login with Amazon SP OAuth 2 strategy for Omniauth.


Installation

Add the following line to you Gemfile:

gem 'omniauth-amazon-sp'

Then run

bundle install

Requirements

You must have an Amazon Selling Partner Account. As well as a Selling Partner Application.


Configuration

You must have the following Rails credentials set:

amazon_sp_api:
  app_id: [YOUR_APP_ID] 
  client_id: [YOUR_CLIENT_ID] 
  client_secret: [YOUR_CLIENT_SECRET] 
  version: beta (only if your app is in draft state)

Then you can set up the strategy via the following: (devise)

config.omniauth :amazon-sp,
  Rails.application.credentials.dig(:amazon_sp_api, :client_id),
  Rails.application.credentials.dig(:amazon_sp_api, :client_secret),
  name: :amazon
  scope: %w(profile:user_id)

About

Rails Omniauth Strategy for Amazon Selling Partner API

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages