revo-loans_api 0.0.27 → 0.0.32

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1e68533af65f3d8af55222f5e4eb39c019558e513ef8f90f0d7634bad7cc2c72
4
- data.tar.gz: ce3d6db2bd91062d5a2cf71bf94e62f71f9cf25f4d8ed4a8f1c53a74ee947608
3
+ metadata.gz: bc51505cc5bc6d5e0efdb8df780d49a1dba82b0e5998ff9b87e00e2ddaa0476d
4
+ data.tar.gz: 9c1c58a64051b289aee20b1f675e32dfdde38aadb01139347a7528318a1e5947
5
5
  SHA512:
6
- metadata.gz: b39470e05666efd995f3d2879be67cb571681e3c6d563173abfacfcac8aa4bcbe31fd06a28ccf69e3dc787bd3803fd15011c6114a5ee5023eb91e642dc338686
7
- data.tar.gz: a77f12622e69e76a58df9a87427f0d21dbc8d50dc28090d17d26ec2d9f476673f3e030317c708f5e28f14a1bdbbf858fdbff2c078f39b74d422383714aae5ec7
6
+ metadata.gz: 2802a89cdd783f76f8797a5f9c8e709d3ec2c58e07e19288a4c938ddf3dea8d3d70c8820883a6be666147d69d3116a85952a939feb84f5018ee5c51891700595
7
+ data.tar.gz: f1728842cf8658893351e65c5b652ec5302de928b6bd9ea3d19501cb76465315cd29f738aac42f2a706d861aa7f3a12c5a906cc69c618ad770b4e8fe79c6e058
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- revo-loans_api (0.0.27)
4
+ revo-loans_api (0.0.29)
5
5
  activesupport
6
6
  http
7
7
 
@@ -225,11 +225,11 @@ class Revo::LoansApi::Client
225
225
  )
226
226
  end
227
227
 
228
- def create_card_loan(token:, term_id:)
228
+ def create_card_loan(token:, term_id:, force_approve: false)
229
229
  make_request(
230
230
  :post,
231
- "loan_requests/#{token}/card_loan",
232
- params: { term_id: term_id },
231
+ "loan_requests/#{token}/virtual_card_loan",
232
+ params: { term_id: term_id, force_approve: force_approve },
233
233
  headers: { 'Application-Source': application_source }
234
234
  )
235
235
  end
@@ -250,6 +250,29 @@ class Revo::LoansApi::Client
250
250
  )
251
251
  end
252
252
 
253
+ def send_restructuring_confirmation_code(client_id:, product:)
254
+ make_request(:post, "clients/#{client_id}/restructuring/#{product}")
255
+ end
256
+
257
+ def restructuring_info(client_id:, product:)
258
+ make_request(:get, "clients/#{client_id}/restructuring/#{product}/info")
259
+ end
260
+
261
+ def confirm_restructuring(client_id:, code:, product:)
262
+ make_request(
263
+ :post,
264
+ "clients/#{client_id}/restructuring/#{product}/confirmation",
265
+ params: { code: code }
266
+ )
267
+ end
268
+
269
+ def restructuring_document(client_id:, product:, format: 'pdf')
270
+ make_request(
271
+ :get,
272
+ "clients/#{client_id}/restructuring/#{product}/document.#{format}"
273
+ )
274
+ end
275
+
253
276
  def increase_client_limit(client_id:, amount:)
254
277
  make_request(
255
278
  :patch,
@@ -344,7 +367,10 @@ class Revo::LoansApi::Client
344
367
  if response.content_type.mime_type == API_CONTENT_TYPE
345
368
  parse(response)
346
369
  else
347
- { errors: { base: [:unexpected_response] } }
370
+ {
371
+ errors: { base: [:unexpected_response] },
372
+ raw_response: response.to_s.presence
373
+ }
348
374
  end
349
375
  end
350
376
 
@@ -1,5 +1,5 @@
1
1
  module Revo
2
2
  module LoansApi
3
- VERSION = '0.0.27'.freeze
3
+ VERSION = '0.0.32'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: revo-loans_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.27
4
+ version: 0.0.32
5
5
  platform: ruby
6
6
  authors:
7
7
  - Revo Developers
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-04-13 00:00:00.000000000 Z
11
+ date: 2020-07-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: http