balanced 1.0.beta1 → 1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -0
  3. data/.ruby-version +1 -1
  4. data/LICENSE +2 -2
  5. data/balanced.gemspec +1 -1
  6. data/lib/balanced/resources.rb +1 -0
  7. data/lib/balanced/resources/customer.rb +0 -14
  8. data/lib/balanced/resources/dispute.rb +12 -0
  9. data/lib/balanced/version.rb +1 -1
  10. data/scenario.cache +142 -141
  11. data/scenarios/api_key_create/ruby.mako +6 -6
  12. data/scenarios/api_key_delete/ruby.mako +2 -2
  13. data/scenarios/api_key_list/ruby.mako +10 -10
  14. data/scenarios/api_key_show/ruby.mako +6 -6
  15. data/scenarios/bank_account_associate_to_customer/ruby.mako +13 -13
  16. data/scenarios/bank_account_create/ruby.mako +13 -13
  17. data/scenarios/bank_account_credit/ruby.mako +15 -15
  18. data/scenarios/bank_account_debit/ruby.mako +15 -15
  19. data/scenarios/bank_account_delete/ruby.mako +2 -2
  20. data/scenarios/bank_account_list/ruby.mako +22 -22
  21. data/scenarios/bank_account_show/ruby.mako +12 -12
  22. data/scenarios/bank_account_update/ruby.mako +12 -12
  23. data/scenarios/bank_account_verification_create/ruby.mako +9 -9
  24. data/scenarios/bank_account_verification_show/ruby.mako +9 -9
  25. data/scenarios/bank_account_verification_update/ruby.mako +9 -9
  26. data/scenarios/callback_create/ruby.mako +5 -4
  27. data/scenarios/callback_delete/ruby.mako +2 -2
  28. data/scenarios/callback_list/ruby.mako +4 -4
  29. data/scenarios/callback_show/ruby.mako +5 -5
  30. data/scenarios/card_associate_to_customer/ruby.mako +15 -15
  31. data/scenarios/card_create/ruby.mako +14 -14
  32. data/scenarios/card_debit/ruby.mako +16 -16
  33. data/scenarios/card_delete/ruby.mako +2 -2
  34. data/scenarios/card_hold_capture/ruby.mako +16 -16
  35. data/scenarios/card_hold_create/ruby.mako +16 -14
  36. data/scenarios/card_hold_list/ruby.mako +29 -25
  37. data/scenarios/card_hold_show/ruby.mako +16 -14
  38. data/scenarios/card_hold_update/ruby.mako +16 -14
  39. data/scenarios/card_hold_void/ruby.mako +16 -14
  40. data/scenarios/card_list/ruby.mako +24 -24
  41. data/scenarios/card_show/ruby.mako +13 -13
  42. data/scenarios/card_update/ruby.mako +13 -13
  43. data/scenarios/credit_list/ruby.mako +14 -14
  44. data/scenarios/credit_list_bank_account/ruby.mako +2 -2
  45. data/scenarios/credit_show/ruby.mako +15 -15
  46. data/scenarios/credit_update/ruby.mako +15 -15
  47. data/scenarios/customer_create/ruby.mako +19 -17
  48. data/scenarios/customer_delete/ruby.mako +1 -1
  49. data/scenarios/customer_list/ruby.mako +37 -33
  50. data/scenarios/customer_show/ruby.mako +20 -18
  51. data/scenarios/customer_update/ruby.mako +20 -18
  52. data/scenarios/debit_list/ruby.mako +28 -28
  53. data/scenarios/debit_show/ruby.mako +15 -15
  54. data/scenarios/debit_update/ruby.mako +15 -15
  55. data/scenarios/event_list/ruby.mako +67 -20
  56. data/scenarios/event_show/ruby.mako +23 -21
  57. data/scenarios/order_create/ruby.mako +14 -14
  58. data/scenarios/order_list/ruby.mako +13 -13
  59. data/scenarios/order_show/ruby.mako +14 -14
  60. data/scenarios/order_update/ruby.mako +14 -14
  61. data/scenarios/refund_create/ruby.mako +13 -13
  62. data/scenarios/refund_list/ruby.mako +12 -12
  63. data/scenarios/refund_show/ruby.mako +13 -13
  64. data/scenarios/refund_update/ruby.mako +13 -13
  65. data/scenarios/render_mako.rb +0 -1
  66. data/scenarios/reversal_create/ruby.mako +12 -12
  67. data/scenarios/reversal_list/ruby.mako +11 -11
  68. data/scenarios/reversal_show/ruby.mako +12 -12
  69. data/scenarios/reversal_update/ruby.mako +12 -12
  70. data/spec/balanced/resources/bank_account_spec.rb +0 -3
  71. data/spec/balanced/resources/debit_spec.rb +0 -13
  72. data/spec/balanced/resources/dispute_spec.rb +65 -0
  73. metadata +20 -18
  74. data/.rbenv-version +0 -1
