revo-loans_api 0.0.4 → 0.0.7

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: 627c8ee996c8b365402eb708b4a85d20e8df58b3a5ed4f491ff682c2b4d074b0
4
- data.tar.gz: a72213f6e01273763deefe4bbed2d5bf23de2d4d48732df640c1c45b6bd25f80
3
+ metadata.gz: 42037b1b0b7a36cd1e24c0bcae6a3c530704fb9e0c1d7391badd901b78d49a0e
4
+ data.tar.gz: '04967e25561ba10bfc5a963e2377e23bf65a822ebfdd38ede6f07605652da9e3'
5
5
  SHA512:
6
- metadata.gz: b738a3cc8438d6ac1460e45ef850ea867df3aa61db30e4c30d59451eb7f7cf44f57fcfa7cbf2cb8db4775bcab00435cce9a0658b55c4793268feed7c474c6701
7
- data.tar.gz: a220277e10e3e458c0d47bbe45cf8835fe91aff784f93c061ac6fd9d10fb5a85a63d4a9296855c479865d8bb43e74edea4393bb9ee4ef37da0ae73458db62043
6
+ metadata.gz: 1e35433067f7cf5c10af3e1e59e6a1be1012d392255d2ff6369102bdace33ffe0a2ab6d2cf290b8ad616170d8d5be4c3d85e9dcaa11225d0e62c96ae26cf223f
7
+ data.tar.gz: a8b81f6be52bda5d1902664a75846bd348ece0f15777060aea7de532ba804b87ad72c82e47b33e0461160f48f7191c7d5bf74acc605d2adff4c0794c89758447
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- revo-loans_api (0.0.4)
4
+ revo-loans_api (0.0.7)
5
5
  activesupport
6
6
  http
7
7
 
data/README.md CHANGED
@@ -425,6 +425,28 @@ result.response # =>
425
425
  # }
426
426
  ```
427
427
 
428
+ ### Patch client data
429
+
430
+
431
+ ```ruby
432
+ result = client.update_client(
433
+ id: '123', # use the one you got when creating a client
434
+ client_params: {
435
+ mobile_phone: '8881234567',
436
+ email: 'user@example.com'
437
+ }
438
+ }
439
+ )
440
+
441
+ # Success:
442
+ result.success? # => true
443
+ result.response # => `nil`
444
+
445
+ # Failure:
446
+ result.success? # => false
447
+ result.response # => `{ errors: { mobile_phone: ['error'] } }`
448
+ ```
449
+
428
450
 
429
451
  ### Possible Exceptions
430
452
 
@@ -124,6 +124,18 @@ class Revo::LoansApi::Client
124
124
  client: client_params, provider_data: provider_data)
125
125
  end
126
126
 
127
+ def update_client(id:, client_params:)
128
+ make_request(:patch, "/clients/#{id}", client: client_params)
129
+ end
130
+
131
+ def create_virtual_card(token:)
132
+ make_request(:post, "loan_requests/#{token}/virtual_card")
133
+ end
134
+
135
+ def create_card_loan(token:, term_id:)
136
+ make_request(:post, "loan_requests/#{token}/card_loan", term_id: term_id)
137
+ end
138
+
127
139
  private
128
140
 
129
141
  attr_reader :connection, :base_url, :login, :password
@@ -1,5 +1,5 @@
1
1
  module Revo
2
2
  module LoansApi
3
- VERSION = '0.0.4'
3
+ VERSION = '0.0.7'
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.4
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Revo Developers
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-11-22 00:00:00.000000000 Z
11
+ date: 2019-12-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: http