@blindpay/node 1.1.2 → 2.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.
Files changed (44) hide show
  1. package/dist/{chunk-64EFLUS3.mjs → chunk-CPOSU35L.mjs} +10 -0
  2. package/dist/{chunk-BONN6PYB.mjs → chunk-MPJKYFDD.mjs} +9 -4
  3. package/dist/{chunk-YSH4QGAQ.mjs → chunk-URXUVGMC.mjs} +6 -6
  4. package/dist/index.d.mts +2 -2
  5. package/dist/index.d.ts +2 -2
  6. package/dist/index.js +20 -5
  7. package/dist/index.mjs +6 -6
  8. package/dist/resources/api-keys/api-keys.test.js +20 -5
  9. package/dist/resources/api-keys/api-keys.test.mjs +3 -3
  10. package/dist/resources/available/available.test.js +20 -5
  11. package/dist/resources/available/available.test.mjs +3 -3
  12. package/dist/resources/bank-accounts/bank-accounts.test.js +56 -5
  13. package/dist/resources/bank-accounts/bank-accounts.test.mjs +39 -3
  14. package/dist/resources/bank-accounts/index.d.mts +30 -1
  15. package/dist/resources/bank-accounts/index.d.ts +30 -1
  16. package/dist/resources/bank-accounts/index.js +10 -0
  17. package/dist/resources/bank-accounts/index.mjs +1 -1
  18. package/dist/resources/instances/instances.test.js +20 -5
  19. package/dist/resources/instances/instances.test.mjs +3 -3
  20. package/dist/resources/partner-fees/partner-fees.test.js +20 -5
  21. package/dist/resources/partner-fees/partner-fees.test.mjs +3 -3
  22. package/dist/resources/payins/payins-quotes.test.js +20 -5
  23. package/dist/resources/payins/payins-quotes.test.mjs +3 -3
  24. package/dist/resources/payins/payins.test.js +20 -5
  25. package/dist/resources/payins/payins.test.mjs +3 -3
  26. package/dist/resources/payouts/payouts.test.js +20 -5
  27. package/dist/resources/payouts/payouts.test.mjs +3 -3
  28. package/dist/resources/quotes/quotes.test.js +20 -5
  29. package/dist/resources/quotes/quotes.test.mjs +3 -3
  30. package/dist/resources/receivers/index.d.mts +169 -53
  31. package/dist/resources/receivers/index.d.ts +169 -53
  32. package/dist/resources/receivers/index.js +9 -4
  33. package/dist/resources/receivers/index.mjs +1 -1
  34. package/dist/resources/receivers/receivers.test.js +288 -171
  35. package/dist/resources/receivers/receivers.test.mjs +271 -169
  36. package/dist/resources/virtual-accounts/virtual-accounts.test.js +20 -5
  37. package/dist/resources/virtual-accounts/virtual-accounts.test.mjs +3 -3
  38. package/dist/resources/wallets/blockchain.test.js +20 -5
  39. package/dist/resources/wallets/blockchain.test.mjs +3 -3
  40. package/dist/resources/wallets/offramp.test.js +20 -5
  41. package/dist/resources/wallets/offramp.test.mjs +3 -3
  42. package/dist/resources/webhooks/webhooks.test.js +20 -5
  43. package/dist/resources/webhooks/webhooks.test.mjs +3 -3
  44. package/package.json +1 -1
@@ -8,19 +8,19 @@ import {
8
8
  import {
9
9
  BlindPay,
10
10
  init_client
11
- } from "../../chunk-YSH4QGAQ.mjs";
11
+ } from "../../chunk-URXUVGMC.mjs";
12
12
  import "../../chunk-IZYPRCCV.mjs";
13
13
  import "../../chunk-QGNLMN6Z.mjs";
14
14
  import "../../chunk-UC57SCKQ.mjs";
15
15
  import "../../chunk-TBTA7A2P.mjs";
16
- import "../../chunk-BONN6PYB.mjs";
16
+ import "../../chunk-MPJKYFDD.mjs";
17
17
  import "../../chunk-5XJJKYXE.mjs";
18
+ import "../../chunk-CPOSU35L.mjs";
18
19
  import "../../chunk-RC5NN5UF.mjs";
19
20
  import "../../chunk-W7NJUABI.mjs";
