flowcommerce 0.0.45 → 0.0.46

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 66bbca2281967a2708da56dfe063a8a7baab9370
4
- data.tar.gz: 507ac2ae0fba539530eab52f4cb4d1a9a09412f1
3
+ metadata.gz: 2acb519c93e770c0deed1994b8dde5bb66a436d5
4
+ data.tar.gz: ef8f7ed4b5c701667dfd3c4696fba019c672ab03
5
5
  SHA512:
6
- metadata.gz: 69b0c2a6752b6cdd293f530be330402fde9087212ff57cfda8305efc4a06bb0c03f68a191370b527bfacfca8a43a3feefce1329e91bb2d5b050bd494dbea1c97
7
- data.tar.gz: 321c3223c193176fc2d3fd25d3da9a54710cff313c3524ff49ee26e6a033f263971d8292c24481986ea734911da50c898b089ae5d3e84123fe1332d3d4df5748
6
+ metadata.gz: c530b5a6e947b680ffd6aa23bc96c2690e3f1a8f832cc56014c2feab24bb44f48f6e464fc546ce2dc6bfa981321cdcd2eee980833e2224c1a20d62b7578c79ff
7
+ data.tar.gz: 248eb7c660bf13a5ce07aef64d41f33d3fdfe5b401f03696fe3f4cffda1850f231351d9ca513b3348d45464d144293163af931e105f2457dec6dcb60ac3b296e
@@ -1,6 +1,6 @@
1
1
  # Generated by apidoc - http://www.apidoc.me
2
- # Service version: 0.1.26
3
- # apidoc:0.11.35 http://www.apidoc.me/flow/api/0.1.26/ruby_client
2
+ # Service version: 0.1.29
3
+ # apidoc:0.11.36 http://www.apidoc.me/flow/api/0.1.29/ruby_client
4
4
 
5
5
  require 'cgi'
6
6
  require 'net/http'
@@ -25,8 +25,8 @@ module Io
25
25
 
26
26
  BASE_URL = 'https://api.flow.io' unless defined?(Constants::BASE_URL)
27
27
  NAMESPACE = 'io.flow.v0' unless defined?(Constants::NAMESPACE)
28
- USER_AGENT = 'apidoc:0.11.35 http://www.apidoc.me/flow/api/0.1.26/ruby_client' unless defined?(Constants::USER_AGENT)
29
- VERSION = '0.1.26' unless defined?(Constants::VERSION)
28
+ USER_AGENT = 'apidoc:0.11.36 http://www.apidoc.me/flow/api/0.1.29/ruby_client' unless defined?(Constants::USER_AGENT)
29
+ VERSION = '0.1.29' unless defined?(Constants::VERSION)
30
30
  VERSION_MAJOR = 0 unless defined?(VERSION_MAJOR)
31
31
 
32
32
  end
@@ -3153,6 +3153,13 @@ module Io
3153
3153
  nil
3154
3154
  end
3155
3155
 
3156
+ # Returns currencies for a specific organization.
3157
+ def get_settings_and_currencies_by_organization_id(organization_id)
3158
+ HttpClient::Preconditions.assert_class('organization_id', organization_id, String)
3159
+ r = @client.request("/organizations/#{CGI.escape(organization_id)}/settings/currencies").get
3160
+ r.map { |x| ::Io::Flow::V0::Models::Currency.new(x) }
3161
+ end
3162
+
3156
3163
  # Provides visibility into recent changes of each object, including deletion
3157
3164
  def get_versions(incoming={})
3158
3165
  opts = HttpClient::Helper.symbolize_keys(incoming)
@@ -4184,22 +4191,28 @@ module Io
4184
4191
  end
4185
4192
 
4186
4193
  def AvsCode.ALL
4187
- @@all ||= [AvsCode.match, AvsCode.no_match, AvsCode.not_supported]
4194
+ @@all ||= [AvsCode.match, AvsCode.partial, AvsCode.unsupported, AvsCode.no_match]
4188
4195
  end
4189
4196
 
4190
- # Address matches expected values
4197
+ # Full match
4191
4198
  def AvsCode.match
4192
4199
  @@_match ||= AvsCode.new('match')
4193
4200
  end
4194
4201
 
4195
- # Address does not match expected card values
4196
- def AvsCode.no_match
4197
- @@_no_match ||= AvsCode.new('no_match')
4202
+ # Partial match; see details in 'avs' model to undestand which components
4203
+ # matched
4204
+ def AvsCode.partial
4205
+ @@_partial ||= AvsCode.new('partial')
4198
4206
  end
4199
4207
 
4200
4208
  # Issuer does not support address verification
4201
- def AvsCode.not_supported
4202
- @@_not_supported ||= AvsCode.new('not_supported')
4209
+ def AvsCode.unsupported
4210
+ @@_unsupported ||= AvsCode.new('unsupported')
4211
+ end
4212
+
4213
+ # Address does not match expected card values
4214
+ def AvsCode.no_match
4215
+ @@_no_match ||= AvsCode.new('no_match')
4203
4216
  end
