flowcommerce 0.0.62 → 0.0.63

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: a57c829e07bb5406968acf5e839b176ebbc5a437
4
- data.tar.gz: 6208530e999188ad8b494356942de27720a6ab24
3
+ metadata.gz: af13d7336fac680f7b272a0a062d76c53af9cef8
4
+ data.tar.gz: 932641e7fecff83894d8dd84d5bd6b27087e8340
5
5
  SHA512:
6
- metadata.gz: 2b8c0291a97ce0bb5b3e2f5689f8e48be410e8a0b6fa2abc74ad19bb8646f11b627e50a73e2e63985af777736041baab761af1531abbe955cc9d32431a6ed2a2
7
- data.tar.gz: 66dfb82f0194d4f3587c22d891b69504aa619bad050f6b56e33ad21946a9dc694c076c080085e1a586e01077e2326e30cb5105b47cbadba99cb816a0ac48a7aa
6
+ metadata.gz: f94313b9e1206a24d73a1d39f471d1484e634459be18fc6eca634fca56624dffee807b81fb5df15a75b839499fd28b979ca353c4d36f20a496ba7bbcc98b3602
7
+ data.tar.gz: 9a093d96b4603fd5feb6745aa3874bfbca80628eab8ccfbe68f26e47b3db5172be0178092fb925ff2f107d1a592b180e3dcb417d8c669cddc567c648891ac646
@@ -1,6 +1,6 @@
1
1
  # Generated by apidoc - http://www.apidoc.me
2
2
  # Service version: 0.1.59
3
- # apidoc:0.11.37 http://www.apidoc.me/flow/api/0.1.62/ruby_client
3
+ # apidoc:0.11.37 http://www.apidoc.me/flow/api/0.1.63/ruby_client
4
4
 
5
5
  require 'cgi'
6
6
  require 'net/http'
@@ -25,7 +25,7 @@ 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.37 http://www.apidoc.me/flow/api/0.1.62/ruby_client' unless defined?(Constants::USER_AGENT)
28
+ USER_AGENT = 'apidoc:0.11.37 http://www.apidoc.me/flow/api/0.1.63/ruby_client' unless defined?(Constants::USER_AGENT)
29
29
  VERSION = '0.1.59' unless defined?(Constants::VERSION)
30
30
  VERSION_MAJOR = 0 unless defined?(VERSION_MAJOR)
31
31
 
@@ -1872,6 +1872,16 @@ module Io
1872
1872
  ::Io::Flow::V0::Models::Card.new(r)
1873
1873
  end
1874
1874
 
1875
+ # Creates a card from a one time nonce. Each nonce can be used at most once
1876
+ # and you will receive a validation error if the nonce has already been
1877
+ # exchanged.
1878
+ def post_nonces(organization, card_nonce_form)
1879
+ HttpClient::Preconditions.assert_class('organization', organization, String)
1880
+ HttpClient::Preconditions.assert_class('card_nonce_form', card_nonce_form, ::Io::Flow::V0::Models::CardNonceForm)
1881
+ r = @client.request("/#{CGI.escape(organization)}/cards/nonces").with_json(card_nonce_form.to_json).post
1882
+ ::Io::Flow::V0::Models::Card.new(r)
1883
+ end
1884
+
1875
1885
  # Provides visibility into recent changes of each object, including deletion
1876
1886
  def get_versions(organization, incoming={})
1877
1887
  HttpClient::Preconditions.assert_class('organization', organization, String)
@@ -7297,7 +7307,12 @@ module Io
7297
7307
 
7298
7308
  # Card represents the metadata about a secure, tokenized card. The card 'token'
7299
7309
  # is a unique, cryptographically secure token by which this card can be
7300
- # identified in the future.
7310
+ # identified in the future. The card token itself will either be a permanent
7311
+ # card token (denoted by a prefix of F96) or a one time nonce (denoted by a
7312
+ # prefix of F17). Nonces represent cards that were encrypted from public
7313
+ # channels (like the user's browser via JavaScript) and can be used once only.
7314
+ # If you have a nonce you can exchange it for a permanent card token via the
7315
+ # operation POST /:organization/cards/nonces
7301
7316
  class Card
7302
7317
 
7303
7318
  attr_reader :id, :token, :type, :expiration, :last4, :name, :address
@@ -7411,6 +7426,34 @@ module Io
7411
7426
 
7412
7427
  end
7413
7428
 
7429
+ # The card nonce form presents a one time token to exchance server side for a
7430
+ # permanent, secure tokenized card
7431
+ class CardNonceForm
7432
+
7433
+ attr_reader :token
7434
+
7435
+ def initialize(incoming={})
7436
+ opts = HttpClient::Helper.symbolize_keys(incoming)
7437
+ HttpClient::Preconditions.require_keys(opts, [:token], 'CardNonceForm')
7438
+ @token = HttpClient::Preconditions.assert_class('token', opts.delete(:token), String)
7439
+ end
7440
+
7441
+ def to_json
7442
+ JSON.dump(to_hash)
7443
+ end
7444
+
7445
+ def copy(incoming={})
7446
+ CardNonceForm.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
7447
+ end
7448
+
7449
+ def to_hash
7450
+ {
7451
+ :token => token
7452
+ }
7453
+ end
7454
+
7455
+ end
7456
+
7414
7457
  class CardReference
7415
7458
 
7416
7459
  attr_reader :id, :token
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.62
4
+ version: 0.0.63
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-09-23 00:00:00.000000000 Z
11
+ date: 2016-09-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json