bambora-client 0.1.3 → 0.2.0
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/Gemfile.lock +3 -3
- data/lib/bambora/client/version.rb +1 -1
- data/lib/bambora/v1/profile_resource.rb +42 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0ba08f9e38a85141dce37a2cc1ef6b85a7935ecda24d06abc4811cfbd467e1d4
|
4
|
+
data.tar.gz: 5d5608a1401b10ced7a4881456941531346e8fb903da6e7016785fa6bcc7e586
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 68935433385cd450909aee6f18ed9dce231d68e6c4d960bc33f888f0ae5ce7ed83936b66f58d1ca9db9989487505009cbd0459a058c6b3ba4b7bee88ad0a5f60
|
7
|
+
data.tar.gz: 348eaec713407d64e216e64f462c6d3c2298e1d3b84caa31d85b8424fba19f6ddf4e6a5803a664143894a29a58d913e4a55770cfe0e4a1668fbd07626d3eda06
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
bambora-client (0.1.
|
4
|
+
bambora-client (0.1.3)
|
5
5
|
excon (< 1.0)
|
6
6
|
faraday (< 1.0)
|
7
7
|
gyoku (~> 1.0)
|
@@ -29,7 +29,7 @@ GEM
|
|
29
29
|
method_source (0.9.2)
|
30
30
|
mime-types (3.3.1)
|
31
31
|
mime-types-data (~> 3.2015)
|
32
|
-
mime-types-data (3.
|
32
|
+
mime-types-data (3.2020.0425)
|
33
33
|
multipart-post (2.1.1)
|
34
34
|
multiparty (0.2.0)
|
35
35
|
mime-types
|
@@ -90,4 +90,4 @@ DEPENDENCIES
|
|
90
90
|
webmock (~> 3.7)
|
91
91
|
|
92
92
|
BUNDLED WITH
|
93
|
-
2.1.
|
93
|
+
2.1.1
|
@@ -58,6 +58,48 @@ module Bambora
|
|
58
58
|
client.post(path: sub_path, body: card_data, api_key: api_key)
|
59
59
|
end
|
60
60
|
|
61
|
+
##
|
62
|
+
# Get a Bambora payment profile given a customer code.
|
63
|
+
#
|
64
|
+
# @example
|
65
|
+
#
|
66
|
+
# client = Bambora::Rest::JSONClient(base_url: '...', api_key: '...', merchant_id: '...')
|
67
|
+
# profiles = Bambora::V1::ProfileResource(client: client)
|
68
|
+
# customer_code = '02355E2e58Bf488EAB4EaFAD7083dB6A'
|
69
|
+
#
|
70
|
+
# profiles.get(customer_code: customer_code)
|
71
|
+
# # => {
|
72
|
+
# # :code => 1,
|
73
|
+
# # :message => "Operation Successful",
|
74
|
+
# # :customer_code => "02355E2e58Bf488EAB4EaFAD7083dB6A",
|
75
|
+
# # :status => "A",
|
76
|
+
# # :last_transaction => "1900-01-01T00:00:00",
|
77
|
+
# # :modified_date => "1900-01-01T00:00:00",
|
78
|
+
# # :card => { :name => "", :number => "", :card_type => "" },
|
79
|
+
# # :language => "en",
|
80
|
+
# # :velocity_group => "",
|
81
|
+
# # :profile_group => "",
|
82
|
+
# # :account_ref => "",
|
83
|
+
# # :billing =>
|
84
|
+
# # {
|
85
|
+
# # :name => "Harry Lewis",
|
86
|
+
# # :address_line1 => "",
|
87
|
+
# # :address_line2 => "",
|
88
|
+
# # :city => "",
|
89
|
+
# # :province => "",
|
90
|
+
# # :country => "",
|
91
|
+
# # :postal_code => "",
|
92
|
+
# # :phone_number => "",
|
93
|
+
# # :email_address => ""},
|
94
|
+
# # :custom => { :ref1 => "", :ref2 => "", :ref3 => "", :ref4 => "", :ref5 => "" }}
|
95
|
+
#
|
96
|
+
# @param customer_code [String] A unique identifier for the associated payment profile.
|
97
|
+
#
|
98
|
+
# @return [Hash] Payment profile details.
|
99
|
+
def get(customer_code:)
|
100
|
+
client.get(path: "#{sub_path}/#{customer_code}", api_key: api_key)
|
101
|
+
end
|
102
|
+
|
61
103
|
##
|
62
104
|
# Delete a Bambora payment profile given a customer code.
|
63
105
|
#
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bambora-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Cassidy K
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-05-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: excon
|