4204
4217
 
4205
4218
  def to_hash
@@ -4431,7 +4444,7 @@ module Io
4431
4444
  end
4432
4445
 
4433
4446
  def CvvCode.ALL
4434
- @@all ||= [CvvCode.match, CvvCode.no_match, CvvCode.not_supported]
4447
+ @@all ||= [CvvCode.match, CvvCode.suspicious, CvvCode.unsupported, CvvCode.no_match]
4435
4448
  end
4436
4449
 
4437
4450
  # CVV matches
@@ -4439,14 +4452,19 @@ module Io
4439
4452
  @@_match ||= CvvCode.new('match')
4440
4453
  end
4441
4454
 
4442
- # CVV did not match
4443
- def CvvCode.no_match
4444
- @@_no_match ||= CvvCode.new('no_match')
4455
+ # CVV did not match; Transaction is possibly fraudulent
4456
+ def CvvCode.suspicious
4457
+ @@_suspicious ||= CvvCode.new('suspicious')
4458
+ end
4459
+
4460
+ # CVV did not match; Issuer does not support card verification numbers
4461
+ def CvvCode.unsupported
4462
+ @@_unsupported ||= CvvCode.new('unsupported')
4445
4463
  end
4446
4464
 
4447
- # Issuer does not support card verification numbers
4448
- def CvvCode.not_supported
4449
- @@_not_supported ||= CvvCode.new('not_supported')
4465
+ # CVV did not match; Specific reason not available
4466
+ def CvvCode.no_match
4467
+ @@_no_match ||= CvvCode.new('no_match')
4450
4468
  end
4451
4469
 
4452
4470
  def to_hash
@@ -6397,12 +6415,15 @@ module Io
6397
6415
  # Represents the address verification results
6398
6416
  class Avs
6399
6417
 
6400
- attr_reader :code, :description
6418
+ attr_reader :code, :name, :address, :postal, :description
6401
6419
 
6402
6420
  def initialize(incoming={})
6403
6421
  opts = HttpClient::Helper.symbolize_keys(incoming)
6404
6422
  HttpClient::Preconditions.require_keys(opts, [:code], 'Avs')
6405
6423
  @code = (x = opts.delete(:code); x.is_a?(::Io::Flow::V0::Models::AvsCode) ? x : ::Io::Flow::V0::Models::AvsCode.apply(x))
6424
+ @name = (x = opts.delete(:name); x.nil? ? nil : HttpClient::Preconditions.assert_boolean('name', x))
6425
+ @address = (x = opts.delete(:address); x.nil? ? nil : HttpClient::Preconditions.assert_boolean('address', x))
6426
+ @postal = (x = opts.delete(:postal); x.nil? ? nil : HttpClient::Preconditions.assert_boolean('postal', x))
6406
6427
  @description = (x = opts.delete(:description); x.nil? ? nil : HttpClient::Preconditions.assert_class('description', x, String))
6407
6428
  end
6408
6429
 
@@ -6417,6 +6438,9 @@ module Io
6417
6438
  def to_hash
6418
6439
  {
6419
6440
  :code => code.value,
6441
+ :name => name,
6442
+ :address => address,
6443
+ :postal => postal,
6420
6444
  :description => description
6421
6445
  }
6422
6446
  end
@@ -6570,7 +6594,7 @@ module Io
6570
6594
 
6571
6595
  class CardForm
6572
6596
 
6573
- attr_reader :number, :cipher, :expiration_month, :expiration_year, :name, :cvv, :address, :challenge
6597
+ attr_reader :number, :cipher, :expiration_month, :expiration_year, :name, :cvv, :address, :challenge_text, :challenge_cipher
6574
6598
 
6575
6599
  def initialize(incoming={})
6576
6600
  opts = HttpClient::Helper.symbolize_keys(incoming)
@@ -6582,7 +6606,8 @@ module Io
6582
6606
  @name = HttpClient::Preconditions.assert_class('name', opts.delete(:name), String)
6583
6607
  @cvv = (x = opts.delete(:cvv); x.nil? ? nil : HttpClient::Preconditions.assert_class('cvv', x, String))
6584
6608
  @address = (x = opts.delete(:address); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::Address) ? x : ::Io::Flow::V0::Models::Address.new(x)))
6585
- @challenge = (x = opts.delete(:challenge); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::Challenge) ? x : ::Io::Flow::V0::Models::Challenge.new(x)))
6609
+ @challenge_text = (x = opts.delete(:challenge_text); x.nil? ? nil : HttpClient::Preconditions.assert_class('challenge_text', x, String))
6610
+ @challenge_cipher = (x = opts.delete(:challenge_cipher); x.nil? ? nil : HttpClient::Preconditions.assert_class('challenge_cipher', x, String))
6586
6611
  end