20
21
  import "../../chunk-E7M4CJKR.mjs";
21
22
  import "../../chunk-3QQCDR3E.mjs";
22
23
  import "../../chunk-LRHWT4JU.mjs";
23
- import "../../chunk-64EFLUS3.mjs";
24
24
  import "../../chunk-QHMIK7U3.mjs";
25
25
  import "../../chunk-B5T7AQLH.mjs";
26
26
  import {
@@ -40,7 +40,7 @@ var require_receivers_test = __commonJS({
40
40
  it("should list receivers", () => __async(null, null, function* () {
41
41
  const mockedReceivers = [
42
42
  {
43
- id: "re_000000000000",
43
+ id: "re_Euw7HN4OdxPn",
44
44
  type: "individual",
45
45
  kyc_type: "standard",
46
46
  kyc_status: "verifying",
@@ -52,64 +52,138 @@ var require_receivers_test = __commonJS({
52
52
  warning_id: null
53
53
  }
54
54
  ],
55
- email: "email@example.com",
56
- tax_id: "536804398",
57
- address_line_1: "738 Plain St",
58
- address_line_2: "Building 22",
59
- city: "Marshfield",
60
- state_province_region: "MA",
61
- country: "US",
62
- postal_code: "02050",
55
+ email: "bernardo@gmail.com",
56
+ tax_id: "12345678900",
57
+ address_line_1: "Av. Paulista, 1000",
58
+ address_line_2: "Apto 101",
59
+ city: "S\xE3o Paulo",
60
+ state_province_region: "SP",
61
+ country: "BR",
62
+ postal_code: "01310-100",
63
63
  ip_address: "127.0.0.1",
64
64
  image_url: "https://example.com/image.png",
65
- phone_number: "+1234567890",
65
+ phone_number: "+5511987654321",
66
66
  proof_of_address_doc_type: "UTILITY_BILL",
67
67
  proof_of_address_doc_file: "https://example.com/image.png",
68
- first_name: "John",
69
- last_name: "Doe",
70
- date_of_birth: "1998-01-01T00:00:00Z",
68
+ first_name: "Bernardo",
69
+ last_name: "Simonassi",
70
+ date_of_birth: "1998-02-02T00:00:00.000Z",
71
71
  id_doc_country: "BR",
72
72
  id_doc_type: "PASSPORT",
73
73
  id_doc_front_file: "https://example.com/image.png",
74
74
  id_doc_back_file: "https://example.com/image.png",
75
- legal_name: "Company Name Inc.",
76
- alternate_name: "Company Name Inc.",
77
- formation_date: "1998-01-01T00:00:00Z",
78
- website: "https://example.com",
75
+ aiprise_validation_key: "",
76
+ instance_id: "in_000000000000",
77
+ tos_id: "to_3ZZhllJkvo5Z",
78
+ created_at: "2021-01-01T00:00:00.000Z",
79
+ updated_at: "2021-01-01T00:00:00.000Z",
80
+ limit: {
81
+ per_transaction: 1e5,
82
+ daily: 2e5,
83
+ monthly: 1e6
84
+ }
85
+ },
86
+ {
87
+ id: "re_YuaMcI2B8zbQ",
88
+ type: "individual",
89
+ kyc_type: "enhanced",
90
+ kyc_status: "approved",
91
+ kyc_warnings: null,
92
+ email: "alice.johnson@example.com",
93
+ tax_id: "98765432100",
94
+ address_line_1: "123 Main St",
95
+ address_line_2: null,
96
+ city: "New York",
97
+ state_province_region: "NY",
98
+ country: "US",
99
+ postal_code: "10001",
100
+ ip_address: "192.168.1.1",
101
+ image_url: null,
102
+ phone_number: "+15555555555",
103
+ proof_of_address_doc_type: "BANK_STATEMENT",
104
+ proof_of_address_doc_file: "https://example.com/image.png",
105
+ first_name: "Alice",
106
+ last_name: "Johnson",
107
+ date_of_birth: "1990-05-10T00:00:00.000Z",
108
+ id_doc_country: "US",
109
+ id_doc_type: "PASSPORT",
110
+ id_doc_front_file: "https://example.com/image.png",
111
+ id_doc_back_file: null,
112
+ aiprise_validation_key: "enhanced-key",
113
+ instance_id: "in_000000000001",
114
+ source_of_funds_doc_type: "salary",
115
+ source_of_funds_doc_file: "https://example.com/image.png",
116
+ individual_holding_doc_front_file: "https://example.com/image.png",
117
+ purpose_of_transactions: "investment_purposes",
118
+ purpose_of_transactions_explanation: "Investing in stocks",
119
+ tos_id: "to_nppX66ntvtHs",
120
+ created_at: "2022-02-02T00:00:00.000Z",
121
+ updated_at: "2022-02-02T00:00:00.000Z",
122
+ limit: {
123
+ per_transaction: 5e4,
124
+ daily: 1e5,
125
+ monthly: 5e5
126
+ }
127
+ },
128
+ {
129
+ id: "re_IOxAUL24LG7P",
130
+ type: "business",
131
+ kyc_type: "standard",
132
+ kyc_status: "pending",
133
+ kyc_warnings: null,
134
+ email: "business@example.com",
135
+ tax_id: "20096178000195",
136
+ address_line_1: "1 King St W",
137
+ address_line_2: "Suite 100",
138
+ city: "Toronto",
139
+ state_province_region: "ON",
140
+ country: "CA",
141
+ postal_code: "M5H 1A1",
142
+ ip_address: null,
143
+ image_url: null,
144
+ phone_number: "+14165555555",
145
+ proof_of_address_doc_type: "UTILITY_BILL",
146
+ proof_of_address_doc_file: "https://example.com/image.png",
147
+ legal_name: "Business Corp",
148
+ alternate_name: "BizCo",
149
+ formation_date: "2010-01-01T00:00:00.000Z",
150
+ website: "https://businesscorp.com",
79
151
  owners: [
80
152
  {
81
- id: "ub_000000000000",
82
- first_name: "John",
83
- last_name: "Doe",
84
- address_line_1: "738 Plain St",
85
- address_line_2: "Building 22",
86
- city: "Marshfield",
87
- state_province_region: "MA",
88
- country: "US",
89
- postal_code: "02050",
153
+ role: "beneficial_owner",
154
+ first_name: "Carlos",
155
+ last_name: "Silva",
156
+ date_of_birth: "1995-05-15T00:00:00.000Z",
157
+ tax_id: "12345678901",
158
+ address_line_1: "Rua Augusta, 1500",
159
+ address_line_2: null,
160
+ city: "S\xE3o Paulo",
161
+ state_province_region: "SP",
162
+ country: "BR",
163
+ postal_code: "01304-001",
90
164
  id_doc_country: "BR",
91
165
  id_doc_type: "PASSPORT",
92
166
  id_doc_front_file: "https://example.com/image.png",
93
- id_doc_back_file: "https://example.com/image.png"
167
+ id_doc_back_file: "https://example.com/image.png",
168
+ proof_of_address_doc_type: "UTILITY_BILL",
169
+ proof_of_address_doc_file: "https://example.com/image.png",
170
+ id: "ub_000000000000",
171
+ instance_id: "in_000000000000",
172
+ receiver_id: "re_IOxAUL24LG7P"
94
173
  }
95
174
  ],
96
175
  incorporation_doc_file: "https://example.com/image.png",
97
176
  proof_of_ownership_doc_file: "https://example.com/image.png",
98
- source_of_funds_doc_type: "business_income",
99
- source_of_funds_doc_file: "https://example.com/image.png",
100
- individual_holding_doc_front_file: "https://example.com/image.png",
101
- purpose_of_transactions: "business_transactions",
102
- purpose_of_transactions_explanation: "I am a business owner and I want to receive payments from my customers",
103
- external_id: "your_company_external_id",
104
- instance_id: "in_000000000000",
105
- tos_id: "to_000000000000",
177
+ external_id: null,
178
+ instance_id: "in_000000000002",
179
+ tos_id: "to_nppX66ntvtHs",
106
180
  aiprise_validation_key: "",
107
- created_at: "2021-01-01T00:00:00Z",
108
- updated_at: "2021-01-01T00:00:00Z",
181
+ created_at: "2015-03-15T00:00:00.000Z",
182
+ updated_at: "2015-03-15T00:00:00.000Z",
109
183
  limit: {
110
- per_transaction: 1e5,
111
- daily: 2e5,
112
- monthly: 1e6
184
+ per_transaction: 2e5,
185
+ daily: 4e5,
186
+ monthly: 2e6
113
187
  }
114
188
  }
115
189
  ];
@@ -122,81 +196,134 @@ var require_receivers_test = __commonJS({
122
196
  }));
123
197
  });
124
198
  describe("Create receiver", () => {
125
- const mockedReceiver = {
126
- id: "re_000000000000"
127
- };
128
- it("should create a receiver", () => __async(null, null, function* () {
199
+ it("should create an individual receiver with standard KYC", () => __async(null, null, function* () {
200
+ const mockedReceiver = {
201
+ id: "re_Euw7HN4OdxPn"
202
+ };
129
203
  fetchMock.mockResponseOnce(JSON.stringify(mockedReceiver), {
130
204
  headers: { "Content-Type": "application/json" }
131
205
  });
132
- const { data, error } = yield blindpay.receivers.create({
206
+ const { data, error } = yield blindpay.receivers.createIndividualWithStandardKYC({
133
207
  type: "individual",
134
208
  kyc_type: "standard",
135
- email: "email@example.com",
136
- tax_id: "536804398",
137
- address_line_1: "738 Plain St",
138
- address_line_2: "Building 22",
139
- city: "Marshfield",
140
- state_province_region: "MA",
141
- country: "US",
142
- postal_code: "02050",
143
- ip_address: "127.0.0.1",
144
- image_url: "https://example.com/image.png",
145
- phone_number: "+1234567890",
209
+ email: "bernardo.simonassi@gmail.com",
210
+ tax_id: "12345678900",
211
+ address_line_1: "Av. Paulista, 1000",
212
+ address_line_2: "Apto 101",
213
+ city: "S\xE3o Paulo",
214
+ state_province_region: "SP",
215
+ country: "BR",
216
+ postal_code: "01310-100",
217
+ first_name: "Bernardo",
218
+ last_name: "Simonassi",
219
+ date_of_birth: "1998-02-02T00:00:00.000Z",
220
+ id_doc_country: "BR",
221
+ id_doc_type: "PASSPORT",
222
+ id_doc_front_file: "https://example.com/image.png",
146
223
  proof_of_address_doc_type: "UTILITY_BILL",
147
224
  proof_of_address_doc_file: "https://example.com/image.png",
148
- first_name: "John",
149
- last_name: "Doe",
150
- date_of_birth: "1998-01-01T00:00:00Z",
225
+ tos_id: "to_tPiz4bM2nh5K"
226
+ });
227
+ globalExpect(error).toBeNull();
228
+ globalExpect(data).toEqual({ id: "re_Euw7HN4OdxPn" });
229
+ }));
230
+ it("should create an individual receiver with enhanced KYC", () => __async(null, null, function* () {
231
+ const mockedReceiver = {
232
+ id: "re_YuaMcI2B8zbQ"
233
+ };
234
+ fetchMock.mockResponseOnce(JSON.stringify(mockedReceiver), {
235
+ headers: { "Content-Type": "application/json" }
236
+ });
237
+ const { data, error } = yield blindpay.receivers.createIndividualWithEnhancedKYC({
238
+ type: "individual",
239
+ kyc_type: "enhanced",
240
+ email: "bernardo.simonassi@gmail.com",
241
+ tax_id: "12345678900",
242
+ address_line_1: "Av. Paulista, 1000",
243
+ address_line_2: "Apto 101",
244
+ city: "S\xE3o Paulo",
245
+ state_province_region: "SP",
246
+ country: "BR",
247
+ postal_code: "01310-100",
248
+ first_name: "Bernardo",
249
+ last_name: "Simonassi",
250
+ date_of_birth: "1998-02-02T00:00:00.000Z",
151
251
  id_doc_country: "BR",
152
252
  id_doc_type: "PASSPORT",
153
253
  id_doc_front_file: "https://example.com/image.png",
154
- id_doc_back_file: "https://example.com/image.png",
155
- legal_name: "Company Name Inc.",
156
- alternate_name: "Company Name Inc.",
157
- formation_date: "1998-01-01T00:00:00Z",
158
- website: "https://example.com",
254
+ proof_of_address_doc_type: "UTILITY_BILL",
255
+ proof_of_address_doc_file: "https://example.com/image.png",
256
+ individual_holding_doc_front_file: "https://example.com/image.png",
257
+ purpose_of_transactions: "personal_or_living_expenses",
258
+ source_of_funds_doc_type: "savings",
259
+ source_of_funds_doc_file: "https://example.com/image.png",
260
+ tos_id: "to_3ZZhllJkvo5Z"
261
+ });
262
+ globalExpect(error).toBeNull();
263
+ globalExpect(data).toEqual({ id: "re_YuaMcI2B8zbQ" });
264
+ }));
265
+ it("should create a business receiver with standard KYB", () => __async(null, null, function* () {
266
+ const mockedReceiver = {
267
+ id: "re_IOxAUL24LG7P"
268
+ };
269
+ fetchMock.mockResponseOnce(JSON.stringify(mockedReceiver), {
270
+ headers: { "Content-Type": "application/json" }
271
+ });
272
+ const { data, error } = yield blindpay.receivers.createBusinessWithStandardKYB({
273
+ type: "business",
274
+ kyc_type: "standard",
275
+ email: "contato@empresa.com.br",
276
+ tax_id: "20096178000195",
277
+ address_line_1: "Av. Brigadeiro Faria Lima, 400",
278
+ address_line_2: "Sala 1201",
279
+ city: "S\xE3o Paulo",
280
+ state_province_region: "SP",
281
+ country: "BR",
282
+ postal_code: "04538-132",
283
+ legal_name: "Empresa Exemplo Ltda",
284
+ alternate_name: "Exemplo",
285
+ formation_date: "2010-05-20T00:00:00.000Z",
286
+ incorporation_doc_file: "https://example.com/image.png",
287
+ proof_of_address_doc_type: "UTILITY_BILL",
288
+ proof_of_address_doc_file: "https://example.com/image.png",
289
+ proof_of_ownership_doc_file: "https://example.com/image.png",
290
+ tos_id: "to_nppX66ntvtHs",
291
+ website: "https://site.com/",
159
292
  owners: [
160
293
  {
161
- first_name: "John",
162
- last_name: "Doe",
163
294
  role: "beneficial_owner",
164
- date_of_birth: "1998-01-01T00:00:00Z",
165
- tax_id: "536804398",
166
- address_line_1: "738 Plain St",
167
- address_line_2: "Building 22",
168
- city: "Marshfield",
169
- state_province_region: "MA",
170
- country: "US",
171
- postal_code: "02050",
295
+ first_name: "Carlos",
296
+ last_name: "Silva",
297
+ date_of_birth: "1995-05-15T00:00:00.000Z",
298
+ tax_id: "12345678901",
299
+ address_line_1: "Rua Augusta, 1500",
300
+ address_line_2: null,
301
+ city: "S\xE3o Paulo",
302
+ state_province_region: "SP",
303
+ country: "BR",
304
+ postal_code: "01304-001",
172
305
  id_doc_country: "BR",
173
306
  id_doc_type: "PASSPORT",
174
307
  id_doc_front_file: "https://example.com/image.png",
175
308
  id_doc_back_file: "https://example.com/image.png",
309
+ proof_of_address_doc_type: "UTILITY_BILL",
176
310
  proof_of_address_doc_file: "https://example.com/image.png",
177
- proof_of_address_doc_type: "UTILITY_BILL"
311
+ id: "ub_000000000000",
312
+ instance_id: "in_000000000000",
313
+ receiver_id: "re_IOxAUL24LG7P"
178
314
  }
179
- ],
180
- incorporation_doc_file: "https://example.com/image.png",
181
- proof_of_ownership_doc_file: "https://example.com/image.png",
182
- source_of_funds_doc_type: "business_income",
183
- source_of_funds_doc_file: "https://example.com/image.png",
184
- individual_holding_doc_front_file: "https://example.com/image.png",
185
- purpose_of_transactions: "business_transactions",
186
- purpose_of_transactions_explanation: "I am a business owner and I want to receive payments from my customers",
187
- external_id: "your_company_external_id",
188
- tos_id: "to_000000000000"
315
+ ]
189
316
  });
190
317
  globalExpect(error).toBeNull();
191
- globalExpect(data).toEqual({ id: "re_000000000000" });
318
+ globalExpect(data).toEqual({ id: "re_IOxAUL24LG7P" });
192
319
  }));
193
320
  });
194
321
  describe("Get receiver", () => {
195
322
  it("should get a receiver", () => __async(null, null, function* () {
196
323
  const mockedReceiver = {
197
- id: "re_000000000000",
324
+ id: "re_YuaMcI2B8zbQ",
198
325
  type: "individual",
199
- kyc_type: "standard",
326
+ kyc_type: "enhanced",
200
327
  kyc_status: "verifying",
201
328
  kyc_warnings: [
202
329
  {
@@ -206,60 +333,36 @@ var require_receivers_test = __commonJS({
206
333
  warning_id: null
207
334
  }
208
335
  ],
209
- email: "email@example.com",
210
- tax_id: "536804398",
211
- address_line_1: "738 Plain St",
212
- address_line_2: "Building 22",
213
- city: "Marshfield",
214
- state_province_region: "MA",
215
- country: "US",
216
- postal_code: "02050",
336
+ email: "bernardo.simonassi@gmail.com",
337
+ tax_id: "12345678900",
338
+ address_line_1: "Av. Paulista, 1000",
339
+ address_line_2: "Apto 101",
340
+ city: "S\xE3o Paulo",
341
+ state_province_region: "SP",
342
+ country: "BR",
343
+ postal_code: "01310-100",
217
344
  ip_address: "127.0.0.1",
218
345
  image_url: "https://example.com/image.png",
219
- phone_number: "+1234567890",
346
+ phone_number: "+5511987654321",
220
347
  proof_of_address_doc_type: "UTILITY_BILL",
221
348
  proof_of_address_doc_file: "https://example.com/image.png",
222
- first_name: "John",
223
- last_name: "Doe",
224
- date_of_birth: "1998-01-01T00:00:00Z",
349
+ first_name: "Bernardo",
350
+ last_name: "Simonassi",
351
+ date_of_birth: "1998-02-02T00:00:00.000Z",
225
352
  id_doc_country: "BR",
226
353
  id_doc_type: "PASSPORT",
227
354
  id_doc_front_file: "https://example.com/image.png",
228
355
  id_doc_back_file: "https://example.com/image.png",
229
- legal_name: "Company Name Inc.",
230
- alternate_name: "Company Name Inc.",
231
- formation_date: "1998-01-01T00:00:00Z",
232
- website: "https://example.com",
233
- owners: [
234
- {
235
- id: "ub_000000000000",
236
- first_name: "John",
237
- last_name: "Doe",
238
- address_line_1: "738 Plain St",
239
- address_line_2: "Building 22",
240
- city: "Marshfield",
241
- state_province_region: "MA",
242
- country: "US",
243
- postal_code: "02050",
244
- id_doc_country: "BR",
245
- id_doc_type: "PASSPORT",
246
- id_doc_front_file: "https://example.com/image.png",
247
- id_doc_back_file: "https://example.com/image.png"
248
- }
249
- ],
250
- incorporation_doc_file: "https://example.com/image.png",
251
- proof_of_ownership_doc_file: "https://example.com/image.png",
252
- source_of_funds_doc_type: "business_income",
356
+ aiprise_validation_key: "",
357
+ source_of_funds_doc_type: "savings",
253
358
  source_of_funds_doc_file: "https://example.com/image.png",
254
359
  individual_holding_doc_front_file: "https://example.com/image.png",
255
- purpose_of_transactions: "business_transactions",
256
- purpose_of_transactions_explanation: "I am a business owner and I want to receive payments from my customers",
257
- external_id: "your_company_external_id",
360
+ purpose_of_transactions: "personal_or_living_expenses",
361
+ purpose_of_transactions_explanation: "I am receiving salary payments from my employer",
258
362
  instance_id: "in_000000000000",
259
- tos_id: "to_000000000000",
260
- aiprise_validation_key: "",
261
- created_at: "2021-01-01T00:00:00Z",
262
- updated_at: "2021-01-01T00:00:00Z",
363
+ tos_id: "to_3ZZhllJkvo5Z",
364
+ created_at: "2021-01-01T00:00:00.000Z",
365
+ updated_at: "2021-01-01T00:00:00.000Z",
263
366
  limit: {
264
367
  per_transaction: 1e5,
265
368
  daily: 2e5,
@@ -269,7 +372,7 @@ var require_receivers_test = __commonJS({
269
372
  fetchMock.mockResponseOnce(JSON.stringify(mockedReceiver), {
270
373
  headers: { "Content-Type": "application/json" }
271
374
  });
272
- const { data, error } = yield blindpay.receivers.get("re_000000000000");
375
+ const { data, error } = yield blindpay.receivers.get("re_YuaMcI2B8zbQ");
273
376
  globalExpect(error).toBeNull();
274
377
  globalExpect(data).toEqual(mockedReceiver);
275
378
  }));
@@ -280,45 +383,44 @@ var require_receivers_test = __commonJS({
280
383
  headers: { "Content-Type": "application/json" }
281
384
  });
282
385
  const { data, error } = yield blindpay.receivers.update({
283
- receiver_id: "re_000000000000",
284
- email: "email@example.com",
285
- tax_id: "536804398",
286
- address_line_1: "738 Plain St",
287
- address_line_2: "Building 22",
288
- city: "Marshfield",
289
- state_province_region: "MA",
290
- country: "US",
291
- postal_code: "02050",
386
+ receiver_id: "re_YuaMcI2B8zbQ",
387
+ email: "bernardo.simonassi@gmail.com",
388
+ tax_id: "12345678900",
389
+ address_line_1: "Av. Paulista, 1000",
390
+ address_line_2: "Apto 101",
391
+ city: "S\xE3o Paulo",
392
+ state_province_region: "SP",
393
+ country: "BR",
394
+ postal_code: "01310-100",
292
395
  ip_address: "127.0.0.1",
293
396
  image_url: "https://example.com/image.png",
294
- phone_number: "+1234567890",
397
+ phone_number: "+5511987654321",
295
398
  proof_of_address_doc_type: "UTILITY_BILL",
296
399
  proof_of_address_doc_file: "https://example.com/image.png",
297
- first_name: "John",
298
- last_name: "Doe",
299
- date_of_birth: "1998-01-01T00:00:00Z",
400
+ first_name: "Bernardo",
401
+ last_name: "Simonassi",
402
+ date_of_birth: "1998-02-02T00:00:00.000Z",
300
403
  id_doc_country: "BR",
301
404
  id_doc_type: "PASSPORT",
302
405
  id_doc_front_file: "https://example.com/image.png",
303
406
  id_doc_back_file: "https://example.com/image.png",
304
- legal_name: "Company Name Inc.",
305
- alternate_name: "Company Name Inc.",
306
- formation_date: "1998-01-01T00:00:00Z",
307
- website: "https://example.com",
407
+ alternate_name: "Exemplo",
408
+ formation_date: "2010-05-20T00:00:00.000Z",
409
+ website: "https://site.com",
308
410
  owners: [
309
411
  {
310
412
  id: "ub_000000000000",
311
- first_name: "John",
312
- last_name: "Doe",
413
+ first_name: "Carlos",
414
+ last_name: "Silva",
313
415
  role: "beneficial_owner",
314
- date_of_birth: "1998-01-01T00:00:00Z",
315
- tax_id: "536804398",
316
- address_line_1: "738 Plain St",
317
- address_line_2: "Building 22",
318
- city: "Marshfield",
319
- state_province_region: "MA",
320
- country: "US",
321
- postal_code: "02050",
416
+ date_of_birth: "1995-05-15T00:00:00.000Z",
417
+ tax_id: "12345678901",
418
+ address_line_1: "Rua Augusta, 1500",
419
+ address_line_2: null,
420
+ city: "S\xE3o Paulo",
421
+ state_province_region: "SP",
422
+ country: "BR",
423
+ postal_code: "01304-001",
322
424
  id_doc_country: "BR",
323
425
  id_doc_type: "PASSPORT",
324
426
  id_doc_front_file: "https://example.com/image.png",
@@ -327,13 +429,13 @@ var require_receivers_test = __commonJS({
327
429
  ],
328
430
  incorporation_doc_file: "https://example.com/image.png",
329
431
  proof_of_ownership_doc_file: "https://example.com/image.png",
330
- source_of_funds_doc_type: "business_income",
432
+ source_of_funds_doc_type: "savings",
331
433
  source_of_funds_doc_file: "https://example.com/image.png",
332
434
  individual_holding_doc_front_file: "https://example.com/image.png",
333
- purpose_of_transactions: "business_transactions",
334
- purpose_of_transactions_explanation: "I am a business owner and I want to receive payments from my customers",
335
- external_id: "your_company_external_id",
336
- tos_id: "to_000000000000"
435
+ purpose_of_transactions: "personal_or_living_expenses",
436
+ purpose_of_transactions_explanation: "I am receiving salary payments from my employer",
437
+ external_id: "some-external-id",
438
+ tos_id: "to_3ZZhllJkvo5Z"
337
439
  });
338
440
  globalExpect(error).toBeNull();
339
441
  globalExpect(data).toEqual({ data: null });
@@ -344,7 +446,7 @@ var require_receivers_test = __commonJS({
344
446
  fetchMock.mockResponseOnce(JSON.stringify({ data: null }), {
345
447
  headers: { "Content-Type": "application/json" }
346
448
  });
347
- const { data, error } = yield blindpay.receivers.delete("re_000000000000");
449
+ const { data, error } = yield blindpay.receivers.delete("re_YuaMcI2B8zbQ");
348
450
  globalExpect(error).toBeNull();
349
451
  globalExpect(data).toEqual({ data: null });
350
452
  }));
@@ -366,7 +468,7 @@ var require_receivers_test = __commonJS({
366
468
  fetchMock.mockResponseOnce(JSON.stringify(mockedReceiverLimits), {
367
469
  headers: { "Content-Type": "application/json" }
368
470
  });
369
- const { data, error } = yield blindpay.receivers.getLimits("re_000000000000");
471
+ const { data, error } = yield blindpay.receivers.getLimits("re_YuaMcI2B8zbQ");
370
472
  globalExpect(error).toBeNull();
371
473
  globalExpect(data).toEqual(mockedReceiverLimits);
372
474
  }));
@@ -18714,7 +18714,7 @@ var import_expect_type = __toESM(require_dist(), 1);
18714
18714
  var import_node_crypto = require("crypto");
18715
18715
 
18716
18716
  // package.json
18717
- var version = "1.1.2";
18717
+ var version = "2.0.0";
18718
18718
 
18719
18719
  // src/internal/blindpay-error.ts
18720
18720
  var BlindPayError = class extends Error {
@@ -18843,6 +18843,16 @@ function createBankAccountsResource(instanceId, client) {
18843
18843
  return client.post(`/instances/${instanceId}/receivers/${receiver_id}/bank-accounts`, __spreadValues({
18844
18844
  type: "international_swift"
18845
18845
  }, data));
18846
+ },
18847
+ createRtp(_o) {
18848
+ var _p = _o, {
18849
+ receiver_id
18850
+ } = _p, data = __objRest(_p, [
18851
+ "receiver_id"
18852
+ ]);
18853
+ return client.post(`/instances/${instanceId}/receivers/${receiver_id}/bank-accounts`, __spreadValues({
18854
+ type: "rtp"
18855
+ }, data));
18846
18856
  }
18847
18857
  };
18848
18858
  }
@@ -18983,15 +18993,20 @@ function createReceiversResource(instanceId, client) {
18983
18993
  list() {
18984
18994
  return client.get(`/instances/${instanceId}/receivers`);
18985
18995
  },
18986
- create(_a3) {
18987
- var data = __objRest(_a3, []);
18996
+ createIndividualWithStandardKYC(data) {
18997
+ return client.post(`/instances/${instanceId}/receivers`, data);
18998
+ },
18999
+ createIndividualWithEnhancedKYC(data) {
19000
+ return client.post(`/instances/${instanceId}/receivers`, data);
19001
+ },
19002
+ createBusinessWithStandardKYB(data) {
18988
19003
  return client.post(`/instances/${instanceId}/receivers`, data);
18989
19004
  },
18990
19005
  get(receiver_id) {
18991
19006
  return client.get(`/instances/${instanceId}/receivers/${receiver_id}`);
18992
19007
  },
18993
- update(_b) {
18994
- var _c = _b, { receiver_id } = _c, data = __objRest(_c, ["receiver_id"]);
19008
+ update(_a3) {
19009
+ var _b = _a3, { receiver_id } = _b, data = __objRest(_b, ["receiver_id"]);
18995
19010
  return client.patch(`/instances/${instanceId}/receivers/${receiver_id}`, data);
18996
19011
  },
18997
19012
  delete(receiver_id) {