mastercard_spendcontrols 1.0.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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 54c5336b35de41f775cc5e89c92dd3e050316904
4
+ data.tar.gz: e6aa4922f69ff2eda7def0b4cd51384a61ccfa7a
5
+ SHA512:
6
+ metadata.gz: a70611baeec456d98ce880c40c2f1dc08ace1abd5cf6ef87852ac607d4648113afd9093198197fc1249559d278d9adeca3f0044cd467301f5abd4c2b5805d6af
7
+ data.tar.gz: e00984634ed72023751ac91a07990304c5914892e2ae7fc5b07f60b722ce6d6c64765a8d2607e52fa17d448c9a734288171906416b03c0ea909f928c052210e0
@@ -0,0 +1,148 @@
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 Spendcontrols
35
+ class Alertall < MasterCard::Core::Model::BaseObject
36
+ include MasterCard::Core::Model
37
+ #
38
+
39
+ @__store = {
40
+ '2bac28a6-eee3-4749-845f-8721bc4f14ba' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts/all", "delete", [], []),
41
+ 'a59b81e3-b09e-4a36-a41f-784aa4178dc8' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts/all", "query", [], []),
42
+ 'fd891bc2-c512-4bed-be13-5954eed13edc' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts/all", "create", [], []),
43
+
44
+ }
45
+
46
+ protected
47
+
48
+ def self.getOperationConfig(uuid)
49
+ if @__store.key?(uuid)
50
+ return @__store[uuid]
51
+ end
52
+ raise NotImplementedError.new("Invalid operationUUID supplied:"+ uuid)
53
+ end
54
+
55
+ def self.getOperationMetadata()
56
+ return OperationMetadata.new(ResourceConfig.instance.getVersion(), ResourceConfig.instance.getHost(), ResourceConfig.instance.getContext())
57
+ end
58
+
59
+ public
60
+
61
+
62
+
63
+
64
+
65
+ def self.deleteById(id, map = nil)
66
+ #Delete object of type Alertall by id
67
+
68
+ #@param [String] id
69
+ #@param [Dict] map, containing additional parameters
70
+ #@return [Alertall] of the response of the deleted instance.
71
+ #@raise [APIException] an exception from the response status
72
+
73
+
74
+ mapObj = Alertall.new
75
+ if !(id.nil? || id.to_s.empty?)
76
+ mapObj.set("id", id)
77
+ end
78
+ if !map.nil?
79
+ if map.instance_of? RequestMap
80
+ mapObj.setAll(map.getObject())
81
+ else
82
+ mapObj.setAll(map)
83
+ end
84
+ end
85
+
86
+ return self.execute("2bac28a6-eee3-4749-845f-8721bc4f14ba", mapObj)
87
+ end
88
+
89
+
90
+ def delete
91
+ #
92
+ #Delete object of type Alertall
93
+
94
+ #@param [String] id
95
+ #@return [Alertall] of the response of the deleted instance.
96
+ #@raise [APIException] an exception from the response status
97
+ #
98
+
99
+ return self.class.execute("2bac28a6-eee3-4749-845f-8721bc4f14ba", self)
100
+ end
101
+
102
+
103
+
104
+
105
+
106
+
107
+
108
+
109
+
110
+ def self.query(criteria)
111
+ #
112
+ #Query objects of type Alertall by id and optional criteria
113
+ #@param [Dict] criteria
114
+ #@return [Alertall] object representing the response.
115
+ #@raise [APIException] an exception from the response status
116
+ #
117
+
118
+ return self.execute("a59b81e3-b09e-4a36-a41f-784aa4178dc8",Alertall.new(criteria))
119
+ end
120
+
121
+
122
+ def self.create(mapObj)
123
+ #
124
+ #Creates object of type Alertall
125
+ #
126
+ #@param Dict mapObj, containing the required parameters to create a new object
127
+ #@return [Alertall] of the response of created instance.
128
+ #@raise [APIException] an exception from the response status
129
+ return self.execute("fd891bc2-c512-4bed-be13-5954eed13edc", Alertall.new(mapObj))
130
+ end
131
+
132
+
133
+
134
+
135
+
136
+
137
+
138
+ end
139
+ end
140
+ end
141
+ end
142
+
143
+
144
+
145
+
146
+
147
+
148
+
@@ -0,0 +1,148 @@
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 Spendcontrols
35
+ class Alerts < MasterCard::Core::Model::BaseObject
36
+ include MasterCard::Core::Model
37
+ #
38
+
39
+ @__store = {
40
+ '664f6e72-1b04-4284-95e2-b525ebc9d64e' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts", "delete", [], []),
41
+ '5ff9922f-fa3f-40d6-8f39-cdb6dcfa7f41' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts", "query", [], []),
42
+ '2ebcb607-1d6f-44b2-b641-34677bff7ac9' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts", "create", [], []),
43
+
44
+ }
45
+
46
+ protected
47
+
48
+ def self.getOperationConfig(uuid)
49
+ if @__store.key?(uuid)
50
+ return @__store[uuid]
51
+ end
52
+ raise NotImplementedError.new("Invalid operationUUID supplied:"+ uuid)
53
+ end
54
+
55
+ def self.getOperationMetadata()
56
+ return OperationMetadata.new(ResourceConfig.instance.getVersion(), ResourceConfig.instance.getHost(), ResourceConfig.instance.getContext())
57
+ end
58
+
59
+ public
60
+
61
+
62
+
63
+
64
+
65
+ def self.deleteById(id, map = nil)
66
+ #Delete object of type Alerts by id
67
+
68
+ #@param [String] id
69
+ #@param [Dict] map, containing additional parameters
70
+ #@return [Alerts] of the response of the deleted instance.
71
+ #@raise [APIException] an exception from the response status
72
+
73
+
74
+ mapObj = Alerts.new
75
+ if !(id.nil? || id.to_s.empty?)
76
+ mapObj.set("id", id)
77
+ end
78
+ if !map.nil?
79
+ if map.instance_of? RequestMap
80
+ mapObj.setAll(map.getObject())
81
+ else
82
+ mapObj.setAll(map)
83
+ end
84
+ end
85
+
86
+ return self.execute("664f6e72-1b04-4284-95e2-b525ebc9d64e", mapObj)
87
+ end
88
+
89
+
90
+ def delete
91
+ #
92
+ #Delete object of type Alerts
93
+
94
+ #@param [String] id
95
+ #@return [Alerts] of the response of the deleted instance.
96
+ #@raise [APIException] an exception from the response status
97
+ #
98
+
99
+ return self.class.execute("664f6e72-1b04-4284-95e2-b525ebc9d64e", self)
100
+ end
101
+
102
+
103
+
104
+
105
+
106
+
107
+
108
+
109
+
110
+ def self.query(criteria)
111
+ #
112
+ #Query objects of type Alerts by id and optional criteria
113
+ #@param [Dict] criteria
114
+ #@return [Alerts] object representing the response.
115
+ #@raise [APIException] an exception from the response status
116
+ #
117
+
118
+ return self.execute("5ff9922f-fa3f-40d6-8f39-cdb6dcfa7f41",Alerts.new(criteria))
119
+ end
120
+
121
+
122
+ def self.create(mapObj)
123
+ #
124
+ #Creates object of type Alerts
125
+ #
126
+ #@param Dict mapObj, containing the required parameters to create a new object
127
+ #@return [Alerts] of the response of created instance.
128
+ #@raise [APIException] an exception from the response status
129
+ return self.execute("2ebcb607-1d6f-44b2-b641-34677bff7ac9", Alerts.new(mapObj))
130
+ end
131
+
132
+
133
+
134
+
135
+
136
+
137
+
138
+ end
139
+ end
140
+ end
141
+ end
142
+
143
+
144
+
145
+
146
+
147
+
148
+
@@ -0,0 +1,148 @@
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 Spendcontrols
35
+ class Amount < MasterCard::Core::Model::BaseObject
36
+ include MasterCard::Core::Model
37
+ #
38
+
39
+ @__store = {
40
+ '91ebb912-cde3-4536-96b3-fafbb5992409' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts/transactionamount", "delete", [], []),
41
+ 'd68d891d-5383-4a97-a8ce-e8ca9dfcfd6f' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts/transactionamount", "query", [], []),
42
+ '75bd13e8-38e9-42eb-9091-ef8e7c6f700d' => OperationConfig.new("/issuer/v1/card/{uuid}/controls/alerts/transactionamount", "create", [], []),
43
+
44
+ }
45
+
46
+ protected
47
+
48
+ def self.getOperationConfig(uuid)
49
+ if @__store.key?(uuid)
50
+ return @__store[uuid]
51
+ end
52
+ raise NotImplementedError.new("Invalid operationUUID supplied:"+ uuid)
53
+ end
54
+
55
+ def self.getOperationMetadata()
56
+ return OperationMetadata.new(ResourceConfig.instance.getVersion(), ResourceConfig.instance.getHost(), ResourceConfig.instance.getContext())
57
+ end
58
+
59
+ public
60
+
61
+
62
+
63
+
64
+
65
+ def self.deleteById(id, map = nil)
66
+ #Delete object of type Amount by id
67
+
68
+ #@param [String] id
69
+ #@param [Dict] map, containing additional parameters
70
+ #@return [Amount] of the response of the deleted instance.
71
+ #@raise [APIException] an exception from the response status
72
+
73
+
74
+ mapObj = Amount.new
75
+ if !(id.nil? || id.to_s.empty?)
76
+ mapObj.set("id", id)
77
+ end
78
+ if !map.nil?
79
+ if map.instance_of? RequestMap
80
+ mapObj.setAll(map.getObject())
81
+ else
82
+ mapObj.setAll(map)
83
+ end
84
+ end
85
+
86
+ return self.execute("91ebb912-cde3-4536-96b3-fafbb5992409", mapObj)
87
+ end
88
+
89
+
90
+ def delete
91
+ #
92
+ #Delete object of type Amount
93
+
94
+ #@param [String] id
95
+ #@return [Amount] of the response of the deleted instance.
96
+ #@raise [APIException] an exception from the response status
97
+ #
98
+
99
+ return self.class.execute("91ebb912-cde3-4536-96b3-fafbb5992409", self)
100
+ end
101
+
102
+
103
+
104
+
105
+
106
+
107
+
108
+
109
+
110
+ def self.query(criteria)
111
+ #
112
+ #Query objects of type Amount by id and optional criteria
113
+ #@param [Dict] criteria
114
+ #@return [Amount] object representing the response.
115
+ #@raise [APIException] an exception from the response status
116
+ #
117
+
118
+ return self.execute("d68d891d-5383-4a97-a8ce-e8ca9dfcfd6f",Amount.new(criteria))
119
+ end
120
+
121
+
122
+ def self.create(mapObj)
123
+ #
124
+ #Creates object of type Amount
125
+ #
126
+ #@param Dict mapObj, containing the required parameters to create a new object
127
+ #@return [Amount] of the response of created instance.
128
+ #@raise [APIException] an exception from the response status
129
+ return self.execute("75bd13e8-38e9-42eb-9091-ef8e7c6f700d", Amount.new(mapObj))
130
+ end
131
+
132
+
133
+
134
+
135
+
136
+
137
+
138
+ end
139
+ end
140
+ end
141
+ end
142
+
143
+
144
+
145
+
146
+
147
+
148
+