killbill-stripe 3.0.1 → 3.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/NEWS +3 -0
- data/README.md +30 -0
- data/VERSION +1 -1
- data/lib/stripe/api.rb +1 -1
- data/lib/stripe/models/payment_method.rb +2 -2
- data/pom.xml +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 93eb72559ef8c3517570c186d5f29be49c610462
|
4
|
+
data.tar.gz: fcc197f4c25a3689271280e120605bc087cd6e28
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8787b675c7f96d674dbc007a6bd322c4af0d93ac925ed953e6611b69dd54541c78beeed0a724008efcd8e0540fb85d6887617f462dda7203b717c713094dc139
|
7
|
+
data.tar.gz: 7a33c85bfd8331bdb59da1ee01656aad78fe7e3cbe238dc76bb5b18d0397cba6e29ca5c7935fd46f2be3c5041530d51c7a394f8fade77dd41b11296a7d74db00
|
data/Gemfile.lock
CHANGED
data/NEWS
CHANGED
data/README.md
CHANGED
@@ -80,3 +80,33 @@ An example implementation is exposed at:
|
|
80
80
|
```
|
81
81
|
http://127.0.0.1:8080/plugins/killbill-stripe?kb_account_id=2a55045a-ce1d-4344-942d-b825536328f9&kb_tenant_id=a86d9fd1-718d-4178-a9eb-46c61aa2548f
|
82
82
|
```
|
83
|
+
|
84
|
+
Plugin properties
|
85
|
+
-----------------
|
86
|
+
|
87
|
+
| Key | Description |
|
88
|
+
| ---------------------------: | ----------------------------------------------------------------- |
|
89
|
+
| skip_gw | If true, skip the call to Stripe |
|
90
|
+
| payment_processor_account_id | Config entry name of the merchant account to use |
|
91
|
+
| external_key_as_order_id | If true, set the payment external key as the Stripe order id |
|
92
|
+
| customer | Stripe customer id |
|
93
|
+
| token | Stripe token |
|
94
|
+
| cc_first_name | Credit card holder first name |
|
95
|
+
| cc_last_name | Credit card holder last name |
|
96
|
+
| cc_type | Credit card brand |
|
97
|
+
| cc_expiration_month | Credit card expiration month |
|
98
|
+
| cc_expiration_year | Credit card expiration year |
|
99
|
+
| cc_verification_value | CVC/CVV/CVN |
|
100
|
+
| email | Purchaser email |
|
101
|
+
| address1 | Billing address first line |
|
102
|
+
| address2 | Billing address second line |
|
103
|
+
| city | Billing address city |
|
104
|
+
| zip | Billing address zip code |
|
105
|
+
| state | Billing address state |
|
106
|
+
| country | Billing address country |
|
107
|
+
| eci | Network tokenization attribute |
|
108
|
+
| payment_cryptogram | Network tokenization attribute |
|
109
|
+
| transaction_id | Network tokenization attribute |
|
110
|
+
| payment_instrument_name | ApplePay tokenization attribute |
|
111
|
+
| payment_network | ApplePay tokenization attribute |
|
112
|
+
| transaction_identifier | ApplePay tokenization attribute |
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
3.0.
|
1
|
+
3.0.2
|
data/lib/stripe/api.rb
CHANGED
@@ -96,7 +96,7 @@ module Killbill #:nodoc:
|
|
96
96
|
|
97
97
|
def add_payment_method(kb_account_id, kb_payment_method_id, payment_method_props, set_default, properties, context)
|
98
98
|
# Do we have a customer for that account already?
|
99
|
-
stripe_customer_id = StripePaymentMethod.stripe_customer_id_from_kb_account_id(kb_account_id, context.tenant_id)
|
99
|
+
stripe_customer_id = find_value_from_properties(payment_method_props.properties, :customer) || StripePaymentMethod.stripe_customer_id_from_kb_account_id(kb_account_id, context.tenant_id)
|
100
100
|
|
101
101
|
# Pass extra parameters for the gateway here
|
102
102
|
options = {
|
@@ -5,7 +5,7 @@ module Killbill #:nodoc:
|
|
5
5
|
self.table_name = 'stripe_payment_methods'
|
6
6
|
|
7
7
|
def self.from_response(kb_account_id, kb_payment_method_id, kb_tenant_id, cc_or_token, response, options, extra_params = {}, model = ::Killbill::Stripe::StripePaymentMethod)
|
8
|
-
stripe_customer_id = self.stripe_customer_id_from_kb_account_id(kb_account_id, kb_tenant_id)
|
8
|
+
stripe_customer_id = options[:customer] || self.stripe_customer_id_from_kb_account_id(kb_account_id, kb_tenant_id)
|
9
9
|
if !stripe_customer_id.blank? && response.respond_to?(:responses)
|
10
10
|
card_response = response.responses.first.params
|
11
11
|
customer_response = response.responses.last.params
|
@@ -14,7 +14,7 @@ module Killbill #:nodoc:
|
|
14
14
|
customer_response = response.params
|
15
15
|
else
|
16
16
|
card_response = {}
|
17
|
-
customer_response = {}
|
17
|
+
customer_response = { 'id' => stripe_customer_id }
|
18
18
|
end
|
19
19
|
|
20
20
|
super(kb_account_id,
|
data/pom.xml
CHANGED
@@ -25,7 +25,7 @@
|
|
25
25
|
<groupId>org.kill-bill.billing.plugin.ruby</groupId>
|
26
26
|
<artifactId>stripe-plugin</artifactId>
|
27
27
|
<packaging>pom</packaging>
|
28
|
-
<version>3.0.
|
28
|
+
<version>3.0.2</version>
|
29
29
|
<name>stripe-plugin</name>
|
30
30
|
<url>http://github.com/killbill/killbill-stripe-plugin</url>
|
31
31
|
<description>Plugin for accessing Stripe as a payment gateway</description>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: killbill-stripe
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kill Bill core team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-01-
|
11
|
+
date: 2016-01-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: killbill
|