mastercard_blockchainb2bxb 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mastercard/api/blockchainb2bxb/{fx.rb → accept.rb} +7 -41
- data/lib/mastercard/api/blockchainb2bxb/claims.rb +2 -2
- data/lib/mastercard/api/blockchainb2bxb/payments.rb +13 -16
- data/lib/mastercard/api/blockchainb2bxb/reject.rb +86 -0
- data/lib/mastercard/api/blockchainb2bxb/resourceconfig.rb +1 -1
- data/lib/mastercard_blockchainb2bxb.rb +2 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d7a314812134b9d44cc1adb626e9a01b608a5c5a
|
4
|
+
data.tar.gz: 66287893fba36ff5b4191cb9cc03e83588988fa2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 78a2ae753f01ccf01248e3f8bba991e3abd69f880cc4824c3861963cf8041bacd2d5f2ead3ef236b565b2c8323dd6528a953be6b17130dd0114adcd0314cd143
|
7
|
+
data.tar.gz: bd37497e6f4fa837b08d29bc2447aeba594cb78156884d07571ee7f9811897548a34de507f838dee37dd10acc245447c387ee067cd9964b30ca63ab095336fc4
|
@@ -32,13 +32,12 @@ require "mastercard/core/baseobject"
|
|
32
32
|
module MasterCard
|
33
33
|
module API
|
34
34
|
module BlockchainB2bxb
|
35
|
-
class
|
35
|
+
class Accept < MasterCard::Core::Model::BaseObject
|
36
36
|
include MasterCard::Core::Model
|
37
37
|
#
|
38
38
|
|
39
39
|
@__store = {
|
40
|
-
'
|
41
|
-
'14e0bcba-ab18-4e46-bad8-7451f3d84968' => OperationConfig.new("/labs/proxy/blockchain/b2bxb/api/v1/fx/{id}", "read", [], []),
|
40
|
+
'ae1fc3e2-6a6b-428f-8332-03cf58dcc3bb' => OperationConfig.new("/labs/proxy/blockchain/b2bxb/api/v1/accepts", "create", [], []),
|
42
41
|
|
43
42
|
}
|
44
43
|
|
@@ -58,21 +57,14 @@ module MasterCard
|
|
58
57
|
public
|
59
58
|
|
60
59
|
|
61
|
-
|
62
|
-
|
63
|
-
def self.listByCriteria(criteria = nil)
|
60
|
+
def self.create(mapObj)
|
64
61
|
#
|
65
|
-
#
|
62
|
+
#Creates object of type Accept
|
66
63
|
#
|
67
|
-
#@param
|
68
|
-
#@return
|
64
|
+
#@param Dict mapObj, containing the required parameters to create a new object
|
65
|
+
#@return [Accept] of the response of created instance.
|
69
66
|
#@raise [APIException] an exception from the response status
|
70
|
-
|
71
|
-
if criteria.nil?
|
72
|
-
return self.execute("646efc1b-16ef-4bf4-ae40-8dc9440e5ad2",FX.new)
|
73
|
-
else
|
74
|
-
return self.execute("646efc1b-16ef-4bf4-ae40-8dc9440e5ad2",FX.new(criteria))
|
75
|
-
end
|
67
|
+
return self.execute("ae1fc3e2-6a6b-428f-8332-03cf58dcc3bb", Accept.new(mapObj))
|
76
68
|
end
|
77
69
|
|
78
70
|
|
@@ -81,32 +73,6 @@ module MasterCard
|
|
81
73
|
|
82
74
|
|
83
75
|
|
84
|
-
|
85
|
-
def self.read(id, criteria = nil)
|
86
|
-
#
|
87
|
-
#Returns objects of type FX by id and optional criteria
|
88
|
-
#@param [String] id
|
89
|
-
#@param [Dict] criteria
|
90
|
-
#@return [FX] object representing the response
|
91
|
-
#@raise [APIException] an exception from the response status
|
92
|
-
|
93
|
-
mapObj = FX.new
|
94
|
-
if !(id.nil? || id.to_s.empty?)
|
95
|
-
mapObj.set("id", id)
|
96
|
-
end
|
97
|
-
if !criteria.nil?
|
98
|
-
if criteria.instance_of? RequestMap
|
99
|
-
mapObj.setAll(criteria.getObject())
|
100
|
-
else
|
101
|
-
mapObj.setAll(criteria)
|
102
|
-
end
|
103
|
-
end
|
104
|
-
|
105
|
-
return self.execute("14e0bcba-ab18-4e46-bad8-7451f3d84968",FX.new(mapObj))
|
106
|
-
end
|
107
|
-
|
108
|
-
|
109
|
-
|
110
76
|
end
|
111
77
|
end
|
112
78
|
end
|
@@ -37,7 +37,7 @@ module MasterCard
|
|
37
37
|
#
|
38
38
|
|
39
39
|
@__store = {
|
40
|
-
'
|
40
|
+
'db44d34e-e17b-42ce-a74f-57cbe2ef59a1' => OperationConfig.new("/labs/proxy/blockchain/b2bxb/api/v1/claims", "create", [], []),
|
41
41
|
|
42
42
|
}
|
43
43
|
|
@@ -64,7 +64,7 @@ module MasterCard
|
|
64
64
|
#@param Dict mapObj, containing the required parameters to create a new object
|
65
65
|
#@return [Claims] of the response of created instance.
|
66
66
|
#@raise [APIException] an exception from the response status
|
67
|
-
return self.execute("
|
67
|
+
return self.execute("db44d34e-e17b-42ce-a74f-57cbe2ef59a1", Claims.new(mapObj))
|
68
68
|
end
|
69
69
|
|
70
70
|
|
@@ -37,9 +37,9 @@ module MasterCard
|
|
37
37
|
#
|
38
38
|
|
39
39
|
@__store = {
|
40
|
-
'
|
41
|
-
'
|
42
|
-
'
|
40
|
+
'a7a448c6-08cf-469c-8e76-7eadc166e411' => OperationConfig.new("/labs/proxy/blockchain/b2bxb/api/v1/payments", "query", [], ["status","offset","count"]),
|
41
|
+
'2a2a84a3-8bac-4cde-ae2c-0a486ad2c86c' => OperationConfig.new("/labs/proxy/blockchain/b2bxb/api/v1/payments", "create", [], ["callbackUrl"]),
|
42
|
+
'a60cc0e9-4720-454e-903b-a4abe6d167b1' => OperationConfig.new("/labs/proxy/blockchain/b2bxb/api/v1/payments/{reference}", "read", [], []),
|
43
43
|
|
44
44
|
}
|
45
45
|
|
@@ -61,24 +61,21 @@ module MasterCard
|
|
61
61
|
|
62
62
|
|
63
63
|
|
64
|
-
|
65
|
-
|
66
|
-
|
64
|
+
|
65
|
+
|
66
|
+
|
67
|
+
def self.query(criteria)
|
67
68
|
#
|
69
|
+
#Query objects of type Payments by id and optional criteria
|
68
70
|
#@param [Dict] criteria
|
69
|
-
#@return
|
71
|
+
#@return [Payments] object representing the response.
|
70
72
|
#@raise [APIException] an exception from the response status
|
73
|
+
#
|
71
74
|
|
72
|
-
|
73
|
-
return self.execute("afc1f961-8125-47a2-a127-f8e5f41a573d",Payments.new)
|
74
|
-
else
|
75
|
-
return self.execute("afc1f961-8125-47a2-a127-f8e5f41a573d",Payments.new(criteria))
|
76
|
-
end
|
75
|
+
return self.execute("a7a448c6-08cf-469c-8e76-7eadc166e411",Payments.new(criteria))
|
77
76
|
end
|
78
77
|
|
79
78
|
|
80
|
-
|
81
|
-
|
82
79
|
def self.create(mapObj)
|
83
80
|
#
|
84
81
|
#Creates object of type Payments
|
@@ -86,7 +83,7 @@ module MasterCard
|
|
86
83
|
#@param Dict mapObj, containing the required parameters to create a new object
|
87
84
|
#@return [Payments] of the response of created instance.
|
88
85
|
#@raise [APIException] an exception from the response status
|
89
|
-
return self.execute("
|
86
|
+
return self.execute("2a2a84a3-8bac-4cde-ae2c-0a486ad2c86c", Payments.new(mapObj))
|
90
87
|
end
|
91
88
|
|
92
89
|
|
@@ -119,7 +116,7 @@ module MasterCard
|
|
119
116
|
end
|
120
117
|
end
|
121
118
|
|
122
|
-
return self.execute("
|
119
|
+
return self.execute("a60cc0e9-4720-454e-903b-a4abe6d167b1",Payments.new(mapObj))
|
123
120
|
end
|
124
121
|
|
125
122
|
|
@@ -0,0 +1,86 @@
|
|
1
|
+
#
|
2
|
+
# Copyright (c) 2016 MasterCard International Incorporated
|
3
|
+
# All rights reserved.
|
4
|
+
#
|
5
|
+
# Redistribution and use in source and binary forms, with or without modification, are
|
6
|
+
# permitted provided that the following conditions are met:
|
7
|
+
#
|
8
|
+
# Redistributions of source code must retain the above copyright notice, this list of
|
9
|
+
# conditions and the following disclaimer.
|
10
|
+
# Redistributions in binary form must reproduce the above copyright notice, this list of
|
11
|
+
# conditions and the following disclaimer in the documentation and/or other materials
|
12
|
+
# provided with the distribution.
|
13
|
+
# Neither the name of the MasterCard International Incorporated nor the names of its
|
14
|
+
# contributors may be used to endorse or promote products derived from this software
|
15
|
+
# without specific prior written permission.
|
16
|
+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
17
|
+
# EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
18
|
+
# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
|
19
|
+
# SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
20
|
+
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
|
21
|
+
# TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
|
22
|
+
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
23
|
+
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
24
|
+
# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
25
|
+
# SUCH DAMAGE.
|
26
|
+
#
|
27
|
+
|
28
|
+
|
29
|
+
require "mastercard/core/model"
|
30
|
+
require "mastercard/core/baseobject"
|
31
|
+
|
32
|
+
module MasterCard
|
33
|
+
module API
|
34
|
+
module BlockchainB2bxb
|
35
|
+
class Reject < MasterCard::Core::Model::BaseObject
|
36
|
+
include MasterCard::Core::Model
|
37
|
+
#
|
38
|
+
|
39
|
+
@__store = {
|
40
|
+
'0dd94e91-8619-496f-9b21-980a2ecfee4f' => OperationConfig.new("/labs/proxy/blockchain/b2bxb/api/v1/rejects", "create", [], []),
|
41
|
+
|
42
|
+
}
|
43
|
+
|
44
|
+
protected
|
45
|
+
|
46
|
+
def self.getOperationConfig(operationUUID)
|
47
|
+
if @__store.key?(operationUUID)
|
48
|
+
return @__store[operationUUID]
|
49
|
+
end
|
50
|
+
raise NotImplementedError.new("Invalid operationUUID supplied:"+ operationUUID)
|
51
|
+
end
|
52
|
+
|
53
|
+
def self.getOperationMetadata()
|
54
|
+
return OperationMetadata.new(ResourceConfig.instance.getVersion(), ResourceConfig.instance.getHost(), ResourceConfig.instance.getContext(), ResourceConfig.instance.getJsonNative(), ResourceConfig.instance.getContentTypeOverride())
|
55
|
+
end
|
56
|
+
|
57
|
+
public
|
58
|
+
|
59
|
+
|
60
|
+
def self.create(mapObj)
|
61
|
+
#
|
62
|
+
#Creates object of type Reject
|
63
|
+
#
|
64
|
+
#@param Dict mapObj, containing the required parameters to create a new object
|
65
|
+
#@return [Reject] of the response of created instance.
|
66
|
+
#@raise [APIException] an exception from the response status
|
67
|
+
return self.execute("0dd94e91-8619-496f-9b21-980a2ecfee4f", Reject.new(mapObj))
|
68
|
+
end
|
69
|
+
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
|
84
|
+
|
85
|
+
|
86
|
+
|
@@ -2,6 +2,7 @@ require 'mastercard_api_core'
|
|
2
2
|
|
3
3
|
require 'mastercard/api/blockchainb2bxb/resourceconfig'
|
4
4
|
|
5
|
+
require 'mastercard/api/blockchainb2bxb/accept'
|
5
6
|
require 'mastercard/api/blockchainb2bxb/claims'
|
6
|
-
require 'mastercard/api/blockchainb2bxb/fx'
|
7
7
|
require 'mastercard/api/blockchainb2bxb/payments'
|
8
|
+
require 'mastercard/api/blockchainb2bxb/reject'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mastercard_blockchainb2bxb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- MasterCard Worldwide
|
@@ -51,9 +51,10 @@ executables: []
|
|
51
51
|
extensions: []
|
52
52
|
extra_rdoc_files: []
|
53
53
|
files:
|
54
|
+
- lib/mastercard/api/blockchainb2bxb/accept.rb
|
54
55
|
- lib/mastercard/api/blockchainb2bxb/claims.rb
|
55
|
-
- lib/mastercard/api/blockchainb2bxb/fx.rb
|
56
56
|
- lib/mastercard/api/blockchainb2bxb/payments.rb
|
57
|
+
- lib/mastercard/api/blockchainb2bxb/reject.rb
|
57
58
|
- lib/mastercard/api/blockchainb2bxb/resourceconfig.rb
|
58
59
|
- lib/mastercard_blockchainb2bxb.rb
|
59
60
|
homepage: https://developer.mastercard.com
|