dwolla_swagger 1.0.7 → 1.0.8

Sign up to get free protection for your applications and to get access to all the features.
Files changed (30) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +2 -2
  3. data/README.md +8 -1
  4. data/lib/dwolla_swagger/api/customers_api.rb +2 -0
  5. data/lib/dwolla_swagger/api/fundingsources_api.rb +96 -3
  6. data/lib/dwolla_swagger/api/masspaymentitems_api.rb +108 -0
  7. data/lib/dwolla_swagger/api/masspayments_api.rb +196 -0
  8. data/lib/dwolla_swagger/api/ondemandauthorizations_api.rb +49 -0
  9. data/lib/dwolla_swagger/api/transfers_api.rb +95 -2
  10. data/lib/dwolla_swagger/models/authorization.rb +28 -0
  11. data/lib/dwolla_swagger/models/create_funding_source_request.rb +9 -1
  12. data/lib/dwolla_swagger/models/customer.rb +59 -3
  13. data/lib/dwolla_swagger/models/document.rb +9 -1
  14. data/lib/dwolla_swagger/models/facilitator_fee_request.rb +46 -0
  15. data/lib/dwolla_swagger/models/funding_source.rb +11 -3
  16. data/lib/dwolla_swagger/models/funding_source_balance.rb +62 -0
  17. data/lib/dwolla_swagger/models/id.rb +28 -0
  18. data/lib/dwolla_swagger/models/mass_payment.rb +76 -0
  19. data/lib/dwolla_swagger/models/mass_payment_item.rb +76 -0
  20. data/lib/dwolla_swagger/models/mass_payment_item_list_response.rb +54 -0
  21. data/lib/dwolla_swagger/models/mass_payment_item_request_body.rb +52 -0
  22. data/lib/dwolla_swagger/models/mass_payment_list_response.rb +54 -0
  23. data/lib/dwolla_swagger/models/mass_payment_request_body.rb +54 -0
  24. data/lib/dwolla_swagger/models/remove_bank_request.rb +36 -0
  25. data/lib/dwolla_swagger/models/transfer_request_body.rb +13 -3
  26. data/lib/dwolla_swagger/models/update_transfer.rb +36 -0
  27. data/lib/dwolla_swagger/swagger/version.rb +1 -1
  28. data/lib/dwolla_swagger.rb +35 -20
  29. metadata +18 -4
  30. data/dwolla_swagger-1.0.6.gem +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4f2a76657b31293c046729c56847fdd76aadfbc5
4
- data.tar.gz: 345d18c0d09c95a225e6cf704a747d79e26bcc43
3
+ metadata.gz: 6d927b525b49201af925e1048cf65fffed20e430
4
+ data.tar.gz: 42e3aa9b616c4871c78cdb7a3f33579a5701dc3c
5
5
  SHA512:
6
- metadata.gz: b8eaccdefbc43b3545b7f84c50bed7a31e11a01ce9f80580f0579b2ebe2c7b2b3227fa063e2461253a088a5d19e0030ec961bf129684b5a8816a77d125263dda
7
- data.tar.gz: 66e103a2fbe2accb01419d24384f93f3c25f838a6ee19ce721bb33e376f6f63a16d753d255024b2ac41a890f4ca2dce0fe77be750fa88a303c02916edb43c82c
6
+ metadata.gz: 60cfb90a062989e93d059a4ef5fd0491051bfeec805ac47afa7c741659da38477861b5473724dffb8a3693d54eaba2b6608231a257b9e7f897023a31cd90b2d9
7
+ data.tar.gz: 4174d2c533544027725e0cd9488b7a9ba005daa15efcc32eeac752695ad76cbe73d4d832960dfc4bc3a04c8d22faacbad9695d8bc1800f99e6ecb86115775e84
data/Gemfile.lock CHANGED
@@ -20,7 +20,7 @@ GEM
20
20
  crack (0.4.3)
21
21
  safe_yaml (~> 1.0.0)
22
22
  diff-lcs (1.2.5)
23
- ethon (0.8.1)
23
+ ethon (0.8.0)
24
24
  ffi (>= 1.3.0)
25
25
  ffi (1.9.10)
26
26
  hashdiff (0.2.3)
@@ -63,4 +63,4 @@ DEPENDENCIES
63
63
  webmock (~> 1.6, >= 1.6.2)
64
64
 
65
65
  BUNDLED WITH