6587
6612
 
6588
6613
  def to_json
@@ -6602,7 +6627,8 @@ module Io
6602
6627
  :name => name,
6603
6628
  :cvv => cvv,
6604
6629
  :address => address.nil? ? nil : address.to_hash,
6605
- :challenge => challenge.nil? ? nil : challenge.to_hash
6630
+ :challenge_text => challenge_text,
6631
+ :challenge_cipher => challenge_cipher
6606
6632
  }
6607
6633
  end
6608
6634
 
@@ -7223,36 +7249,6 @@ module Io
7223
7249
 
7224
7250
  end
7225
7251
 
7226
- # Challenge provides a text string and an encryption of that string which is
7227
- # used server side to verify that encryption worked as expected.
7228
- class Challenge
7229
-
7230
- attr_reader :text, :cipher
7231
-
7232
- def initialize(incoming={})
7233
- opts = HttpClient::Helper.symbolize_keys(incoming)
7234
- HttpClient::Preconditions.require_keys(opts, [:text, :cipher], 'Challenge')
7235
- @text = HttpClient::Preconditions.assert_class('text', opts.delete(:text), String)
7236
- @cipher = HttpClient::Preconditions.assert_class('cipher', opts.delete(:cipher), String)
7237
- end
7238
-
7239
- def to_json
7240
- JSON.dump(to_hash)
7241
- end
7242
-
7243
- def copy(incoming={})
7244
- Challenge.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
7245
- end
7246
-
7247
- def to_hash
7248
- {
7249
- :text => text,
7250
- :cipher => cipher
7251
- }
7252
- end
7253
-
7254
- end
7255
-
7256
7252
  # The actual value of the API token. This is modeled as a separate resource as
7257
7253
  # it is fetched only on demand.
7258
7254
  class Cleartext
@@ -13267,16 +13263,16 @@ module Io
13267
13263
 
13268
13264
  class ShippingLabelForm
13269
13265
 
13270
- attr_reader :service, :destination, :origin, :packages, :delivered_duty, :insurance
13266
+ attr_reader :service, :delivered_duty, :destination, :origin, :packages, :insurance
13271
13267
 
13272
13268
  def initialize(incoming={})
13273
13269
  opts = HttpClient::Helper.symbolize_keys(incoming)
13274
- HttpClient::Preconditions.require_keys(opts, [:service, :destination, :origin, :packages], 'ShippingLabelForm')
13270
+ HttpClient::Preconditions.require_keys(opts, [:service, :delivered_duty, :destination, :origin, :packages], 'ShippingLabelForm')
13275
13271
  @service = HttpClient::Preconditions.assert_class('service', opts.delete(:service), String)
13272
+ @delivered_duty = (x = opts.delete(:delivered_duty); x.is_a?(::Io::Flow::V0::Models::DeliveredDuty) ? x : ::Io::Flow::V0::Models::DeliveredDuty.apply(x))
13276
13273
  @destination = (x = opts.delete(:destination); x.is_a?(::Io::Flow::V0::Models::ShippingAddress) ? x : ::Io::Flow::V0::Models::ShippingAddress.new(x))
13277
13274
  @origin = (x = opts.delete(:origin); x.is_a?(::Io::Flow::V0::Models::ShippingAddress) ? x : ::Io::Flow::V0::Models::ShippingAddress.new(x))
13278
13275
  @packages = HttpClient::Preconditions.assert_class('packages', opts.delete(:packages), Array).map { |v| (x = v; x.is_a?(::Io::Flow::V0::Models::ShippingLabelPackage) ? x : ::Io::Flow::V0::Models::ShippingLabelPackage.new(x)) }
13279
- @delivered_duty = (x = opts.delete(:delivered_duty); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::DeliveredDuty) ? x : ::Io::Flow::V0::Models::DeliveredDuty.apply(x)))
13280
13276
  @insurance = (x = opts.delete(:insurance); x.nil? ? nil : (x = x; x.is_a?(::Io::Flow::V0::Models::Price) ? x : ::Io::Flow::V0::Models::Price.new(x)))
13281
13277
  end
13282
13278
 
@@ -13291,10 +13287,10 @@ module Io
13291
13287
  def to_hash
13292
13288
  {
13293
13289
  :service => service,
13290
+ :delivered_duty => delivered_duty.value,
13294
13291
  :destination => destination.to_hash,
13295
13292
  :origin => origin.to_hash,
13296
13293
  :packages => packages.map { |o| o.to_hash },
13297
- :delivered_duty => delivered_duty.nil? ? nil : delivered_duty.value,
13298
13294
  :insurance => insurance.nil? ? nil : insurance.to_hash
13299
13295
  }
13300
13296
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flowcommerce
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.45
4
+ version: 0.0.46
5
5
  platform: ruby
6
6
  authors:
7
7
  - Flow Commerce, Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-08-29 00:00:00.000000000 Z
11
+ date: 2016-08-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json