youlend 1.1.3 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +12 -0
- data/Gemfile.lock +8 -16
- data/bin/console +1 -0
- data/lib/youlend/auth.rb +1 -4
- data/lib/youlend/configuration.rb +3 -3
- data/lib/youlend/connection.rb +21 -3
- data/lib/youlend/lead.rb +12 -9
- data/lib/youlend/params_generators/lead.rb +4 -2
- data/lib/youlend/params_generators/significant_persons.rb +42 -0
- data/lib/youlend/significant_persons.rb +9 -0
- data/lib/youlend/version.rb +1 -1
- data/lib/youlend.rb +1 -0
- data/vcr_cassettes/auth_onboarding_correct.yml +1 -1
- data/vcr_cassettes/auth_prequalification_correct.yml +1 -1
- data/vcr_cassettes/lead_create_correct.yml +62 -60
- data/vcr_cassettes/lead_create_incorrect.yml +18 -139
- data/vcr_cassettes/lead_details_incomplete.yml +47 -0
- data/vcr_cassettes/lead_details_submitted.yml +167 -0
- data/vcr_cassettes/lead_update_correct.yml +170 -0
- data/vcr_cassettes/pre_qualification_incomplete.yml +1 -1
- data/vcr_cassettes/prequalification_correct.yml +3 -3
- data/vcr_cassettes/prequalification_incorrect.yml +3 -3
- data/vcr_cassettes/prequalification_rejection.yml +3 -3
- data/vcr_cassettes/significant_persons_create_correct.yml +170 -0
- data/vcr_cassettes/significant_persons_create_incorrect.yml +47 -0
- data/youlend.gemspec +1 -15
- metadata +17 -192
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d49a303159c04ab41c25871153190bf3d803f9b357f8669d173447618b1d519f
|
4
|
+
data.tar.gz: ebcf5d73e32ee6bb28e53bda0b649021aa70bf660b6d02881587a11cea655b30
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a8286f24802c2d337cae26882d1da002adb01c3835ab21f76927ee31040caf9c8649e1737da3024b3f618f5b26ddbb51acca7087be1b772040f3feb45106fbd
|
7
|
+
data.tar.gz: a462b275e338259f074c5bafff7c2e30e7e92b9ec022f1ada3f5b159647485bdf0cb4797eabc033400ece5bb90e846f0d541dfd6a99f6a86c02d40c253149adb
|
data/Gemfile
CHANGED
@@ -4,3 +4,15 @@ source 'https://rubygems.org'
|
|
4
4
|
|
5
5
|
# Specify your gem's dependencies in youlend.gemspec
|
6
6
|
gemspec
|
7
|
+
|
8
|
+
# Development dependencies
|
9
|
+
gem 'dotenv'
|
10
|
+
gem 'faker'
|
11
|
+
gem 'pry-byebug'
|
12
|
+
gem 'rake', '~> 10.0'
|
13
|
+
gem 'rspec', '~> 3.0'
|
14
|
+
gem 'rubocop'
|
15
|
+
gem 'rubocop-rspec'
|
16
|
+
gem 'simplecov'
|
17
|
+
gem 'vcr'
|
18
|
+
gem 'webmock'
|
data/Gemfile.lock
CHANGED
@@ -1,11 +1,9 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
youlend (1.
|
4
|
+
youlend (1.2.0)
|
5
5
|
addressable
|
6
|
-
faraday
|
7
|
-
faraday_middleware
|
8
|
-
multi_json
|
6
|
+
faraday (~> 2.7)
|
9
7
|
rainbow
|
10
8
|
|
11
9
|
GEM
|
@@ -24,20 +22,15 @@ GEM
|
|
24
22
|
dotenv (2.7.5)
|
25
23
|
faker (2.11.0)
|
26
24
|
i18n (>= 1.6, < 2)
|
27
|
-
faraday (
|
28
|
-
faraday-net_http (
|
29
|
-
|
30
|
-
|
31
|
-
faraday-net_http (1.0.1)
|
32
|
-
faraday_middleware (1.0.0)
|
33
|
-
faraday (~> 1.0)
|
25
|
+
faraday (2.7.10)
|
26
|
+
faraday-net_http (>= 2.0, < 3.1)
|
27
|
+
ruby2_keywords (>= 0.0.4)
|
28
|
+
faraday-net_http (3.0.2)
|
34
29
|
hashdiff (1.0.1)
|
35
30
|
i18n (1.8.5)
|
36
31
|
concurrent-ruby (~> 1.0)
|
37
32
|
jaro_winkler (1.5.4)
|
38
33
|
method_source (1.0.0)
|
39
|
-
multi_json (1.15.0)
|
40
|
-
multipart-post (2.1.1)
|
41
34
|
parallel (1.19.1)
|
42
35
|
parser (2.7.1.2)
|
43
36
|
ast (~> 2.4.0)
|
@@ -75,7 +68,7 @@ GEM
|
|
75
68
|
rubocop-rspec (1.39.0)
|
76
69
|
rubocop (>= 0.68.1)
|
77
70
|
ruby-progressbar (1.10.1)
|
78
|
-
ruby2_keywords (0.0.
|
71
|
+
ruby2_keywords (0.0.5)
|
79
72
|
safe_yaml (1.0.5)
|
80
73
|
simplecov (0.18.5)
|
81
74
|
docile (~> 1.1)
|
@@ -92,7 +85,6 @@ PLATFORMS
|
|
92
85
|
ruby
|
93
86
|
|
94
87
|
DEPENDENCIES
|
95
|
-
bundler
|
96
88
|
dotenv
|
97
89
|
faker
|
98
90
|
pry-byebug
|
@@ -106,4 +98,4 @@ DEPENDENCIES
|
|
106
98
|
youlend!
|
107
99
|
|
108
100
|
BUNDLED WITH
|
109
|
-
2.
|
101
|
+
2.3.10
|
data/bin/console
CHANGED
data/lib/youlend/auth.rb
CHANGED
@@ -1,8 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require 'multi_json'
|
4
3
|
require 'faraday'
|
5
|
-
require 'faraday_middleware'
|
6
4
|
require 'addressable'
|
7
5
|
|
8
6
|
module Youlend
|
@@ -34,7 +32,7 @@ module Youlend
|
|
34
32
|
grant_type: 'client_credentials',
|
35
33
|
client_id: client_id,
|
36
34
|
client_secret: client_secret,
|
37
|
-
audience: "#{Youlend.configuration.
|
35
|
+
audience: "#{Youlend.configuration.domain}/#{audience}"
|
38
36
|
}
|
39
37
|
|
40
38
|
result = adapter.post('/oauth/token', params.to_json)
|
@@ -54,7 +52,6 @@ module Youlend
|
|
54
52
|
Faraday.new(url: auth_url) do |conn|
|
55
53
|
conn.headers['Content-Type'] = 'application/json'
|
56
54
|
conn.headers['User-Agent'] = "ruby-youlend-#{VERSION}"
|
57
|
-
conn.use FaradayMiddleware::ParseJson
|
58
55
|
conn.response :json, parser_options: { symbolize_names: true }
|
59
56
|
conn.response :logger if Youlend.configuration.debug?
|
60
57
|
conn.adapter Faraday.default_adapter
|
@@ -6,13 +6,13 @@ module Youlend
|
|
6
6
|
attr_writer :debug
|
7
7
|
|
8
8
|
DOMAINS = {
|
9
|
-
production: 'https://
|
10
|
-
development: 'https://staging.
|
9
|
+
production: 'https://youlendapi.com',
|
10
|
+
development: 'https://staging.youlendapi.com'
|
11
11
|
}.freeze
|
12
12
|
|
13
13
|
API_DOMAINS = {
|
14
14
|
production: 'https://youlendapi.com',
|
15
|
-
development: 'https://staging
|
15
|
+
development: 'https://partners.staging-youlendapi.com'
|
16
16
|
}.freeze
|
17
17
|
|
18
18
|
def initialize
|
data/lib/youlend/connection.rb
CHANGED
@@ -1,7 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require 'faraday'
|
4
|
-
require 'faraday_middleware'
|
5
4
|
require 'rainbow'
|
6
5
|
require 'addressable'
|
7
6
|
|
@@ -13,6 +12,12 @@ module Youlend
|
|
13
12
|
BASE_PATH = '/'
|
14
13
|
|
15
14
|
def with_token_refresh(audience)
|
15
|
+
if token_for(audience).to_s.empty?
|
16
|
+
log "Refreshing outdated token... #{Youlend.configuration.tokens[audience]}"
|
17
|
+
|
18
|
+
Auth.request_token(audience)
|
19
|
+
end
|
20
|
+
|
16
21
|
http_response = yield
|
17
22
|
|
18
23
|
response = Response.new(http_response)
|
@@ -40,6 +45,16 @@ module Youlend
|
|
40
45
|
Response.new(http_response)
|
41
46
|
end
|
42
47
|
|
48
|
+
def put(path, audience, params = {})
|
49
|
+
log "PUT: #{params.inspect}"
|
50
|
+
|
51
|
+
http_response = with_token_refresh(audience) do
|
52
|
+
adapter(audience).put(PathSanitizer.sanitize(path), params.to_json)
|
53
|
+
end
|
54
|
+
|
55
|
+
Response.new(http_response)
|
56
|
+
end
|
57
|
+
|
43
58
|
def get(path, audience)
|
44
59
|
http_response = with_token_refresh(audience) do
|
45
60
|
adapter(audience).get(PathSanitizer.sanitize(path))
|
@@ -60,14 +75,17 @@ module Youlend
|
|
60
75
|
Addressable::URI.join(Youlend.configuration.api_domain, BASE_PATH).to_s
|
61
76
|
end
|
62
77
|
|
78
|
+
def token_for(audience)
|
79
|
+
Youlend.configuration.tokens[audience]
|
80
|
+
end
|
81
|
+
|
63
82
|
def adapter(audience)
|
64
|
-
token =
|
83
|
+
token = token_for(audience)
|
65
84
|
|
66
85
|
Faraday.new(url: base_url) do |conn|
|
67
86
|
conn.headers['Authorization'] = "Bearer #{token}" unless token.to_s.empty?
|
68
87
|
conn.headers['Content-Type'] = 'application/json'
|
69
88
|
conn.headers['User-Agent'] = "ruby-youlend-#{VERSION}"
|
70
|
-
conn.use FaradayMiddleware::ParseJson
|
71
89
|
conn.response :json, parser_options: { symbolize_names: true }
|
72
90
|
conn.response :logger if Youlend.configuration.debug?
|
73
91
|
conn.adapter Faraday.default_adapter
|
data/lib/youlend/lead.rb
CHANGED
@@ -1,23 +1,26 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
# Following the API description here: https://
|
3
|
+
# Following the API description here: https://docs.youlend.com/reference/onboarding-intro
|
4
4
|
module Youlend
|
5
5
|
class Lead
|
6
6
|
def self.create(params)
|
7
|
-
|
7
|
+
Youlend.connection.post('/onboarding/Leads', :onboarding, params)
|
8
8
|
end
|
9
9
|
|
10
|
-
def
|
11
|
-
|
12
|
-
@params = params
|
10
|
+
def self.update(lead_id, params)
|
11
|
+
Youlend.connection.put("/onboarding/Leads/#{lead_id}/organisationdetails", :onboarding, params)
|
13
12
|
end
|
14
13
|
|
15
|
-
def
|
16
|
-
Youlend.connection.
|
14
|
+
def self.details(lead_id)
|
15
|
+
Youlend.connection.get("/onboarding/Leads/#{lead_id}/details", :onboarding)
|
17
16
|
end
|
18
17
|
|
19
|
-
def self.
|
20
|
-
Youlend.connection.get("/onboarding/Leads/#{lead_id}", :onboarding)
|
18
|
+
def self.offers(lead_id)
|
19
|
+
Youlend.connection.get("/onboarding/Leads/#{lead_id}/offers", :onboarding)
|
20
|
+
end
|
21
|
+
|
22
|
+
def self.accept_offer(lead_id, offer_id)
|
23
|
+
Youlend.connection.post("/onboarding/Leads/#{lead_id}/offers/#{offer_id}/acceptance", :onboarding)
|
21
24
|
end
|
22
25
|
|
23
26
|
def self.onboard_link(lead_id, email_address)
|
@@ -34,14 +34,16 @@ module Youlend
|
|
34
34
|
companyType: 'ltd',
|
35
35
|
monthsTrading: rand(3..10),
|
36
36
|
countryISOCode: 'GBR',
|
37
|
+
country: 'GBR',
|
37
38
|
keyContactName: Faker::Name.name,
|
38
39
|
thirdPartyLeadId: SecureRandom.uuid,
|
39
40
|
registeredAddress: address,
|
40
41
|
contactPhoneNumber: Faker::PhoneNumber.phone_number,
|
41
|
-
monthlyCardRevenue: 10_000,
|
42
|
+
# monthlyCardRevenue: 10_000,
|
42
43
|
contactEmailAddress: Faker::Internet.email,
|
43
44
|
loanCurrencyISOCode: 'GBP',
|
44
45
|
thirdPartyCustomerId: SecureRandom.uuid,
|
46
|
+
description: 'desc',
|
45
47
|
companyNumber: '09525857', # optional
|
46
48
|
notificationURL: Faker::Internet.url, # optional
|
47
49
|
thirdPartyMerchantId: SecureRandom.uuid # optional
|
@@ -57,7 +59,7 @@ module Youlend
|
|
57
59
|
city: 'London',
|
58
60
|
region: 'London',
|
59
61
|
areaCode: Faker::Address.zip_code,
|
60
|
-
country: '
|
62
|
+
country: 'GBR'
|
61
63
|
}
|
62
64
|
end
|
63
65
|
end
|
@@ -0,0 +1,42 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'faker'
|
4
|
+
|
5
|
+
module Youlend
|
6
|
+
module ParamsGenerators
|
7
|
+
class SignificantPersons
|
8
|
+
def self.generate
|
9
|
+
new.generate
|
10
|
+
end
|
11
|
+
|
12
|
+
def generate
|
13
|
+
{
|
14
|
+
significantPersons: [
|
15
|
+
{
|
16
|
+
typeOfPerson: 'Director',
|
17
|
+
address: {
|
18
|
+
line1: Faker::Address.street_address,
|
19
|
+
line2: Faker::Address.secondary_address,
|
20
|
+
city: 'London',
|
21
|
+
region: 'London',
|
22
|
+
areaCode: Faker::Address.zip_code,
|
23
|
+
country: 'GBR'
|
24
|
+
},
|
25
|
+
dateOfBirth: {
|
26
|
+
year: 2000,
|
27
|
+
month: 1,
|
28
|
+
day: 1
|
29
|
+
},
|
30
|
+
firstName: Faker::Name.first_name,
|
31
|
+
surname: Faker::Name.last_name,
|
32
|
+
emailAddress: Faker::Internet.email,
|
33
|
+
mobilePhoneNumber: Faker::PhoneNumber.phone_number,
|
34
|
+
percentageOwned: rand(10..80),
|
35
|
+
nationality: Faker::Nation.nationality
|
36
|
+
}
|
37
|
+
]
|
38
|
+
}
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
data/lib/youlend/version.rb
CHANGED
data/lib/youlend.rb
CHANGED
@@ -80,7 +80,7 @@ http_interactions:
|
|
80
80
|
- h3-27=":443"; ma=86400, h3-28=":443"; ma=86400, h3-29=":443"; ma=86400
|
81
81
|
body:
|
82
82
|
encoding: ASCII-8BIT
|
83
|
-
string: '{"access_token":"
|
83
|
+
string: '{"access_token":"eyJhbGciOiJSUzI1NiIsInR5cdI6IkcXVCIsImtpZCI6Ik0wUXdOMEl5TnpRMVJrRXhNa1pGTlVWRU5UQTJ","expires_in":86400,"token_type":"Bearer"}'
|
84
84
|
http_version:
|
85
85
|
recorded_at: Tue, 02 Feb 2021 13:24:57 GMT
|
86
86
|
recorded_with: VCR 5.0.0
|
@@ -80,7 +80,7 @@ http_interactions:
|
|
80
80
|
- h3-27=":443"; ma=86400, h3-28=":443"; ma=86400, h3-29=":443"; ma=86400
|
81
81
|
body:
|
82
82
|
encoding: ASCII-8BIT
|
83
|
-
string: '{"access_token":"
|
83
|
+
string: '{"access_token":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6Ik0wUXdOMEl5TnpRMVJrRXhNa1pGTlVWRU5UQTJ","expires_in":86400,"token_type":"Bearer"}'
|
84
84
|
http_version:
|
85
85
|
recorded_at: Tue, 02 Feb 2021 13:24:56 GMT
|
86
86
|
recorded_with: VCR 5.0.0
|
@@ -2,18 +2,18 @@
|
|
2
2
|
http_interactions:
|
3
3
|
- request:
|
4
4
|
method: post
|
5
|
-
uri: https://staging
|
5
|
+
uri: https://partners.staging-youlendapi.com/onboarding/Leads/
|
6
6
|
body:
|
7
7
|
encoding: UTF-8
|
8
|
-
string: '{"companyName":"HOKO LTD","companyType":"ltd","monthsTrading":6,"countryISOCode":"GBR","keyContactName":"
|
9
|
-
|
10
|
-
|
11
|
-
|
8
|
+
string: '{"companyName":"HOKO LTD","companyType":"ltd","monthsTrading":6,"countryISOCode":"GBR","country":"GBR","keyContactName":"Katharine
|
9
|
+
Cassin","thirdPartyLeadId":"f4a58f1c-bdf6-4a79-adb8-87503e8806de","registeredAddress":{"line1":"340
|
10
|
+
Weissnat Via","line2":"Suite 503","city":"London","region":"London","areaCode":"Y1
|
11
|
+
3UG","country":"GBR"},"contactPhoneNumber":"016977 3530","contactEmailAddress":"michaela_lowe@reilly.org","loanCurrencyISOCode":"GBP","thirdPartyCustomerId":"5454e112-e193-4d37-9b75-37a84f6ff840","description":"desc","companyNumber":"09525857","notificationURL":"http://bogisichhilll.co/ariel","thirdPartyMerchantId":"fff103ea-ee41-4e7b-ba4b-c40c59152187"}'
|
12
12
|
headers:
|
13
13
|
Content-Type:
|
14
14
|
- application/json
|
15
15
|
User-Agent:
|
16
|
-
- ruby-youlend-1.
|
16
|
+
- ruby-youlend-1.1.4
|
17
17
|
Accept-Encoding:
|
18
18
|
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
19
19
|
Accept:
|
@@ -24,22 +24,24 @@ http_interactions:
|
|
24
24
|
message: Unauthorized
|
25
25
|
headers:
|
26
26
|
Date:
|
27
|
-
-
|
27
|
+
- Fri, 19 May 2023 12:20:23 GMT
|
28
|
+
Transfer-Encoding:
|
29
|
+
- chunked
|
30
|
+
Connection:
|
31
|
+
- keep-alive
|
28
32
|
Server:
|
29
33
|
- Microsoft-IIS/10.0
|
30
34
|
Www-Authenticate:
|
31
35
|
- Bearer
|
36
|
+
Strict-Transport-Security:
|
37
|
+
- max-age=63072000; includeSubDomains; preload
|
32
38
|
X-Powered-By:
|
33
39
|
- ASP.NET
|
34
|
-
Transfer-Encoding:
|
35
|
-
- chunked
|
36
|
-
Connection:
|
37
|
-
- keep-alive
|
38
40
|
body:
|
39
41
|
encoding: UTF-8
|
40
42
|
string: ''
|
41
|
-
http_version:
|
42
|
-
recorded_at:
|
43
|
+
http_version:
|
44
|
+
recorded_at: Fri, 19 May 2023 12:20:23 GMT
|
43
45
|
- request:
|
44
46
|
method: post
|
45
47
|
uri: https://youlend-stag.eu.auth0.com/oauth/token
|
@@ -50,7 +52,7 @@ http_interactions:
|
|
50
52
|
Content-Type:
|
51
53
|
- application/json
|
52
54
|
User-Agent:
|
53
|
-
- ruby-youlend-1.
|
55
|
+
- ruby-youlend-1.1.4
|
54
56
|
Accept-Encoding:
|
55
57
|
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
56
58
|
Accept:
|
@@ -61,51 +63,49 @@ http_interactions:
|
|
61
63
|
message: OK
|
62
64
|
headers:
|
63
65
|
Date:
|
64
|
-
-
|
66
|
+
- Fri, 19 May 2023 12:20:23 GMT
|
65
67
|
Content-Type:
|
66
68
|
- application/json
|
67
69
|
Transfer-Encoding:
|
68
70
|
- chunked
|
69
71
|
Connection:
|
70
72
|
- keep-alive
|
73
|
+
Cf-Ray:
|
74
|
+
- 7c9c4b2d4e34b7ef-AMS
|
75
|
+
Cache-Control:
|
76
|
+
- no-store
|
71
77
|
Set-Cookie:
|
72
|
-
- __cf_bm=
|
73
|
-
path=/; expires=
|
78
|
+
- __cf_bm=jDINnLBWOrFxQ.5YDPK5V03hevAyhHlGkjBAtFFhZcs-1684498823-0-AbyyrdPKa5KPVstgW9N0h+KxMoWF305BxbZnw3qco0HDS5G6l6Nnq0WgzNb6lHjvzaHzUjZcqTFDtMF5VbGU7Ws=;
|
79
|
+
path=/; expires=Fri, 19-May-23 12:50:23 GMT; domain=.eu.auth0.com; HttpOnly;
|
74
80
|
Secure; SameSite=None
|
75
|
-
-
|
76
|
-
|
77
|
-
- did=s%3Av0%3A6c84a100-655c-11eb-8d10-33d3d6fc6471.Kdh3t06XUDZxEOxdk9OFK%2Bv0J17CVFQkPJ8Yf0jed7E;
|
78
|
-
Max-Age=31557600; Path=/; Expires=Wed, 02 Feb 2022 19:41:59 GMT; HttpOnly;
|
81
|
+
- did=s%3Av0%3A875ec160-f63f-11ed-9974-dfec3c6254ad.RIGYFkY%2FPHW4jXiRRqqQwVVUv155r4nl%2BFCGyPWvs78;
|
82
|
+
Max-Age=31557600; Path=/; Expires=Sat, 18 May 2024 18:20:23 GMT; HttpOnly;
|
79
83
|
Secure; SameSite=None
|
80
|
-
- did_compat=s%3Av0%
|
81
|
-
Max-Age=31557600; Path=/; Expires=
|
84
|
+
- did_compat=s%3Av0%3A875ec160-f63f-11ed-9974-dfec3c6254ad.RIGYFkY%2FPHW4jXiRRqqQwVVUv155r4nl%2BFCGyPWvs78;
|
85
|
+
Max-Age=31557600; Path=/; Expires=Sat, 18 May 2024 18:20:23 GMT; HttpOnly;
|
82
86
|
Secure
|
83
|
-
Cf-Ray:
|
84
|
-
- 61b45537ce32da72-LIS
|
85
|
-
Cache-Control:
|
86
|
-
- no-store
|
87
87
|
Strict-Transport-Security:
|
88
88
|
- max-age=31536000
|
89
89
|
Vary:
|
90
|
-
- Accept-Encoding
|
90
|
+
- Accept-Encoding, Origin
|
91
91
|
Cf-Cache-Status:
|
92
92
|
- DYNAMIC
|
93
|
-
Cf-Request-Id:
|
94
|
-
- '08049396da0000da7280b5d000000001'
|
95
|
-
Expect-Ct:
|
96
|
-
- max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"
|
97
93
|
Ot-Baggage-Auth0-Request-Id:
|
98
|
-
-
|
94
|
+
- 7c9c4b2d4e34b7ef
|
99
95
|
Ot-Tracer-Sampled:
|
100
96
|
- 'true'
|
101
97
|
Ot-Tracer-Spanid:
|
102
|
-
-
|
98
|
+
- 318b83d557fa7f25
|
103
99
|
Ot-Tracer-Traceid:
|
104
|
-
-
|
100
|
+
- 2b3bff9f0a95f57f
|
105
101
|
Pragma:
|
106
102
|
- no-cache
|
103
|
+
Traceparent:
|
104
|
+
- 00-00000000000000002b3bff9f0a95f57f-318b83d557fa7f25-01
|
105
|
+
Tracestate:
|
106
|
+
- auth0-request-id=7c9c4b2d4e34b7ef,auth0=true
|
107
107
|
X-Auth0-Requestid:
|
108
|
-
-
|
108
|
+
- ae1c9007d2978572e16b
|
109
109
|
X-Content-Type-Options:
|
110
110
|
- nosniff
|
111
111
|
X-Ratelimit-Limit:
|
@@ -113,32 +113,32 @@ http_interactions:
|
|
113
113
|
X-Ratelimit-Remaining:
|
114
114
|
- '29'
|
115
115
|
X-Ratelimit-Reset:
|
116
|
-
- '
|
116
|
+
- '1684498824'
|
117
117
|
Server:
|
118
118
|
- cloudflare
|
119
119
|
Alt-Svc:
|
120
|
-
- h3
|
120
|
+
- h3=":443"; ma=86400, h3-29=":443"; ma=86400
|
121
121
|
body:
|
122
|
-
encoding:
|
123
|
-
string: '{"access_token":"
|
124
|
-
http_version:
|
125
|
-
recorded_at:
|
122
|
+
encoding: UTF-8
|
123
|
+
string: '{"access_token":"<TOKEN>","expires_in":86400,"token_type":"Bearer"}'
|
124
|
+
http_version:
|
125
|
+
recorded_at: Fri, 19 May 2023 12:20:23 GMT
|
126
126
|
- request:
|
127
127
|
method: post
|
128
|
-
uri: https://staging
|
128
|
+
uri: https://partners.staging-youlendapi.com/onboarding/Leads/
|
129
129
|
body:
|
130
130
|
encoding: UTF-8
|
131
|
-
string: '{"companyName":"HOKO LTD","companyType":"ltd","monthsTrading":6,"countryISOCode":"GBR","keyContactName":"
|
132
|
-
|
133
|
-
|
134
|
-
|
131
|
+
string: '{"companyName":"HOKO LTD","companyType":"ltd","monthsTrading":6,"countryISOCode":"GBR","country":"GBR","keyContactName":"Katharine
|
132
|
+
Cassin","thirdPartyLeadId":"f4a58f1c-bdf6-4a79-adb8-87503e8806de","registeredAddress":{"line1":"340
|
133
|
+
Weissnat Via","line2":"Suite 503","city":"London","region":"London","areaCode":"Y1
|
134
|
+
3UG","country":"GBR"},"contactPhoneNumber":"016977 3530","contactEmailAddress":"michaela_lowe@reilly.org","loanCurrencyISOCode":"GBP","thirdPartyCustomerId":"5454e112-e193-4d37-9b75-37a84f6ff840","description":"desc","companyNumber":"09525857","notificationURL":"http://bogisichhilll.co/ariel","thirdPartyMerchantId":"fff103ea-ee41-4e7b-ba4b-c40c59152187"}'
|
135
135
|
headers:
|
136
136
|
Authorization:
|
137
|
-
- Bearer
|
137
|
+
- "<Bearer>"
|
138
138
|
Content-Type:
|
139
139
|
- application/json
|
140
140
|
User-Agent:
|
141
|
-
- ruby-youlend-1.
|
141
|
+
- ruby-youlend-1.1.4
|
142
142
|
Accept-Encoding:
|
143
143
|
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
144
144
|
Accept:
|
@@ -148,23 +148,25 @@ http_interactions:
|
|
148
148
|
code: 200
|
149
149
|
message: OK
|
150
150
|
headers:
|
151
|
-
|
152
|
-
-
|
151
|
+
Date:
|
152
|
+
- Fri, 19 May 2023 12:20:23 GMT
|
153
153
|
Content-Type:
|
154
154
|
- application/json; charset=utf-8
|
155
|
-
Date:
|
156
|
-
- Tue, 02 Feb 2021 13:42:00 GMT
|
157
|
-
Server:
|
158
|
-
- Microsoft-IIS/10.0
|
159
|
-
X-Powered-By:
|
160
|
-
- ASP.NET
|
161
155
|
Transfer-Encoding:
|
162
156
|
- chunked
|
163
157
|
Connection:
|
164
158
|
- keep-alive
|
159
|
+
Server:
|
160
|
+
- Microsoft-IIS/10.0
|
161
|
+
Api-Supported-Versions:
|
162
|
+
- '1.0'
|
163
|
+
Strict-Transport-Security:
|
164
|
+
- max-age=63072000; includeSubDomains; preload
|
165
|
+
X-Powered-By:
|
166
|
+
- ASP.NET
|
165
167
|
body:
|
166
168
|
encoding: UTF-8
|
167
|
-
string: '{"leadId":"
|
168
|
-
http_version:
|
169
|
-
recorded_at:
|
169
|
+
string: '{"leadId":"fd984430-4042-4f32-afb2-35700d1564b2","leadURL":"https://partners.staging-youlend.com/dashboard/youraccount/fd984430-4042-4f32-afb2-35700d1564b2/companydetails","signUpURL":"https://partners.staging-youlend.com/dashboard/youlendapisignup?emailAddress=michaela_lowe%40reilly.org&leadId=fd984430-4042-4f32-afb2-35700d1564b2"}'
|
170
|
+
http_version:
|
171
|
+
recorded_at: Fri, 19 May 2023 12:20:23 GMT
|
170
172
|
recorded_with: VCR 5.0.0
|