fat_zebra 3.2.0 → 3.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -0
  3. data/README.md +2 -2
  4. data/fat_zebra.gemspec +1 -1
  5. data/lib/fat_zebra.rb +1 -1
  6. data/lib/fat_zebra/authenticate.rb +64 -0
  7. data/lib/fat_zebra/version.rb +1 -1
  8. data/spec/cassettes/FatZebra_Authenticate/_authenticate/validations/1_3_4_1.yml +46 -0
  9. data/spec/cassettes/FatZebra_Authenticate/_authenticate/with_challenge_response/1_3_3_1.yml +91 -0
  10. data/spec/cassettes/FatZebra_Authenticate/_authenticate/with_challenge_response/1_3_3_2.yml +91 -0
  11. data/spec/cassettes/FatZebra_Authenticate/_authenticate/with_frictionless_response/1_3_2_1.yml +91 -0
  12. data/spec/cassettes/FatZebra_Authenticate/_authenticate/with_frictionless_response/1_3_2_2.yml +91 -0
  13. data/spec/cassettes/FatZebra_Authenticate/_authenticate/with_invalid_input/1_3_1_1.yml +91 -0
  14. data/spec/cassettes/FatZebra_Authenticate/_authenticate/with_invalid_input/1_3_1_2.yml +87 -0
  15. data/spec/cassettes/FatZebra_Authenticate/_authenticate/with_invalid_input/1_3_1_3.yml +92 -0
  16. data/spec/cassettes/FatZebra_Authenticate/_authenticate/with_invalid_input/1_3_1_4.yml +92 -0
  17. data/spec/cassettes/FatZebra_Authenticate/_decode_session/when_token_is_invalid/returns_error_when_invalid_token.yml +47 -0
  18. data/spec/cassettes/FatZebra_Authenticate/_decode_session/when_token_is_valid/decodes_JWT.yml +87 -0
  19. data/spec/cassettes/FatZebra_Authenticate/_session/returns_JWT_with_given_params.yml +44 -0
  20. data/spec/cassettes/{FatZebra_Authorise/_jwt_token → FatZebra_Authenticate/_session}/returns_JWT_with_no_params.yml +8 -10
  21. data/spec/cassettes/FatZebra_Authenticate/_session/returns_JWT_with_some_params.yml +44 -0
  22. data/spec/cassettes/FatZebra_Authenticate/_session/returns_error_when_amount_is_invalid.yml +44 -0
  23. data/spec/lib/fat_zebra/authenticate_spec.rb +144 -0
  24. data/spec/spec_helper.rb +1 -1
  25. data/spec/support/payloads.rb +36 -31
  26. metadata +21 -15
  27. data/lib/fat_zebra/authorise.rb +0 -49
  28. data/spec/cassettes/FatZebra_Authorise/_authorise/with_challenge_response/1_2_3_1.yml +0 -48
  29. data/spec/cassettes/FatZebra_Authorise/_authorise/with_challenge_response/1_2_3_2.yml +0 -48
  30. data/spec/cassettes/FatZebra_Authorise/_authorise/with_frictionless_response/1_2_2_1.yml +0 -48
  31. data/spec/cassettes/FatZebra_Authorise/_authorise/with_frictionless_response/1_2_2_2.yml +0 -48
  32. data/spec/cassettes/FatZebra_Authorise/_authorise/with_invalid_input/1_2_1_1.yml +0 -50
  33. data/spec/cassettes/FatZebra_Authorise/_jwt_token/returns_JWT_with_given_params.yml +0 -46
  34. data/spec/cassettes/FatZebra_Authorise/_jwt_token/returns_JWT_with_some_params.yml +0 -46
  35. data/spec/lib/fat_zebra/authorise_spec.rb +0 -101
@@ -1,6 +1,6 @@
1
1
  require 'rubygems'
2
2
  require 'bundler/setup'
3
- require 'pry'
3
+ require 'byebug'
4
4
  require 'rspec'
5
5
  require 'vcr'
6
6
  require 'webmock/rspec'
@@ -40,45 +40,50 @@ shared_context 'payloads' do
40
40
  }
41
41
  }}
42
42
 
