mastercard_psp_payment 1.0.0 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE.txt +1 -1
- data/README.md +9 -9
- data/lib/mastercard_psp_payment/api/psp_payment_data_api.rb +4 -1
- data/lib/mastercard_psp_payment/models/address.rb +1 -1
- data/lib/mastercard_psp_payment/models/authentication_options.rb +1 -1
- data/lib/mastercard_psp_payment/models/card.rb +19 -8
- data/lib/mastercard_psp_payment/models/cryptogram.rb +1 -1
- data/lib/mastercard_psp_payment/models/payment_data.rb +1 -1
- data/lib/mastercard_psp_payment/models/tokenization.rb +1 -1
- data/lib/mastercard_psp_payment/version.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5c9e7bf04c39bd6f7a95228ec447c528f67aa9e9
|
4
|
+
data.tar.gz: 1a7cfbede76410a4911ca4d870c5364b611d0f87
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4f05c82a35e0973a2f59c21ed032071f9adee747fa43a3195e06e3ac0d49a4403b90e83280fa8f072576a4f44a8e8f3d4de3c62afeb203b72c9d9c60e8be55e5
|
7
|
+
data.tar.gz: 1b9d43ed6c71e64354800efe968df788fde0f6535da20a9bac67d9e2aaf42f90fb47ef002574848b2432890088154680512ed71f6a1c098a39a84ab367c39f74
|
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
@@ -1,11 +1,12 @@
|
|
1
1
|
# MastercardPspPayment
|
2
|
-
Masterpass™ is Mastercard’s integrated digital wallet and checkout solution.
|
3
|
-
Masterpass enables consumers to store and manage their payment, shipping, and loyalty program information
|
2
|
+
Masterpass™ is Mastercard’s integrated digital wallet and checkout solution.
|
3
|
+
Masterpass enables consumers to store and manage their payment, shipping, and loyalty program information
|
4
|
+
in their Masterpass Wallet, and to quickly and seamlessly access this information to make secure payments
|
5
|
+
wherever they see the "Buy with MasterPass" button on a merchant website or mobile application.
|
4
6
|
|
5
|
-
From a cardholder's perspective, Masterpass significantly speeds up the checkout process, removing the need
|
6
|
-
|
7
|
-
|
8
|
-
For more information, refer [Masterpass PSP Integration](https://developer.mastercard.com/documentation/masterpass-integration-psp).
|
7
|
+
From a cardholder's perspective, Masterpass significantly speeds up the checkout process, removing the need
|
8
|
+
to re-enter payment, shipping or loyalty program details during checkout.
|
9
|
+
The Masterpass solution is simple, secure and easy for merchants to integrate into their existing website or application.
|
9
10
|
|
10
11
|
## Installation
|
11
12
|
|
@@ -23,12 +24,11 @@ Or install it yourself as:
|
|
23
24
|
|
24
25
|
$ gem install mastercard_psp_payment
|
25
26
|
|
26
|
-
|
27
27
|
## Copyright
|
28
|
-
Copyright (c)
|
28
|
+
Copyright (c) 2018, Mastercard International Incorporated. See LICENSE for details.
|
29
29
|
|
30
30
|
## LICENSE
|
31
|
-
Copyright (c)
|
31
|
+
Copyright (c) 2018, Mastercard International Incorporated. All rights reserved.
|
32
32
|
|
33
33
|
Redistribution and use in source and binary forms, with or without modification, are
|
34
34
|
permitted provided that the following conditions are met:
|
@@ -11,7 +11,7 @@ module MastercardPspPayment
|
|
11
11
|
include MastercardPspPayment::Tracker
|
12
12
|
|
13
13
|
|
14
|
-
# PSP PaymentData Service
|
14
|
+
# PSP PaymentData Service
|
15
15
|
# This service is used by PSP to retrieve the consumer's payment, shipping address, and personal information.
|
16
16
|
# @param transaction_id This is a transaction identifier.
|
17
17
|
# @param api_config Optional ApiConfig object specifying configuration : consumer key, private key, host URL.
|
@@ -20,6 +20,9 @@ module MastercardPspPayment
|
|
20
20
|
path = "/masterpass/psp-paymentdata/{transactionId}"
|
21
21
|
service_request = ServiceRequest.new
|
22
22
|
service_request.path_params["transactionId"] = transaction_id
|
23
|
+
|
24
|
+
|
25
|
+
|
23
26
|
service_request.content_type = "application/json"
|
24
27
|
api_client = ApiClient.new(api_config)
|
25
28
|
api_client.api_tracker = SdkApiTracker.new
|
@@ -19,7 +19,7 @@ module MastercardPspPayment
|
|
19
19
|
xml_accessor :brand_name, :from =>"brandName"
|
20
20
|
|
21
21
|
# @!attribute account_number
|
22
|
-
# @return [String] the PAN.
|
22
|
+
# @return [String] the card number, also known as Primary Account Number (PAN).
|
23
23
|
xml_accessor :account_number, :from =>"accountNumber"
|
24
24
|
|
25
25
|
# @!attribute card_holder_name
|
@@ -27,11 +27,11 @@ module MastercardPspPayment
|
|
27
27
|
xml_accessor :card_holder_name, :from =>"cardHolderName"
|
28
28
|
|
29
29
|
# @!attribute expiry_month
|
30
|
-
# @return [Integer] the expiration month
|
30
|
+
# @return [Integer] the PAN expiration month, returned as a one or two digit integer. No leading zero is required for single digit months e.g. April is 4.
|
31
31
|
xml_accessor :expiry_month, :from =>"expiryMonth"
|
32
32
|
|
33
33
|
# @!attribute expiry_year
|
34
|
-
# @return [Integer] the expiration year
|
34
|
+
# @return [Integer] the PAN expiration year, returned as a four digit integer.
|
35
35
|
xml_accessor :expiry_year, :from =>"expiryYear"
|
36
36
|
|
37
37
|
# @!attribute billing_address
|
@@ -42,6 +42,10 @@ module MastercardPspPayment
|
|
42
42
|
# @return [String] the last four digit of actual card number.
|
43
43
|
xml_accessor :last_four, :from =>"lastFour"
|
44
44
|
|
45
|
+
# @!attribute card_type
|
46
|
+
# @return [String] the card type (CREDIT/DEBIT) used in checkout. Available only for combo card transactions.
|
47
|
+
xml_accessor :card_type, :from =>"cardType"
|
48
|
+
|
45
49
|
|
46
50
|
# Attribute mapping from ruby-style variable name to JSON key.
|
47
51
|
def self.attribute_map
|
@@ -53,7 +57,8 @@ module MastercardPspPayment
|
|
53
57
|
:expiry_month => :expiryMonth ,
|
54
58
|
:expiry_year => :expiryYear ,
|
55
59
|
:billing_address => :billingAddress ,
|
56
|
-
:last_four => :lastFour
|
60
|
+
:last_four => :lastFour ,
|
61
|
+
:card_type => :cardType
|
57
62
|
|
58
63
|
}
|
59
64
|
end
|
@@ -97,6 +102,10 @@ module MastercardPspPayment
|
|
97
102
|
self.last_four = attributes[:last_four]
|
98
103
|
end
|
99
104
|
|
105
|
+
if attributes.has_key?(:card_type)
|
106
|
+
self.card_type = attributes[:card_type]
|
107
|
+
end
|
108
|
+
|
100
109
|
end
|
101
110
|
|
102
111
|
|
@@ -113,7 +122,8 @@ module MastercardPspPayment
|
|
113
122
|
expiry_month == o.expiry_month &&
|
114
123
|
expiry_year == o.expiry_year &&
|
115
124
|
billing_address == o.billing_address &&
|
116
|
-
last_four == o.last_four
|
125
|
+
last_four == o.last_four &&
|
126
|
+
card_type == o.card_type
|
117
127
|
end
|
118
128
|
|
119
129
|
# @see the `==` method
|
@@ -123,7 +133,7 @@ module MastercardPspPayment
|
|
123
133
|
|
124
134
|
# Calculate hash code according to all attributes.
|
125
135
|
def hash
|
126
|
-
[brand_id, brand_name, account_number, card_holder_name, expiry_month, expiry_year, billing_address, last_four].hash
|
136
|
+
[brand_id, brand_name, account_number, card_holder_name, expiry_month, expiry_year, billing_address, last_four, card_type].hash
|
127
137
|
end
|
128
138
|
|
129
139
|
# build the object from hash
|
@@ -185,7 +195,7 @@ module MastercardPspPayment
|
|
185
195
|
to_hash.to_s
|
186
196
|
end
|
187
197
|
|
188
|
-
# to_body is an alias to to_body (backward compatibility)
|
198
|
+
# to_body is an alias to to_body (backward compatibility)
|
189
199
|
def to_body
|
190
200
|
to_hash
|
191
201
|
end
|
@@ -235,7 +245,8 @@ module MastercardPspPayment
|
|
235
245
|
:expiry_month => 'Integer',
|
236
246
|
:expiry_year => 'Integer',
|
237
247
|
:billing_address => 'Address',
|
238
|
-
:last_four => 'String'
|
248
|
+
:last_four => 'String',
|
249
|
+
:card_type => 'String'
|
239
250
|
|
240
251
|
}
|
241
252
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mastercard_psp_payment
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mastercard
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-02-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mastercard_core_sdk
|
@@ -124,7 +124,7 @@ dependencies:
|
|
124
124
|
- - "~>"
|
125
125
|
- !ruby/object:Gem::Version
|
126
126
|
version: '5.0'
|
127
|
-
description: SDK for Payment Service Provider(PSP)
|
127
|
+
description: Mastercard Masterpass Checkout Integration SDK for Payment Service Provider(PSP).
|
128
128
|
email:
|
129
129
|
- merchant_support@masterpass.com
|
130
130
|
executables: []
|
@@ -145,7 +145,7 @@ files:
|
|
145
145
|
- lib/mastercard_psp_payment/models/tokenization.rb
|
146
146
|
- lib/mastercard_psp_payment/tracker/sdk_api_tracker.rb
|
147
147
|
- lib/mastercard_psp_payment/version.rb
|
148
|
-
homepage: https://developer.mastercard.com
|
148
|
+
homepage: https://developer.mastercard.com
|
149
149
|
licenses:
|
150
150
|
- Mastercard
|
151
151
|
metadata: {}
|
@@ -168,5 +168,5 @@ rubyforge_project:
|
|
168
168
|
rubygems_version: 2.4.5.1
|
169
169
|
signing_key:
|
170
170
|
specification_version: 4
|
171
|
-
summary: Masterpass Payment Service Provider(PSP) Payment SDK
|
171
|
+
summary: Masterpass Payment Service Provider(PSP) Payment SDK.
|
172
172
|
test_files: []
|