Skip to content

nebulab/riskified_ruby

 
 

Repository files navigation

Riskified API Client

Ruby client for the Riskified API using Faraday. Ruby > 2.0 is required.

Installation

Add this line to your application's Gemfile:

$ gem 'riskified_ruby', github: 'fcpeuro/riskified_ruby'

Usage

API keys

Credentials must be configured before you make API calls using the gem.

Riskified.configure do |config|
  config.auth_token = 'rw342fdj534'
  config.default_referrer = 'www.example.com'
  config.sandbox_mode = true
end
  • config.auth_token - your Riskified access key
  • config.default_referrer - Default referrer
  • config.sandbox_mode - Decide whether or not to use the sandbox endpoint

The keys are available to you throughout your application as:

Riskified.configuration.auth_token
Riskified.configuration.default_referrer
Riskified.configuration.sandbox_mode

Creating the client

client = Riskified::Client.new
client.checkout_create(order)

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

About

Ruby client for the Riskified API

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 98.4%
  • Shell 1.6%