43
- let(:valid_3ds_authorise_payload) {{
44
- card_number: '5123456789012346',
45
- card_expiry: DateTime.now.next_year.strftime('%m/%Y'),
46
- threeds: {
43
+ let(:valid_sca_authenticate_payload) {{
44
+ card_token: credit_card.token,
45
+ sca: {
47
46
  enabled: true,
48
47
  amount: 100,
49
- billing_address1: 'SOME ADDRESS',
50
- billing_city: 'Sydney',
51
- billing_country_code: '036', # Australia
52
- billing_first_name: 'John',
53
- billing_last_name: 'Smith',
54
- billing_postal_code: '2000',
55
- billing_state: 'NSW',
56
- currency_code: '036',
48
+ currency: 'AUD',
57
49
  df_reference_id: SecureRandom.hex(10),
58
50
  mobile_phone: '1234567890',
59
51
  email: 'dev@fatzebra.com.au',
60
52
  transaction_mode: 'mobile',
61
53
  transaction_type: 'C',
62
54
  order_number: SecureRandom.hex(10),
63
-
64
- shipping_address1: 'SOME ADDRESS',
65
- shipping_state: 'NSW',
66
- shipping_city: 'Sydney',
67
- shipping_country_code: '036',
68
- shipping_address2: 'SOME ADDRESS',
69
- shipping_address3: 'SOME ADDRESS',
70
- shipping_postal_code: '2000',
71
- billing_phone: '1234567890',
72
- work_phone: '1234567890',
73
- billing_address2: 'SOME ADDRESS',
74
- billing_address3: 'SOME ADDRESS',
75
- authentication_indicator: '01',
76
- product_code: 'PHY',
77
-
78
- installment: 2,
79
- purchase_date: DateTime.now.next_year.strftime('%Y%m%d%H%M%S'),
80
- recurring_end: DateTime.now.next_year.strftime('%Y%m%d'),
81
- recurring_frequency: 31
55
+ billing: {
56
+ address1: 'SOME ADDRESS',
57
+ city: 'Sydney',
58
+ country: 'AUS',
59
+ first_name: 'John',
60
+ last_name: 'Smith',
61
+ postal_code: '2000',
62
+ state: 'NSW'
63
+ },
64
+ shipping: {
65
+ address1: 'SOME ADDRESS',
66
+ state: 'NSW',
67
+ city: 'Sydney',
68
+ country: 'AUS',
69
+ address2: 'SOME ADDRESS',
70
+ address3: 'SOME ADDRESS',
71
+ postal_code: '2000',
72
+ },
73
+ extra: {
74
+ billing_phone: '1234567890',
75
+ work_phone: '1234567890',
76
+ billing_address2: 'SOME ADDRESS',
77
+ billing_address3: 'SOME ADDRESS',
78
+ authentication_indicator: '01',
79
+ product_code: 'PHY'
80
+ },
81
+ recurring: {
82
+ installment: 2,
83
+ purchase_date: DateTime.now.next_year.strftime('%Y%m%d%H%M%S'),
84
+ recurring_end: DateTime.now.next_year.strftime('%Y%m%d'),
85
+ recurring_frequency: 31
86
+ }
82
87
  }
83
88
  }}
84
89
 
metadata CHANGED
@@ -1,17 +1,17 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fat_zebra
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.0
4
+ version: 3.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthew Savage
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-02 00:00:00.000000000 Z
11
+ date: 2019-11-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: pry
14
+ name: byebug
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - ">="
@@ -118,7 +118,7 @@ files:
118
118
  - lib/fat_zebra/api_operation/search.rb
119
119
  - lib/fat_zebra/api_operation/void.rb
120
120
  - lib/fat_zebra/api_resource.rb
121
- - lib/fat_zebra/authorise.rb
121
+ - lib/fat_zebra/authenticate.rb
122
122
  - lib/fat_zebra/bank_account.rb
123
123
  - lib/fat_zebra/batch.rb
124
124
  - lib/fat_zebra/card.rb
@@ -143,14 +143,21 @@ files:
143
143
  - lib/fat_zebra/validation.rb
144
144
  - lib/fat_zebra/version.rb
145
145
  - lib/fat_zebra/web_hook.rb
146
- - spec/cassettes/FatZebra_Authorise/_authorise/with_challenge_response/1_2_3_1.yml
147
- - spec/cassettes/FatZebra_Authorise/_authorise/with_challenge_response/1_2_3_2.yml
148
- - spec/cassettes/FatZebra_Authorise/_authorise/with_frictionless_response/1_2_2_1.yml
149
- - spec/cassettes/FatZebra_Authorise/_authorise/with_frictionless_response/1_2_2_2.yml
150
- - spec/cassettes/FatZebra_Authorise/_authorise/with_invalid_input/1_2_1_1.yml
151
- - spec/cassettes/FatZebra_Authorise/_jwt_token/returns_JWT_with_given_params.yml
152
- - spec/cassettes/FatZebra_Authorise/_jwt_token/returns_JWT_with_no_params.yml
153
- - spec/cassettes/FatZebra_Authorise/_jwt_token/returns_JWT_with_some_params.yml
146
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/validations/1_3_4_1.yml
147
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/with_challenge_response/1_3_3_1.yml
148
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/with_challenge_response/1_3_3_2.yml
149
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/with_frictionless_response/1_3_2_1.yml
150
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/with_frictionless_response/1_3_2_2.yml
151
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/with_invalid_input/1_3_1_1.yml
152
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/with_invalid_input/1_3_1_2.yml
153
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/with_invalid_input/1_3_1_3.yml
154
+ - spec/cassettes/FatZebra_Authenticate/_authenticate/with_invalid_input/1_3_1_4.yml
155
+ - spec/cassettes/FatZebra_Authenticate/_decode_session/when_token_is_invalid/returns_error_when_invalid_token.yml
156
+ - spec/cassettes/FatZebra_Authenticate/_decode_session/when_token_is_valid/decodes_JWT.yml
157
+ - spec/cassettes/FatZebra_Authenticate/_session/returns_JWT_with_given_params.yml
158
+ - spec/cassettes/FatZebra_Authenticate/_session/returns_JWT_with_no_params.yml
159
+ - spec/cassettes/FatZebra_Authenticate/_session/returns_JWT_with_some_params.yml
160
+ - spec/cassettes/FatZebra_Authenticate/_session/returns_error_when_amount_is_invalid.yml
154
161
  - spec/cassettes/FatZebra_BankAccount/_create/1_1_1.yml
155
162
  - spec/cassettes/FatZebra_BankAccount/_create/1_1_2.yml
156
163
  - spec/cassettes/FatZebra_BankAccount/_search/1_2_1.yml
@@ -298,7 +305,7 @@ files:
298
305
  - spec/cassettes/FatZebra_WebHook/_update/1_3_2.yml
299
306
  - spec/fixtures/batch_test.csv
300
307
  - spec/lib/fat_zebra/api_resource_spec.rb
301
- - spec/lib/fat_zebra/authorise_spec.rb
308
+ - spec/lib/fat_zebra/authenticate_spec.rb
302
309
  - spec/lib/fat_zebra/bank_account_spec.rb
303
310
  - spec/lib/fat_zebra/batch_spec.rb
304
311
  - spec/lib/fat_zebra/card_spec.rb
@@ -336,8 +343,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
336
343
  - !ruby/object:Gem::Version
337
344
  version: '0'
338
345
  requirements: []
339
- rubyforge_project: fat_zebra
340
- rubygems_version: 2.7.6.2
346
+ rubygems_version: 3.0.6
341
347
  signing_key:
342
348
  specification_version: 4
343
349
  summary: Fat Zebra payments gem - integrate your ruby app with Fat Zebra
@@ -1,49 +0,0 @@
1
- module FatZebra
2
- ##
3
- # == FatZebra \Authorise
4
- #
5
- # Manage 3DS authorisation for the API
6
- #
7
- # * token
8
- # * authorise
9
- #
10
- class Authorise < APIResource
11
- @resource_name = 'authorise'
12
-
13
- validates :card_number, required: true, on: :authorise
14
- validates :card_expiry, required: true, on: :authorise
15
- validates :threeds, required: true, on: :authorise
16
-
17
- class << self
18
-
19
- ##
20
- # Returns a JWT token for the 3DS authorisation process
21
- #
22
- # @param [Hash] params
23
- # @param [Hash] options for the request, and configurations (Optional)
24
- #
25
- # @return [FatZebra::Authorise]
26
- def jwt_token(params = {}, options = {})
27
- valid!(params, :jwt_token) if respond_to?(:valid!)
28
-
29
- response = request(:get, "#{resource_path}/jwt_token", params, options)
30
- initialize_from(response)
31
- end
32
-
33
- ##
34
- # Creates a lookup request to 3DS server
35
- #
36
- # @param [Hash] params
37
- # @param [Hash] options for the request, and configurations (Optional)
38
- #
39
- # @return [FatZebra::Authorise]
40
- def authorise(params = {}, options = {})
41
- valid!(params, :authorise) if respond_to?(:valid!)
42
-
43
- response = request(:post, resource_path, params, options)
44
- initialize_from(response)
45
- end
46
- end
47
-
48
- end
49
- end
@@ -1,48 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: post
5
- uri: https://gateway.sandbox.fatzebra.com.au/v1.0/authorise
6
- body:
7
- encoding: UTF-8
8
- string: '{"card_number":"4111111111111111","card_expiry":"09/2020","threeds":{"enabled":true,"amount":100,"billing_address1":"SOME
9
- ADDRESS","billing_city":"Sydney","billing_country_code":"036","billing_first_name":"John","billing_last_name":"Smith","billing_postal_code":"2000","billing_state":"NSW","currency_code":"036","df_reference_id":"d11506cf96cdbb83badc","mobile_phone":"1234567890","email":"dev@fatzebra.com.au","transaction_mode":"mobile","transaction_type":"C","order_number":"118884994ef0db99f4f5","shipping_address1":"SOME
10
- ADDRESS","shipping_state":"NSW","shipping_city":"Sydney","shipping_country_code":"036","shipping_address2":"SOME
11
- ADDRESS","shipping_address3":"SOME ADDRESS","shipping_postal_code":"2000","billing_phone":"1234567890","work_phone":"1234567890","billing_address2":"SOME
12
- ADDRESS","billing_address3":"SOME ADDRESS","authentication_indicator":"01","product_code":"PHY","installment":2,"purchase_date":"20200902104008","recurring_end":"20200902","recurring_frequency":31},"test":true}'
13
- headers:
14
- Accept-Encoding:
15
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
- Accept:
17
- - application/json
18
- User-Agent:
19
- - Ruby
20
- Authorization:
21
- - Basic VEVTVDpURVNU
22
- Content-Type:
23
- - application/json
24
- response:
25
- status:
26
- code: 200
27
- message: OK
28
- headers:
29
- Cache-Control:
30
- - no-store
31
- Pragma:
32
- - no-cache
33
- Content-Type:
34
- - application/json; charset=utf-8
35
- X-Request-Version:
36
- - 1.21.8
37
- X-Request-Id:
38
- - 67d00e9d5db8ed66fbbb01dee8150f11
39
- X-Runtime:
40
- - '1.262001'
41
- Transfer-Encoding:
42
- - chunked
43
- body:
44
- encoding: UTF-8
45
- string: '{"successful":true,"response":{"ThreeDSVersion":"1.0.2","Enrolled":"Y","ErrorDesc":null,"ErrorNo":"0","EciFlag":"07","OrderId":"8000143411954523","TransactionId":"KJpHTe72N6ePm5HTxYk0","TransactionType":null,"SignatureVerification":null,"CardBrand":"VISA","CardBin":"411111","DSTransactionId":null,"RawACSUrl":"https://someacsurl.com","ACSUrl":"https://someacsurl.com","StepUpUrl":"https://somestepupurl.com","Cavv":null,"PAResStatus":null,"Payload":"551f6bb1db7ba013570c9d96a1aa","Xid":null,"ReasonCode":null,"ReasonDesc":null,"ChallengeRequired":null,"StatusReason":null,"ACSTransactionId":null,"ThreeDSServerTransactionId":null},"errors":null,"test":true}'
46
- http_version:
47
- recorded_at: Mon, 02 Sep 2019 00:40:09 GMT
48
- recorded_with: VCR 3.0.3
@@ -1,48 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: post
5
- uri: https://gateway.sandbox.fatzebra.com.au/v1.0/authorise
6
- body:
7
- encoding: UTF-8
8
- string: '{"card_number":"4111111111111111","card_expiry":"09/2020","threeds":{"enabled":true,"amount":100,"billing_address1":"SOME
9
- ADDRESS","billing_city":"Sydney","billing_country_code":"036","billing_first_name":"John","billing_last_name":"Smith","billing_postal_code":"2000","billing_state":"NSW","currency_code":"036","df_reference_id":"2bcec7c03322c1603ce0","mobile_phone":"1234567890","email":"dev@fatzebra.com.au","transaction_mode":"mobile","transaction_type":"C","order_number":"eb6932557e2500078ac1","shipping_address1":"SOME
10
- ADDRESS","shipping_state":"NSW","shipping_city":"Sydney","shipping_country_code":"036","shipping_address2":"SOME
11
- ADDRESS","shipping_address3":"SOME ADDRESS","shipping_postal_code":"2000","billing_phone":"1234567890","work_phone":"1234567890","billing_address2":"SOME
12
- ADDRESS","billing_address3":"SOME ADDRESS","authentication_indicator":"01","product_code":"PHY","installment":2,"purchase_date":"20200902104009","recurring_end":"20200902","recurring_frequency":31},"test":true}'
13
- headers:
14
- Accept-Encoding:
15
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
- Accept:
17
- - application/json
18
- User-Agent:
19
- - Ruby
20
- Authorization:
21
- - Basic VEVTVDpURVNU
22
- Content-Type:
23
- - application/json
24
- response:
25
- status:
26
- code: 200
27
- message: OK
28
- headers:
29
- Cache-Control:
30
- - no-store
31
- Pragma:
32
- - no-cache
33
- Content-Type:
34
- - application/json; charset=utf-8
35
- X-Request-Version:
36
- - 1.21.8
37
- X-Request-Id:
38
- - a31f46e23fa3e98ede0c58f789916eeb
39
- X-Runtime:
40
- - '1.011716'
41
- Transfer-Encoding:
42
- - chunked
43
- body:
44
- encoding: UTF-8
45
- string: '{"successful":true,"response":{"ThreeDSVersion":"1.0.2","Enrolled":"Y","ErrorDesc":null,"ErrorNo":"0","EciFlag":"07","OrderId":"8000087145309035","TransactionId":"p3gebCQ2vbqT7jKzquU0","TransactionType":null,"SignatureVerification":null,"CardBrand":"VISA","CardBin":"411111","DSTransactionId":null,"RawACSUrl":"https://someacsurl.com","ACSUrl":"https://someacsurl.com","StepUpUrl":"https://somestepupurl.com","Cavv":null,"PAResStatus":null,"Payload":"39b8551f6bb1db7ba013570c9d96a1aa","Xid":null,"ReasonCode":null,"ReasonDesc":null,"ChallengeRequired":null,"StatusReason":null,"ACSTransactionId":null,"ThreeDSServerTransactionId":null},"errors":null,"test":true}'
46
- http_version:
47
- recorded_at: Mon, 02 Sep 2019 00:40:10 GMT
48
- recorded_with: VCR 3.0.3
@@ -1,48 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: post
5
- uri: https://gateway.sandbox.fatzebra.com.au/v1.0/authorise
6
- body:
7
- encoding: UTF-8
8
- string: '{"card_number":"4000000000001000","card_expiry":"09/2020","threeds":{"enabled":true,"amount":100,"billing_address1":"SOME
9
- ADDRESS","billing_city":"Sydney","billing_country_code":"036","billing_first_name":"John","billing_last_name":"Smith","billing_postal_code":"2000","billing_state":"NSW","currency_code":"036","df_reference_id":"9b078159eefbc57e34fb","mobile_phone":"1234567890","email":"dev@fatzebra.com.au","transaction_mode":"mobile","transaction_type":"C","order_number":"c2123ed55ff5c2d9e024","shipping_address1":"SOME
10
- ADDRESS","shipping_state":"NSW","shipping_city":"Sydney","shipping_country_code":"036","shipping_address2":"SOME
11
- ADDRESS","shipping_address3":"SOME ADDRESS","shipping_postal_code":"2000","billing_phone":"1234567890","work_phone":"1234567890","billing_address2":"SOME
12
- ADDRESS","billing_address3":"SOME ADDRESS","authentication_indicator":"01","product_code":"PHY","installment":2,"purchase_date":"20200902104005","recurring_end":"20200902","recurring_frequency":31},"test":true}'
13
- headers:
14
- Accept-Encoding:
15
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
- Accept:
17
- - application/json
18
- User-Agent:
19
- - Ruby
20
- Authorization:
21
- - Basic VEVTVDpURVNU
22
- Content-Type:
23
- - application/json
24
- response:
25
- status:
26
- code: 200
27
- message: OK
28
- headers:
29
- Cache-Control:
30
- - no-store
31
- Pragma:
32
- - no-cache
33
- Content-Type:
34
- - application/json; charset=utf-8
35
- X-Request-Version:
36
- - 1.21.8
37
- X-Request-Id:
38
- - 57648875a0bcbe1d7d5fa04695234c31
39
- X-Runtime:
40
- - '1.365493'
41
- Transfer-Encoding:
42
- - chunked
43
- body:
44
- encoding: UTF-8
45
- string: '{"successful":true,"response":{"ThreeDSVersion":"1.0.2","Enrolled":"Y","ErrorDesc":null,"ErrorNo":"0","EciFlag":"07","OrderId":"8000785369280523","TransactionId":"3UFULPbYKAJtaKXx41S0","TransactionType":null,"SignatureVerification":null,"CardBrand":"VISA","CardBin":"400000","DSTransactionId":null,"RawACSUrl":null,"ACSUrl":null,"StepUpUrl":null,"Cavv":null,"PAResStatus":null,"Payload":null,"Xid":null,"ReasonCode":null,"ReasonDesc":null,"ChallengeRequired":null,"StatusReason":null,"ACSTransactionId":null,"ThreeDSServerTransactionId":null},"errors":null,"test":true}'
46
- http_version:
47
- recorded_at: Mon, 02 Sep 2019 00:40:07 GMT
48
- recorded_with: VCR 3.0.3
@@ -1,48 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: post
5
- uri: https://gateway.sandbox.fatzebra.com.au/v1.0/authorise
6
- body:
7
- encoding: UTF-8
8
- string: '{"card_number":"4000000000001000","card_expiry":"09/2020","threeds":{"enabled":true,"amount":100,"billing_address1":"SOME
9
- ADDRESS","billing_city":"Sydney","billing_country_code":"036","billing_first_name":"John","billing_last_name":"Smith","billing_postal_code":"2000","billing_state":"NSW","currency_code":"036","df_reference_id":"e65ac29e83de2dcb6fec","mobile_phone":"1234567890","email":"dev@fatzebra.com.au","transaction_mode":"mobile","transaction_type":"C","order_number":"0b6724482dfdf72a0dff","shipping_address1":"SOME
10
- ADDRESS","shipping_state":"NSW","shipping_city":"Sydney","shipping_country_code":"036","shipping_address2":"SOME
11
- ADDRESS","shipping_address3":"SOME ADDRESS","shipping_postal_code":"2000","billing_phone":"1234567890","work_phone":"1234567890","billing_address2":"SOME
12
- ADDRESS","billing_address3":"SOME ADDRESS","authentication_indicator":"01","product_code":"PHY","installment":2,"purchase_date":"20200902104007","recurring_end":"20200902","recurring_frequency":31},"test":true}'
13
- headers:
14
- Accept-Encoding:
15
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
- Accept:
17
- - application/json
18
- User-Agent:
19
- - Ruby
20
- Authorization:
21
- - Basic VEVTVDpURVNU
22
- Content-Type:
23
- - application/json
24
- response:
25
- status:
26
- code: 200
27
- message: OK
28
- headers:
29
- Cache-Control:
30
- - no-store
31
- Pragma:
32
- - no-cache
33
- Content-Type:
34
- - application/json; charset=utf-8
35
- X-Request-Version:
36
- - 1.21.8
37
- X-Request-Id:
38
- - 3e75bd7fc1cc1e64a5373a1909d64c10
39
- X-Runtime:
40
- - '1.313599'
41
- Transfer-Encoding:
42
- - chunked
43
- body:
44
- encoding: UTF-8
45
- string: '{"successful":true,"response":{"ThreeDSVersion":"1.0.2","Enrolled":"Y","ErrorDesc":null,"ErrorNo":"0","EciFlag":"07","OrderId":"8000886189302370","TransactionId":"SJjPCuSo1xgEQmxhWqz0","TransactionType":null,"SignatureVerification":null,"CardBrand":"VISA","CardBin":"400000","DSTransactionId":null,"RawACSUrl":null,"ACSUrl":null,"StepUpUrl":null,"Cavv":null,"PAResStatus":null,"Payload":null,"Xid":null,"ReasonCode":null,"ReasonDesc":null,"ChallengeRequired":null,"StatusReason":null,"ACSTransactionId":null,"ThreeDSServerTransactionId":null},"errors":null,"test":true}'
46
- http_version:
47
- recorded_at: Mon, 02 Sep 2019 00:40:08 GMT
48
- recorded_with: VCR 3.0.3
@@ -1,50 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: post
5
- uri: https://gateway.sandbox.fatzebra.com.au/v1.0/authorise
6
- body:
7
- encoding: UTF-8
8
- string: '{"card_number":"5123456789012346","card_expiry":"08/2019","threeds":{"enabled":true,"amount":100,"billing_address1":"SOME
9
- ADDRESS","billing_city":"Sydney","billing_country_code":"036","billing_first_name":"John","billing_last_name":"Smith","billing_postal_code":"2000","billing_state":"NSW","currency_code":"036","df_reference_id":"ae9c3a1e8a26f09c3312","mobile_phone":"1234567890","email":"dev@fatzebra.com.au","transaction_mode":"mobile","transaction_type":"C","order_number":"7515ae6a2fc575777efa","shipping_address1":"SOME
10
- ADDRESS","shipping_state":"NSW","shipping_city":"Sydney","shipping_country_code":"036","shipping_address2":"SOME
11
- ADDRESS","shipping_address3":"SOME ADDRESS","shipping_postal_code":"2000","billing_phone":"1234567890","work_phone":"1234567890","billing_address2":"SOME
12
- ADDRESS","billing_address3":"SOME ADDRESS","authentication_indicator":"01","product_code":"PHY","installment":2,"purchase_date":"20200902104004","recurring_end":"20200902","recurring_frequency":31},"test":true}'
13
- headers:
14
- Accept-Encoding:
15
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
- Accept:
17
- - application/json
18
- User-Agent:
19
- - Ruby
20
- Authorization:
21
- - Basic VEVTVDpURVNU
22
- Content-Type:
23
- - application/json
24
- response:
25
- status:
26
- code: 422
27
- message: Unprocessable Entity
28
- headers:
29
- Cache-Control:
30
- - no-store
31
- Pragma:
32
- - no-cache
33
- Content-Type:
34
- - application/json; charset=utf-8
35
- X-Request-Version:
36
- - 1.21.8
37
- X-Request-Id:
38
- - 38c5e6b4a7af7dc35fb8f6608ae52b4c
39
- X-Runtime:
40
- - '1.637937'
41
- Transfer-Encoding:
42
- - chunked
43
- body:
44
- encoding: UTF-8
45
- string: '{"successful":false,"response":{"ThreeDSVersion":"1.0.2","Enrolled":"U","ErrorDesc":"Error
46
- Validating Credit Card Expiration Information Passed (YYMM)","ErrorNo":"4000","EciFlag":"00","OrderId":"8010307730195369","TransactionId":"EBw7c1ZzTL50yr3JH7S0","TransactionType":null,"SignatureVerification":null,"CardBrand":"MASTERCARD","CardBin":"512345","DSTransactionId":null,"RawACSUrl":null,"ACSUrl":null,"StepUpUrl":null,"Cavv":null,"PAResStatus":null,"Payload":null,"Xid":null,"ReasonCode":null,"ReasonDesc":null,"ChallengeRequired":null,"StatusReason":null,"ACSTransactionId":null,"ThreeDSServerTransactionId":null},"errors":"Error
47
- Validating Credit Card Expiration Information Passed (YYMM)","test":true}'
48
- http_version:
49
- recorded_at: Mon, 02 Sep 2019 00:40:05 GMT
50
- recorded_with: VCR 3.0.3