@@ -3,9 +3,9 @@ Balanced::BankAccount.save
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- bank_account = Balanced::BankAccount.fetch('/bank_accounts/BA1QFf0LmIxr8p41msqX46Oy')
8
+ bank_account = Balanced::BankAccount.fetch('/bank_accounts/BA58WYAEUMrEtAkW5KAvWo5V')
9
9
  bank_account.meta = {
10
10
  'facebook.user_id' => '0192837465',
11
11
  'my-own-customer-id' => '12345',
@@ -14,7 +14,7 @@ bank_account.meta = {
14
14
  bank_account.save
15
15
 
16
16
  % elif mode == 'response':
17
- #<Balanced::BankAccount:0x007fdc9c145520
17
+ #<Balanced::BankAccount:0x007ff2be1a93a8
18
18
  @attributes=
19
19
  {"account_number"=>"xxxxxx0001",
20
20
  "account_type"=>"checking",
@@ -28,11 +28,11 @@ bank_account.save
28
28
  "bank_name"=>"BANK OF AMERICA, N.A.",
29
29
  "can_credit"=>true,
30
30
  "can_debit"=>false,
31
- "created_at"=>"2014-01-27T22:56:20.540530Z",
31
+ "created_at"=>"2014-03-06T19:22:30.247406Z",
32
32
  "fingerprint"=>
33
33
  "5f0ba9fa3f1122ef13b944a40abfe44e7eba9e16934e64200913cb4c402ace14",
34
- "href"=>"/bank_accounts/BA1QFf0LmIxr8p41msqX46Oy",
35
- "id"=>"BA1QFf0LmIxr8p41msqX46Oy",
34
+ "href"=>"/bank_accounts/BA58WYAEUMrEtAkW5KAvWo5V",
35
+ "id"=>"BA58WYAEUMrEtAkW5KAvWo5V",
36
36
  "links"=>{"bank_account_verification"=>nil, "customer"=>nil},
37
37
  "meta"=>
38
38
  {"facebook.user_id"=>"0192837465",
@@ -40,17 +40,17 @@ bank_account.save
40
40
  "twitter.id"=>"1234987650"},
41
41
  "name"=>"Johann Bernoulli",
42
42
  "routing_number"=>"121000358",
43
- "updated_at"=>"2014-01-27T22:56:25.767386Z"},
43
+ "updated_at"=>"2014-03-06T19:22:33.744499Z"},
44
44
  @hyperlinks=
45
45
  {"bank_account_verification"=>
46
- #<Proc:0x007fdc9c144238/lib/balanced/utils.rb:6 (lambda)>,
46
+ #<Proc:0x007ff2bd88be10/lib/balanced/utils.rb:6 (lambda)>,
47
47
  "bank_account_verifications"=>
48
- #<Proc:0x007fdc9c131ef8/lib/balanced/utils.rb:6 (lambda)>,
48
+ #<Proc:0x007ff2bd8aa810/lib/balanced/utils.rb:6 (lambda)>,
49
49
  "credits"=>
50
- #<Proc:0x007fdc9c136e80/lib/balanced/utils.rb:6 (lambda)>,
50
+ #<Proc:0x007ff2bd8bb098/lib/balanced/utils.rb:6 (lambda)>,
51
51
  "customer"=>
52
- #<Proc:0x007fdc9c136200/lib/balanced/utils.rb:6 (lambda)>,
52
+ #<Proc:0x007ff2bd8b9ec8/lib/balanced/utils.rb:6 (lambda)>,
53
53
  "debits"=>
54
- #<Proc:0x007fdc9c14c140/lib/balanced/utils.rb:6 (lambda)>}>
54
+ #<Proc:0x007ff2bd8c1a38/lib/balanced/utils.rb:6 (lambda)>}>
55
55
 
56
56
  % endif
@@ -3,26 +3,26 @@
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- bank_account = Balanced::BankAccount.fetch('/bank_accounts/BA1D3vL3LjasB0kewMqRGI0S')
8
+ bank_account = Balanced::BankAccount.fetch('/bank_accounts/BA50LpPrCTB63Ecm0wEgdOQM')
9
9
  verification = bank_account.verify
10
10
 
11
11
  % elif mode == 'response':
12
- #<Balanced::BankAccountVerification:0x007fdc9c181480
12
+ #<Balanced::BankAccountVerification:0x007ff2bd9290e8
13
13
  @attributes=
14
14
  {"attempts"=>0,
15
15
  "attempts_remaining"=>3,
16
- "created_at"=>"2014-01-27T22:56:10.726455Z",
16
+ "created_at"=>"2014-03-06T19:22:24.651572Z",
17
17
  "deposit_status"=>"succeeded",
18
- "href"=>"/verifications/BZ1FF2MHFH9upRu7C0QUwnby",
19
- "id"=>"BZ1FF2MHFH9upRu7C0QUwnby",
20
- "links"=>{"bank_account"=>"BA1D3vL3LjasB0kewMqRGI0S"},
18
+ "href"=>"/verifications/BZ5alC0fajkuBOvOU7lVT7QJ",
19
+ "id"=>"BZ5alC0fajkuBOvOU7lVT7QJ",
20
+ "links"=>{"bank_account"=>"BA50LpPrCTB63Ecm0wEgdOQM"},
21
21
  "meta"=>{},
22
- "updated_at"=>"2014-01-27T22:56:12.545750Z",
22
+ "updated_at"=>"2014-03-06T19:22:25.233126Z",
23
23
  "verification_status"=>"pending"},
24
24
  @hyperlinks=
25
25
  {"bank_account"=>
26
- #<Proc:0x007fdc9c18b2f0/lib/balanced/resources/resource.rb:60 (lambda)>}>
26
+ #<Proc:0x007ff2bc8a70d0/lib/balanced/resources/resource.rb:60 (lambda)>}>
27
27
 
28
28
  % endif
@@ -3,25 +3,25 @@ Balanced::Verification.fetch
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- verification = Balanced::Verification.fetch('/verifications/BZ1FF2MHFH9upRu7C0QUwnby')
8
+ verification = Balanced::Verification.fetch('/verifications/BZ5alC0fajkuBOvOU7lVT7QJ')
9
9
 
10
10
  % elif mode == 'response':
11
- #<Balanced::BankAccountVerification:0x007fdc9c1989c8
11
+ #<Balanced::BankAccountVerification:0x007ff2bd93a6b8
12
12
  @attributes=
13
13
  {"attempts"=>0,
14
14
  "attempts_remaining"=>3,
15
- "created_at"=>"2014-01-27T22:56:10.726455Z",
15
+ "created_at"=>"2014-03-06T19:22:24.651572Z",
16
16
  "deposit_status"=>"succeeded",
17
- "href"=>"/verifications/BZ1FF2MHFH9upRu7C0QUwnby",
18
- "id"=>"BZ1FF2MHFH9upRu7C0QUwnby",
19
- "links"=>{"bank_account"=>"BA1D3vL3LjasB0kewMqRGI0S"},
17
+ "href"=>"/verifications/BZ5alC0fajkuBOvOU7lVT7QJ",
18
+ "id"=>"BZ5alC0fajkuBOvOU7lVT7QJ",
19
+ "links"=>{"bank_account"=>"BA50LpPrCTB63Ecm0wEgdOQM"},
20
20
  "meta"=>{},
21
- "updated_at"=>"2014-01-27T22:56:12.545750Z",
21
+ "updated_at"=>"2014-03-06T19:22:25.233126Z",
22
22
  "verification_status"=>"pending"},
23
23
  @hyperlinks=
24
24
  {"bank_account"=>
25
- #<Proc:0x007fdc9c1a2b58/lib/balanced/resources/resource.rb:60 (lambda)>}>
25
+ #<Proc:0x007ff2bd942250/lib/balanced/resources/resource.rb:60 (lambda)>}>
26
26
 
27
27
  % endif
@@ -3,9 +3,9 @@ Balanced::Verification.confirm
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- verification = Balanced::Verification.fetch('/verifications/BZ1FF2MHFH9upRu7C0QUwnby')
8
+ verification = Balanced::Verification.fetch('/verifications/BZ5alC0fajkuBOvOU7lVT7QJ')
9
9
  verification.confirm(
10
10
  amount_1 = 1,
11
11
  amount_2 = 1
@@ -13,20 +13,20 @@ verification.confirm(
13
13
 
14
14
 
15
15
  % elif mode == 'response':
16
- #<Balanced::BankAccountVerification:0x007fdc9c1b85c0
16
+ #<Balanced::BankAccountVerification:0x007ff2bd958938
17
17
  @attributes=
18
18
  {"attempts"=>1,
19
19
  "attempts_remaining"=>2,
20
- "created_at"=>"2014-01-27T22:56:10.726455Z",
20
+ "created_at"=>"2014-03-06T19:22:24.651572Z",
21
21
  "deposit_status"=>"succeeded",
22
- "href"=>"/verifications/BZ1FF2MHFH9upRu7C0QUwnby",
23
- "id"=>"BZ1FF2MHFH9upRu7C0QUwnby",
24
- "links"=>{"bank_account"=>"BA1D3vL3LjasB0kewMqRGI0S"},
22
+ "href"=>"/verifications/BZ5alC0fajkuBOvOU7lVT7QJ",
23
+ "id"=>"BZ5alC0fajkuBOvOU7lVT7QJ",
24
+ "links"=>{"bank_account"=>"BA50LpPrCTB63Ecm0wEgdOQM"},
25
25
  "meta"=>{},
26
- "updated_at"=>"2014-01-27T22:56:18.631337Z",
26
+ "updated_at"=>"2014-03-06T19:22:27.893114Z",
27
27
  "verification_status"=>"succeeded"},
28
28
  @hyperlinks=
29
29
  {"bank_account"=>
30
- #<Proc:0x007fdc9c1c2750/lib/balanced/resources/resource.rb:60 (lambda)>}>
30
+ #<Proc:0x007ff2bd95a260/lib/balanced/resources/resource.rb:60 (lambda)>}>
31
31
 
32
32
  % endif
@@ -2,17 +2,18 @@
2
2
  Balanced::Callback.new
3
3
  % elif mode == 'request':
4
4
  require 'balanced'
5
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
5
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
6
6
 
7
7
  callback = Balanced::Callback.new(
8
+ :method => 'post',
8
9
  :url => 'http://www.example.com/callback'
9
10
  ).save
10
11
 
11
12
  % elif mode == 'response':
12
- #<Balanced::Callback:0x007fdc9c1dbb38
13
+ #<Balanced::Callback:0x007ff2bd972b08
13
14
  @attributes=
14
- {"href"=>"/callbacks/CB224374R2NSyoYBpDV4r7C2",
15
- "id"=>"CB224374R2NSyoYBpDV4r7C2",
15
+ {"href"=>"/callbacks/CB5pnz4XnaDpRFGlNMb6u50R",
16
+ "id"=>"CB5pnz4XnaDpRFGlNMb6u50R",
16
17
  "links"=>{},
17
18
  "method"=>"post",
18
19
  "revision"=>"1.1",
@@ -3,9 +3,9 @@ Balanced::Callback.unstore
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- callback = Balanced::Callback.fetch('/callbacks/CB224374R2NSyoYBpDV4r7C2')
8
+ callback = Balanced::Callback.fetch('/callbacks/CB5pnz4XnaDpRFGlNMb6u50R')
9
9
  callback.unstore
10
10
  % elif mode == 'response':
11
11
 
@@ -3,14 +3,14 @@ Balanced::Callback.all
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
8
  callbacks = Balanced::Callback.all
9
9
  % elif mode == 'response':
10
- [#<Balanced::Callback:0x007fdc9c1eb308
10
+ [#<Balanced::Callback:0x007ff2bd9948e8
11
11
  @attributes=
12
- {"href"=>"/callbacks/CB224374R2NSyoYBpDV4r7C2",
13
- "id"=>"CB224374R2NSyoYBpDV4r7C2",
12
+ {"href"=>"/callbacks/CB5pnz4XnaDpRFGlNMb6u50R",
13
+ "id"=>"CB5pnz4XnaDpRFGlNMb6u50R",
14
14
  "links"=>{},
15
15
  "method"=>"post",
16
16
  "revision"=>"1.1",
@@ -3,14 +3,14 @@ Balanced::Callback.fetch
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- callback = Balanced::Callback.fetch('/callbacks/CB224374R2NSyoYBpDV4r7C2')
8
+ callback = Balanced::Callback.fetch('/callbacks/CB5pnz4XnaDpRFGlNMb6u50R')
9
9
  % elif mode == 'response':
10
- #<Balanced::Callback:0x007fdc9d10a618
10
+ #<Balanced::Callback:0x007ff2bd99d628
11
11
  @attributes=
12
- {"href"=>"/callbacks/CB224374R2NSyoYBpDV4r7C2",
13
- "id"=>"CB224374R2NSyoYBpDV4r7C2",
12
+ {"href"=>"/callbacks/CB5pnz4XnaDpRFGlNMb6u50R",
13
+ "id"=>"CB5pnz4XnaDpRFGlNMb6u50R",
14
14
  "links"=>{},
15
15
  "method"=>"post",
16
16
  "revision"=>"1.1",
@@ -3,13 +3,13 @@ Balanced::Customer.add_card
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- card = Balanced::Card.fetch('/cards/CC3kqm84fxh50avenrUsSKbu')
9
- card.associate_to_customer('/customers/CU3eeasZ9yQ86uzzIYZkrPGg')
8
+ card = Balanced::Card.fetch('/cards/CC68IoCVpoFlkugB7xt52p8C')
9
+ card.associate_to_customer('/customers/CU64R7DS6DwuXYVg9RTskFK8')
10
10
 
11
11
  % elif mode == 'response':
12
- #<Balanced::Card:0x007fdc9d1192d0
12
+ #<Balanced::Card:0x007ff2bd9b7190
13
13
  @attributes=
14
14
  {"address"=>
15
15
  {"city"=>nil,
@@ -22,28 +22,28 @@ card.associate_to_customer('/customers/CU3eeasZ9yQ86uzzIYZkrPGg')
22
22
  "avs_result"=>nil,
23
23
  "avs_street_match"=>nil,
24
24
  "brand"=>"MasterCard",
25
- "created_at"=>"2014-01-27T22:57:42.092923Z",
26
- "cvv"=>nil,
27
- "cvv_match"=>nil,
28
- "cvv_result"=>nil,
25
+ "created_at"=>"2014-03-06T19:23:25.159503Z",
26
+ "cvv"=>"xxx",
27
+ "cvv_match"=>"yes",
28
+ "cvv_result"=>"Match",
29
29
  "expiration_month"=>12,
30
30
  "expiration_year"=>2020,
31
31
  "fingerprint"=>
32
32
  "fc4ccd5de54f42a5e75f76fbfde60948440c7a382ee7d21b2bc509ab9cfed788",
33
- "href"=>"/cards/CC3kqm84fxh50avenrUsSKbu",
34
- "id"=>"CC3kqm84fxh50avenrUsSKbu",
33
+ "href"=>"/cards/CC68IoCVpoFlkugB7xt52p8C",
34
+ "id"=>"CC68IoCVpoFlkugB7xt52p8C",
35
35
  "is_verified"=>true,
36
- "links"=>{"customer"=>"CU3eeasZ9yQ86uzzIYZkrPGg"},
36
+ "links"=>{"customer"=>"CU64R7DS6DwuXYVg9RTskFK8"},
37
37
  "meta"=>{},
38
38
  "name"=>nil,
39
39
  "number"=>"xxxxxxxxxxxx5100",
40
- "updated_at"=>"2014-01-27T22:57:42.724392Z"},
40
+ "updated_at"=>"2014-03-06T19:23:25.633918Z"},
41
41
  @hyperlinks=
42
42
  {"card_holds"=>
43
- #<Proc:0x007fdc9d122880/lib/balanced/utils.rb:6 (lambda)>,
43
+ #<Proc:0x007ff2bc113940/lib/balanced/utils.rb:6 (lambda)>,
44
44
  "customer"=>
45
- #<Proc:0x007fdc9d120d50/lib/balanced/resources/resource.rb:60 (lambda)>,
45
+ #<Proc:0x007ff2bc111488/lib/balanced/resources/resource.rb:60 (lambda)>,
46
46
  "debits"=>
47
- #<Proc:0x007fdc9d12abc0/lib/balanced/utils.rb:6 (lambda)>}>
47
+ #<Proc:0x007ff2bc123408/lib/balanced/utils.rb:6 (lambda)>}>
48
48
 
49
49
  % endif
@@ -3,17 +3,17 @@ Balanced::Card.new
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
8
  card = Balanced::Card.new(
9
+ :cvv => '123',
9
10
  :expiration_month => '12',
10
11
  :expiration_year => '2020',
11
- :number => '5105105105105100',
12
- :security_code => '123'
12
+ :number => '5105105105105100'
13
13
  ).save
14
14
 
15
15
  % elif mode == 'response':
16
- #<Balanced::Card:0x007fdc9d1527d8
16
+ #<Balanced::Card:0x007ff2bd9dc800
17
17
  @attributes=
18
18
  {"address"=>
19
19
  {"city"=>nil,
@@ -26,28 +26,28 @@ card = Balanced::Card.new(
26
26
  "avs_result"=>nil,
27
27
  "avs_street_match"=>nil,
28
28
  "brand"=>"MasterCard",
29
- "created_at"=>"2014-01-27T22:57:42.092923Z",
30
- "cvv"=>nil,
31
- "cvv_match"=>nil,
32
- "cvv_result"=>nil,
29
+ "created_at"=>"2014-03-06T19:23:25.159503Z",
30
+ "cvv"=>"xxx",
31
+ "cvv_match"=>"yes",
32
+ "cvv_result"=>"Match",
33
33
  "expiration_month"=>12,
34
34
  "expiration_year"=>2020,
35
35
  "fingerprint"=>
36
36
  "fc4ccd5de54f42a5e75f76fbfde60948440c7a382ee7d21b2bc509ab9cfed788",
37
- "href"=>"/cards/CC3kqm84fxh50avenrUsSKbu",
38
- "id"=>"CC3kqm84fxh50avenrUsSKbu",
37
+ "href"=>"/cards/CC68IoCVpoFlkugB7xt52p8C",
38
+ "id"=>"CC68IoCVpoFlkugB7xt52p8C",
39
39
  "is_verified"=>true,
40
40
  "links"=>{"customer"=>nil},
41
41
  "meta"=>{},
42
42
  "name"=>nil,
43
43
  "number"=>"xxxxxxxxxxxx5100",
44
- "updated_at"=>"2014-01-27T22:57:42.092926Z"},
44
+ "updated_at"=>"2014-03-06T19:23:25.159506Z"},
45
45
  @hyperlinks=
46
46
  {"card_holds"=>
47
- #<Proc:0x007fdc9d15b630/lib/balanced/utils.rb:6 (lambda)>,
47
+ #<Proc:0x007ff2bc8ad0e8/lib/balanced/utils.rb:6 (lambda)>,
48
48
  "customer"=>
49
- #<Proc:0x007fdc9d15a910/lib/balanced/utils.rb:6 (lambda)>,
49
+ #<Proc:0x007ff2bc12a550/lib/balanced/utils.rb:6 (lambda)>,
50
50
  "debits"=>
51
- #<Proc:0x007fdc9d158138/lib/balanced/utils.rb:6 (lambda)>}>
51
+ #<Proc:0x007ff2bd9febf8/lib/balanced/utils.rb:6 (lambda)>}>
52
52
 
53
53
  % endif
@@ -2,9 +2,9 @@
2
2
  Balanced::Card.debit
3
3
  % elif mode == 'request':
4
4
  require 'balanced'
5
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
5
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
6
6
 
7
- card = Balanced::Card.fetch('/cards/CC3kqm84fxh50avenrUsSKbu')
7
+ card = Balanced::Card.fetch('/cards/CC68IoCVpoFlkugB7xt52p8C')
8
8
  card.debit(
9
9
  :amount => 5000,
10
10
  :appears_on_statement_as => 'Statement text',
@@ -12,38 +12,38 @@ card.debit(
12
12
  )
13
13
 
14
14
  % elif mode == 'response':
15
- #<Balanced::Debit:0x007fdc9d180340
15
+ #<Balanced::Debit:0x007ff2bda14cf0
16
16
  @attributes=
17
17
  {"amount"=>5000,
18
18
  "appears_on_statement_as"=>"BAL*Statement text",
19
- "created_at"=>"2014-01-27T22:58:07.291226Z",
19
+ "created_at"=>"2014-03-06T19:23:44.148512Z",
20
20
  "currency"=>"USD",
21
21
  "description"=>"Some descriptive text for the debit in the dashboard",
22
22
  "failure_reason"=>nil,
23
23
  "failure_reason_code"=>nil,
24
- "href"=>"/debits/WD3MKNxNTKBGgA7mX50yogiu",
25
- "id"=>"WD3MKNxNTKBGgA7mX50yogiu",
24
+ "href"=>"/debits/WD6BKYhbRzlRhfKSE1DcpqS5",
25
+ "id"=>"WD6BKYhbRzlRhfKSE1DcpqS5",
26
26
  "links"=>
27
- {"customer"=>"CU3eeasZ9yQ86uzzIYZkrPGg",
27
+ {"customer"=>"CU64R7DS6DwuXYVg9RTskFK8",
28
28
  "dispute"=>nil,
29
29
  "order"=>nil,
30
- "source"=>"CC3kqm84fxh50avenrUsSKbu"},
30
+ "source"=>"CC68IoCVpoFlkugB7xt52p8C"},
31
31
  "meta"=>{},
32
32
  "status"=>"succeeded",
33
- "transaction_number"=>"W180-465-2000",
34
- "updated_at"=>"2014-01-27T22:58:09.706862Z"},
33
+ "transaction_number"=>"W274-713-3734",
34
+ "updated_at"=>"2014-03-06T19:23:45.554127Z"},
35
35
  @hyperlinks=
36
36
  {"customer"=>
37
- #<Proc:0x007fdc9d18a4a8/lib/balanced/resources/resource.rb:60 (lambda)>,
37
+ #<Proc:0x007ff2bda1e958/lib/balanced/resources/resource.rb:60 (lambda)>,
38
38
  "dispute"=>
39
- #<Proc:0x007fdc9d189af8/lib/balanced/utils.rb:6 (lambda)>,
39
+ #<Proc:0x007ff2bda1de68/lib/balanced/utils.rb:6 (lambda)>,
40
40
  "events"=>
41
- #<Proc:0x007fdc9d193c10/lib/balanced/utils.rb:6 (lambda)>,
41
+ #<Proc:0x007ff2bc14b660/lib/balanced/utils.rb:6 (lambda)>,
42
42
  "order"=>
43
- #<Proc:0x007fdc9d193210/lib/balanced/utils.rb:6 (lambda)>,
43
+ #<Proc:0x007ff2bc1495e0/lib/balanced/utils.rb:6 (lambda)>,
44
44
  "refunds"=>
45
- #<Proc:0x007fdc9d191398/lib/balanced/utils.rb:6 (lambda)>,
45
+ #<Proc:0x007ff2bc1528e8/lib/balanced/utils.rb:6 (lambda)>,
46
46
  "source"=>
47
- #<Proc:0x007fdc9d19b988/lib/balanced/resources/resource.rb:60 (lambda)>}>
47
+ #<Proc:0x007ff2bc150b38/lib/balanced/resources/resource.rb:60 (lambda)>}>
48
48
 
49
49
  % endif
@@ -3,9 +3,9 @@ Balanced::Card.unstore
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- card = Balanced::Card.fetch('/cards/CC2uc8iPDjgyxOXHVtnZloyI')
8
+ card = Balanced::Card.fetch('/cards/CC5Buki6e4Kg4bDVZ3OSfQ8O')
9
9
  card.unstore
10
10
 
11
11
  % elif mode == 'response':
@@ -3,47 +3,47 @@ Balanced::CardHold.capture
3
3
 
4
4
  % elif mode == 'request':
5
5
  require 'balanced'
6
- Balanced.configure('ak-test-1kvvievk0Qqw5wQPsrlM9g7wQwNe62cyc')
6
+ Balanced.configure('ak-test-2ADpvITfpgBn8uBzEGsQ2bIgWaftUWiul')
7
7
 
8
- card_hold = Balanced::CardHold.fetch('/card_holds/HL2bT9uMRkTZkfSPmA2pBD9S')
8
+ card_hold = Balanced::CardHold.fetch('/card_holds/HL5wAfv8JaMsEn9idXrLZZZT')
9
9
  debit = card_hold.capture(
10
10
  :appears_on_statement_as => 'ShowsUpOnStmt',
11
11
  :description => 'Some descriptive text for the debit in the dashboard'
12
12
  )
13
13
 
14
14
  % elif mode == 'response':
15
- #<Balanced::Debit:0x007fdc9d1ba0e0
15
+ #<Balanced::Debit:0x007ff2bdaa68f8
16
16
  @attributes=
17
17
  {"amount"=>5000,
18
18
  "appears_on_statement_as"=>"BAL*ShowsUpOnStmt",
19
- "created_at"=>"2014-01-27T22:56:45.623268Z",
19
+ "created_at"=>"2014-03-06T19:22:49.584629Z",
20
20
  "currency"=>"USD",
21
21
  "description"=>"Some descriptive text for the debit in the dashboard",
22
22
  "failure_reason"=>nil,
23
23
  "failure_reason_code"=>nil,
24
- "href"=>"/debits/WD2iSCukjXyeRdkvX3cW0PmC",
25
- "id"=>"WD2iSCukjXyeRdkvX3cW0PmC",
24
+ "href"=>"/debits/WD5Co9XwRZJg1QtvC5QeekhX",
25
+ "id"=>"WD5Co9XwRZJg1QtvC5QeekhX",
26
26
  "links"=>
27
- {"customer"=>"CU1f8Ygc4t0F2FKNcw235x9I",
27
+ {"customer"=>"CU4Wt8xSbREzV2NWtdVAFGeR",
28
28
  "dispute"=>nil,
29
29
  "order"=>nil,
30
- "source"=>"CC2abDOQVm5aNFhHpcRvWS02"},
30
+ "source"=>"CC5nCSU0yFp3qxR4p6UZST7y"},
31
31
  "meta"=>{"holding.for"=>"user1", "meaningful.key"=>"some.value"},
32
32
  "status"=>"succeeded",
33
- "transaction_number"=>"W744-719-1832",
34
- "updated_at"=>"2014-01-27T22:56:47.926021Z"},
33
+ "transaction_number"=>"W493-697-4873",
34
+ "updated_at"=>"2014-03-06T19:22:50.608819Z"},
35
35
  @hyperlinks=
36
36
  {"customer"=>
37
- #<Proc:0x007fdc9d1b8268/lib/balanced/resources/resource.rb:60 (lambda)>,
37
+ #<Proc:0x007ff2bdaa40d0/lib/balanced/resources/resource.rb:60 (lambda)>,
38
38
  "dispute"=>
39
- #<Proc:0x007fdc9d1c3848/lib/balanced/utils.rb:6 (lambda)>,
39
+ #<Proc:0x007ff2bdaaf5c0/lib/balanced/utils.rb:6 (lambda)>,
40
40
  "events"=>
41
- #<Proc:0x007fdc9d1c19d0/lib/balanced/utils.rb:6 (lambda)>,
41
+ #<Proc:0x007ff2bdaad400/lib/balanced/utils.rb:6 (lambda)>,
42
42
  "order"=>
43
- #<Proc:0x007fdc9d1c0fd0/lib/balanced/utils.rb:6 (lambda)>,
43
+ #<Proc:0x007ff2bdaac730/lib/balanced/utils.rb:6 (lambda)>,
44
44
  "refunds"=>
45
- #<Proc:0x007fdc9d1cb0e8/lib/balanced/utils.rb:6 (lambda)>,
45
+ #<Proc:0x007ff2bdab4f98/lib/balanced/utils.rb:6 (lambda)>,
46
46
  "source"=>
47
- #<Proc:0x007fdc9d1c9748/lib/balanced/resources/resource.rb:60 (lambda)>}>
47
+ #<Proc:0x007ff2bdabd9e0/lib/balanced/resources/resource.rb:60 (lambda)>}>
48
48
 
49
49
  % endif