66
- 1.11.2
66
+ 1.10.6
data/README.md CHANGED
@@ -5,7 +5,7 @@ The new Dwolla API V2 SDK, as generated by [this fork of swagger-codegen](https:
5
5
 
6
6
  ## Version
7
7
 
8
- 1.0.6
8
+ 1.0.8
9
9
 
10
10
  ## Installation
11
11
 
@@ -146,6 +146,13 @@ Each model represents the different kinds of requests and responses that can be
146
146
 
147
147
  ## Changelog
148
148
 
149
+ 1.0.8
150
+ * API schema updated - `CustomersApi` contains support for Customer search. `FundingSourceApi` has new method for soft delete and new endpoint for retrieve balance. `TransfersApi` contains support for cancel a transfer and new endpoint to retrieve a transfer's fees. New `OndemandauthorizationsApi`, `MasspaymentsApi`, and `MasspaymentitemsApi`.
151
+ * Existing `Customer`, `CreateFundingSourceRequest`, `TransferRequestBody`, `Document`, `FundingSource` models updated. New `MassPayment`, `Authorization`, `FundingSourceBalance`, `RemoveBankRequest`, and `UpdateTransfer` models.
152
+
153
+ 1.0.7
154
+ * Ensure DateTime is loaded
155
+
149
156
  1.0.6
150
157
  * Fix micro deposit methods in `FundingSourceApi` to fix issue where requests weren't being sent.
151
158
 
@@ -12,6 +12,7 @@ module DwollaSwagger
12
12
  # @param [Hash] opts the optional parameters
13
13
  # @option opts [int] :limit How many results to return.
14
14
  # @option opts [int] :offset How many results to skip.
15
+ # @option opts [string] :search Search term.
15
16
  # @return [CustomerListResponse]
16
17
  def self.list(opts = {})
17
18
 
@@ -25,6 +26,7 @@ module DwollaSwagger
25
26
  query_params = {}
26
27
  query_params[:'limit'] = opts[:'limit'] if opts[:'limit']
27
28
  query_params[:'offset'] = opts[:'offset'] if opts[:'offset']
29
+ query_params[:'search'] = opts[:'search'] if opts[:'search']
28
30
 
29
31
  # header parameters
30
32
  header_params = {}
@@ -9,7 +9,7 @@ module DwollaSwagger
9
9
 
10
10
  # Get an account's funding sources.
11
11
  #
12
- # @param id Account UUID to get funding sources for.
12
+ # @param id Account id to get funding sources for.
13
13
  # @param [Hash] opts the optional parameters
14
14
  # @return [FundingSourceListResponse]
15
15
  def self.get_account_funding_sources(id, opts = {})
@@ -55,7 +55,7 @@ module DwollaSwagger
55
55
 
56
56
  # Get a customer's funding sources.
57
57
  #
58
- # @param id Customer UUID to get funding sources for.
58
+ # @param id Customer id to get funding sources for.
59
59
  # @param [Hash] opts the optional parameters
60
60
  # @return [FundingSourceListResponse]
61
61
  def self.get_customer_funding_sources(id, opts = {})
@@ -101,7 +101,7 @@ module DwollaSwagger
101
101
 
102
102
  # Create a new funding source.
103
103
  #
104
- # @param id Customer UUID to create funding source for.
104
+ # @param id Customer id to create funding source for.
105
105
  # @param [Hash] opts the optional parameters
106
106
  # @option opts [CreateFundingSourceRequest] :body Funding source to create.
107
107
  # @return [FundingSource]
@@ -232,6 +232,53 @@ module DwollaSwagger
232
232
 
233
233
  end
234
234
 
235
+ # Remove a funding source.
236
+ #
237
+ # @param id Funding source ID to remove.
238
+ # @param [Hash] opts the optional parameters
239
+ # @option opts [RemoveBankRequest] :body request body to remove a funding source
240
+ # @return [Unit]
241
+ def self.soft_delete(id, opts = {})
242
+
243
+ # verify the required parameter 'id' is set
244
+ raise "Missing the required parameter 'id' when calling soft_delete" if id.nil?
245
+
246
+
247
+ # resource path
248
+ path = "/funding-sources/{id}".sub('{format}','json')
249
+
250
+
251
+ # check if id parameter is resource URI, otherwise substitute for ID
252
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
253
+
254
+
255
+ # query parameters
256
+ query_params = {}
257
+
258
+ # header parameters
259
+ header_params = {}
260
+
261
+ # HTTP header 'Accept' (if needed)
262
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
263
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
264
+
265
+ # HTTP header 'Content-Type'
266
+ _header_content_type = []
267
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
268
+
269
+ # form parameters
270
+ form_params = {}
271
+
272
+ # http body (model)
273
+ post_body = Swagger::Request.object_to_http_body(opts[:'body'])
274
+
275
+
276
+ response = Swagger::Request.new(:POST, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
277
+
278
+ response.code == 201 ? obj = response.headers['Location'] : (obj = Unit.new() and obj.build_from_hash(response.body))
279
+
280
+ end
281
+
235
282
  # Delete a funding source by id.
236
283
  #
237
284
  # @param id Funding source ID to delete.
@@ -278,6 +325,52 @@ module DwollaSwagger
278
325
 
279
326
  end
280
327
 
328
+ # Get the balance of a funding source.
329
+ #
330
+ # @param id Funding source ID to get the balance for.
331
+ # @param [Hash] opts the optional parameters
332
+ # @return [FundingSourceBalance]
333
+ def self.get_balance(id, opts = {})
334
+
335
+ # verify the required parameter 'id' is set
336
+ raise "Missing the required parameter 'id' when calling get_balance" if id.nil?
337
+
338
+
339
+ # resource path
340
+ path = "/funding-sources/{id}/balance".sub('{format}','json')
341
+
342
+
343
+ # check if id parameter is resource URI, otherwise substitute for ID
344
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
345
+
346
+
347
+ # query parameters
348
+ query_params = {}
349
+
350
+ # header parameters
351
+ header_params = {}
352
+
353
+ # HTTP header 'Accept' (if needed)
354
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
355
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
356
+
357
+ # HTTP header 'Content-Type'
358
+ _header_content_type = []
359
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
360
+
361
+ # form parameters
362
+ form_params = {}
363
+
364
+ # http body (model)
365
+ post_body = nil
366
+
367
+
368
+ response = Swagger::Request.new(:GET, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
369
+
370
+ response.code == 201 ? obj = response.headers['Location'] : (obj = FundingSourceBalance.new() and obj.build_from_hash(response.body))
371
+
372
+ end
373
+
281
374
  # Verify pending verifications exist.
282
375
  #
283
376
  # @param id Funding source ID to check for pending validation deposits for.
@@ -0,0 +1,108 @@
1
+ require 'uri'
2
+
3
+ module DwollaSwagger
4
+ class MasspaymentitemsApi
5
+ basePath = "https://localhost/"
6
+ # apiInvoker = APIInvoker
7
+ @auth_names = ['oauth2']
8
+
9
+
10
+ # Get a mass payment item by id.
11
+ #
12
+ # @param id ID of mass payment item to get.
13
+ # @param [Hash] opts the optional parameters
14
+ # @return [MassPaymentItem]
15
+ def self.by_id(id, opts = {})
16
+
17
+ # verify the required parameter 'id' is set
18
+ raise "Missing the required parameter 'id' when calling by_id" if id.nil?
19
+
20
+
21
+ # resource path
22
+ path = "/mass-payment-items/{id}".sub('{format}','json')
23
+
24
+
25
+ # check if id parameter is resource URI, otherwise substitute for ID
26
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
27
+
28
+
29
+ # query parameters
30
+ query_params = {}
31
+
32
+ # header parameters
33
+ header_params = {}
34
+
35
+ # HTTP header 'Accept' (if needed)
36
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
37
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
38
+
39
+ # HTTP header 'Content-Type'
40
+ _header_content_type = []
41
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
42
+
43
+ # form parameters
44
+ form_params = {}
45
+
46
+ # http body (model)
47
+ post_body = nil
48
+
49
+
50
+ response = Swagger::Request.new(:GET, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
51
+
52
+ response.code == 201 ? obj = response.headers['Location'] : (obj = MassPaymentItem.new() and obj.build_from_hash(response.body))
53
+
54
+ end
55
+
56
+ # Get a mass payment's items.
57
+ #
58
+ # @param id Mass payment id to get items for.
59
+ # @param [Hash] opts the optional parameters
60
+ # @option opts [int] :limit How many results to return.
61
+ # @option opts [int] :offset How many results to skip.
62
+ # @option opts [string] :status What status to filter by.
63
+ # @return [MassPaymentItemListResponse]
64
+ def self.get_mass_payment_items(id, opts = {})
65
+
66
+ # verify the required parameter 'id' is set
67
+ raise "Missing the required parameter 'id' when calling get_mass_payment_items" if id.nil?
68
+
69
+
70
+ # resource path
71
+ path = "/mass-payments/{id}/items".sub('{format}','json')
72
+
73
+
74
+ # check if id parameter is resource URI, otherwise substitute for ID
75
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
76
+
77
+
78
+ # query parameters
79
+ query_params = {}
80
+ query_params[:'limit'] = opts[:'limit'] if opts[:'limit']
81
+ query_params[:'offset'] = opts[:'offset'] if opts[:'offset']
82
+ query_params[:'status'] = opts[:'status'] if opts[:'status']
83
+
84
+ # header parameters
85
+ header_params = {}
86
+
87
+ # HTTP header 'Accept' (if needed)
88
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
89
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
90
+
91
+ # HTTP header 'Content-Type'
92
+ _header_content_type = ['application/vnd.dwolla.v1.hal+json']
93
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
94
+
95
+ # form parameters
96
+ form_params = {}
97
+
98
+ # http body (model)
99
+ post_body = nil
100
+
101
+
102
+ response = Swagger::Request.new(:GET, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
103
+
104
+ response.code == 201 ? obj = response.headers['Location'] : (obj = MassPaymentItemListResponse.new() and obj.build_from_hash(response.body))
105
+
106
+ end
107
+ end
108
+ end
@@ -0,0 +1,196 @@
1
+ require 'uri'
2
+
3
+ module DwollaSwagger
4
+ class MasspaymentsApi
5
+ basePath = "https://localhost/"
6
+ # apiInvoker = APIInvoker
7
+ @auth_names = ['oauth2']
8
+
9
+
10
+ # Get an account's mass payments.
11
+ #
12
+ # @param id Account ID
13
+ # @param [Hash] opts the optional parameters
14
+ # @option opts [int] :limit How many results to return.
15
+ # @option opts [int] :offset How many results to skip.
16
+ # @return [MassPaymentListResponse]
17
+ def self.get_by_account(id, opts = {})
18
+
19
+ # verify the required parameter 'id' is set
20
+ raise "Missing the required parameter 'id' when calling get_by_account" if id.nil?
21
+
22
+
23
+ # resource path
24
+ path = "/accounts/{id}/mass-payments".sub('{format}','json')
25
+
26
+
27
+ # check if id parameter is resource URI, otherwise substitute for ID
28
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
29
+
30
+
31
+ # query parameters
32
+ query_params = {}
33
+ query_params[:'limit'] = opts[:'limit'] if opts[:'limit']
34
+ query_params[:'offset'] = opts[:'offset'] if opts[:'offset']
35
+
36
+ # header parameters
37
+ header_params = {}
38
+
39
+ # HTTP header 'Accept' (if needed)
40
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
41
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
42
+
43
+ # HTTP header 'Content-Type'
44
+ _header_content_type = []
45
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
46
+
47
+ # form parameters
48
+ form_params = {}
49
+
50
+ # http body (model)
51
+ post_body = nil
52
+
53
+
54
+ response = Swagger::Request.new(:GET, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
55
+
56
+ response.code == 201 ? obj = response.headers['Location'] : (obj = MassPaymentListResponse.new() and obj.build_from_hash(response.body))
57
+
58
+ end
59
+
60
+ # Get a customer's mass payments.
61
+ #
62
+ # @param id Customer ID
63
+ # @param [Hash] opts the optional parameters
64
+ # @option opts [int] :limit How many results to return.
65
+ # @option opts [int] :offset How many results to skip.
66
+ # @return [MassPaymentListResponse]
67
+ def self.get_by_customer(id, opts = {})
68
+
69
+ # verify the required parameter 'id' is set
70
+ raise "Missing the required parameter 'id' when calling get_by_customer" if id.nil?
71
+
72
+
73
+ # resource path
74
+ path = "/customers/{id}/mass-payments".sub('{format}','json')
75
+
76
+
77
+ # check if id parameter is resource URI, otherwise substitute for ID
78
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
79
+
80
+
81
+ # query parameters
82
+ query_params = {}
83
+ query_params[:'limit'] = opts[:'limit'] if opts[:'limit']
84
+ query_params[:'offset'] = opts[:'offset'] if opts[:'offset']
85
+
86
+ # header parameters
87
+ header_params = {}
88
+
89
+ # HTTP header 'Accept' (if needed)
90
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
91
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
92
+
93
+ # HTTP header 'Content-Type'
94
+ _header_content_type = []
95
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
96
+
97
+ # form parameters
98
+ form_params = {}
99
+
100
+ # http body (model)
101
+ post_body = nil
102
+
103
+
104
+ response = Swagger::Request.new(:GET, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
105
+
106
+ response.code == 201 ? obj = response.headers['Location'] : (obj = MassPaymentListResponse.new() and obj.build_from_hash(response.body))
107
+
108
+ end
109
+
110
+ # Create a new mass payment.
111
+ #
112
+ # @param [Hash] opts the optional parameters
113
+ # @option opts [MassPaymentRequestBody] :body Mass payment request.
114
+ # @return [Unit]
115
+ def self.create(opts = {})
116
+
117
+
118
+ # resource path
119
+ path = "/mass-payments".sub('{format}','json')
120
+
121
+
122
+
123
+ # query parameters
124
+ query_params = {}
125
+
126
+ # header parameters
127
+ header_params = {}
128
+
129
+ # HTTP header 'Accept' (if needed)
130
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
131
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
132
+
133
+ # HTTP header 'Content-Type'
134
+ _header_content_type = ['application/vnd.dwolla.v1.hal+json']
135
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
136
+
137
+ # form parameters
138
+ form_params = {}
139
+
140
+ # http body (model)
141
+ post_body = Swagger::Request.object_to_http_body(opts[:'body'])
142
+
143
+
144
+ response = Swagger::Request.new(:POST, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
145
+
146
+ response.code == 201 ? obj = response.headers['Location'] : (obj = Unit.new() and obj.build_from_hash(response.body))
147
+
148
+ end
149
+
150
+ # Get a mass payment by id.
151
+ #
152
+ # @param id ID of mass payment to get.
153
+ # @param [Hash] opts the optional parameters
154
+ # @return [MassPayment]
155
+ def self.by_id(id, opts = {})
156
+
157
+ # verify the required parameter 'id' is set
158
+ raise "Missing the required parameter 'id' when calling by_id" if id.nil?
159
+
160
+
161
+ # resource path
162
+ path = "/mass-payments/{id}".sub('{format}','json')
163
+
164
+
165
+ # check if id parameter is resource URI, otherwise substitute for ID
166
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
167
+
168
+
169
+ # query parameters
170
+ query_params = {}
171
+
172
+ # header parameters
173
+ header_params = {}
174
+
175
+ # HTTP header 'Accept' (if needed)
176
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
177
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
178
+
179
+ # HTTP header 'Content-Type'
180
+ _header_content_type = []
181
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
182
+
183
+ # form parameters
184
+ form_params = {}
185
+
186
+ # http body (model)
187
+ post_body = nil
188
+
189
+
190
+ response = Swagger::Request.new(:GET, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
191
+
192
+ response.code == 201 ? obj = response.headers['Location'] : (obj = MassPayment.new() and obj.build_from_hash(response.body))
193
+
194
+ end
195
+ end
196
+ end
@@ -0,0 +1,49 @@
1
+ require 'uri'
2
+
3
+ module DwollaSwagger
4
+ class OndemandauthorizationsApi
5
+ basePath = "https://localhost/"
6
+ # apiInvoker = APIInvoker
7
+ @auth_names = ['oauth2']
8
+
9
+
10
+ # Create a new on-demand authorization.
11
+ #
12
+ # @param [Hash] opts the optional parameters
13
+ # @return [Authorization]
14
+ def self.create_authorization(opts = {})
15
+
16
+
17
+ # resource path
18
+ path = "/on-demand-authorizations".sub('{format}','json')
19
+
20
+
21
+
22
+ # query parameters
23
+ query_params = {}
24
+
25
+ # header parameters
26
+ header_params = {}
27
+
28
+ # HTTP header 'Accept' (if needed)
29
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
30
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
31
+
32
+ # HTTP header 'Content-Type'
33
+ _header_content_type = ['application/vnd.dwolla.v1.hal+json']
34
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
35
+
36
+ # form parameters
37
+ form_params = {}
38
+
39
+ # http body (model)
40
+ post_body = nil
41
+
42
+
43
+ response = Swagger::Request.new(:POST, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
44
+
45
+ response.code == 201 ? obj = response.headers['Location'] : (obj = Authorization.new() and obj.build_from_hash(response.body))
46
+
47
+ end
48
+ end
49
+ end
@@ -9,7 +9,7 @@ module DwollaSwagger
9
9
 
10
10
  # Get an account's transfers.
11
11
  #
12
- # @param id Account UUID to get transfers for.
12
+ # @param id Account id to get transfers for.
13
13
  # @param [Hash] opts the optional parameters
14
14
  # @option opts [int] :limit How many results to return.
15
15
  # @option opts [int] :offset How many results to skip.
@@ -59,7 +59,7 @@ module DwollaSwagger
59
59
 
60
60
  # Get a customer's transfers.
61
61
  #
62
- # @param id Customer UUID to get transfers for.
62
+ # @param id Customer id to get transfers for.
63
63
  # @param [Hash] opts the optional parameters
64
64
  # @option opts [int] :limit How many results to return.
65
65
  # @option opts [int] :offset How many results to skip.
@@ -193,6 +193,53 @@ module DwollaSwagger
193
193
 
194
194
  end
195
195
 
196
+ # Update a transfer.
197
+ #
198
+ # @param id ID of transfer to get.
199
+ # @param [Hash] opts the optional parameters
200
+ # @option opts [UpdateTransfer] :body Transfer to update.
201
+ # @return [Transfer]
202
+ def self.update(id, opts = {})
203
+
204
+ # verify the required parameter 'id' is set
205
+ raise "Missing the required parameter 'id' when calling update" if id.nil?
206
+
207
+
208
+ # resource path
209
+ path = "/transfers/{id}".sub('{format}','json')
210
+
211
+
212
+ # check if id parameter is resource URI, otherwise substitute for ID
213
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
214
+
215
+
216
+ # query parameters
217
+ query_params = {}
218
+
219
+ # header parameters
220
+ header_params = {}
221
+
222
+ # HTTP header 'Accept' (if needed)
223
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
224
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
225
+
226
+ # HTTP header 'Content-Type'
227
+ _header_content_type = ['application/vnd.dwolla.v1.hal+json']
228
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
229
+
230
+ # form parameters
231
+ form_params = {}
232
+
233
+ # http body (model)
234
+ post_body = Swagger::Request.object_to_http_body(opts[:'body'])
235
+
236
+
237
+ response = Swagger::Request.new(:POST, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
238
+
239
+ response.code == 201 ? obj = response.headers['Location'] : (obj = Transfer.new() and obj.build_from_hash(response.body))
240
+
241
+ end
242
+
196
243
  # Get a bank transfer failure by transfer id.
197
244
  #
198
245
  # @param id ID of failed bank transfer to get.
@@ -238,5 +285,51 @@ module DwollaSwagger
238
285
  response.code == 201 ? obj = response.headers['Location'] : (obj = Transfer.new() and obj.build_from_hash(response.body))
239
286
 
240
287
  end
288
+
289
+ # Get a transfer's fees.
290
+ #
291
+ # @param id Transfer id to get fees for.
292
+ # @param [Hash] opts the optional parameters
293
+ # @return [TransferListResponse]
294
+ def self.get_fees_by_source(id, opts = {})
295
+
296
+ # verify the required parameter 'id' is set
297
+ raise "Missing the required parameter 'id' when calling get_fees_by_source" if id.nil?
298
+
299
+
300
+ # resource path
301
+ path = "/transfers/{id}/fees".sub('{format}','json')
302
+
303
+
304
+ # check if id parameter is resource URI, otherwise substitute for ID
305
+ path = id =~ URI::regexp ? path.sub('{' + 'id' + '}', id.split('/')[-1].to_s) : path.sub('{' + 'id' + '}', id.to_s)
306
+
307
+
308
+ # query parameters
309
+ query_params = {}
310
+
311
+ # header parameters
312
+ header_params = {}
313
+
314
+ # HTTP header 'Accept' (if needed)
315
+ _header_accept = ['application/vnd.dwolla.v1.hal+json']
316
+ _header_accept_result = Swagger::Request.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
317
+
318
+ # HTTP header 'Content-Type'
319
+ _header_content_type = ['application/vnd.dwolla.v1.hal+json']
320
+ header_params['Content-Type'] = Swagger::Request.select_header_content_type(_header_content_type)
321
+
322
+ # form parameters
323
+ form_params = {}
324
+
325
+ # http body (model)
326
+ post_body = nil
327
+
328
+
329
+ response = Swagger::Request.new(:GET, path, {:params => query_params, :headers => header_params, :form_params => form_params, :body => post_body, :auth_names => @auth_names}).make
330
+
331
+ response.code == 201 ? obj = response.headers['Location'] : (obj = TransferListResponse.new() and obj.build_from_hash(response.body))
332
+
333
+ end
241
334
  end
242
335
  end