@blindpay/node 2.2.0 → 2.4.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 (53) hide show
  1. package/dist/{chunk-QCRVXYWF.mjs → chunk-4DVSRRBP.mjs} +10 -4
  2. package/dist/{chunk-IZYPRCCV.mjs → chunk-FG25JHDX.mjs} +8 -0
  3. package/dist/{chunk-E7M4CJKR.mjs → chunk-OTRFWEEC.mjs} +3 -0
  4. package/dist/chunk-Z6EYX4D3.mjs +29 -0
  5. package/dist/index.d.mts +4 -2
  6. package/dist/index.d.ts +4 -2
  7. package/dist/index.js +31 -2
  8. package/dist/index.mjs +4 -3
  9. package/dist/resources/api-keys/api-keys.test.js +31 -2
  10. package/dist/resources/api-keys/api-keys.test.mjs +4 -3
  11. package/dist/resources/available/available.test.js +31 -2
  12. package/dist/resources/available/available.test.mjs +4 -3
  13. package/dist/resources/bank-accounts/bank-accounts.test.js +31 -2
  14. package/dist/resources/bank-accounts/bank-accounts.test.mjs +4 -3
  15. package/dist/resources/instances/instances.test.js +31 -2
  16. package/dist/resources/instances/instances.test.mjs +4 -3
  17. package/dist/resources/partner-fees/partner-fees.test.js +31 -2
  18. package/dist/resources/partner-fees/partner-fees.test.mjs +4 -3
  19. package/dist/resources/payins/payins-quotes.test.js +67 -2
  20. package/dist/resources/payins/payins-quotes.test.mjs +40 -3
  21. package/dist/resources/payins/payins.test.js +31 -2
  22. package/dist/resources/payins/payins.test.mjs +4 -3
  23. package/dist/resources/payins/quotes.d.mts +31 -2
  24. package/dist/resources/payins/quotes.d.ts +31 -2
  25. package/dist/resources/payins/quotes.js +3 -0
  26. package/dist/resources/payins/quotes.mjs +1 -1
  27. package/dist/resources/payouts/payouts.test.js +31 -2
  28. package/dist/resources/payouts/payouts.test.mjs +4 -3
  29. package/dist/resources/quotes/quotes.test.js +31 -2
  30. package/dist/resources/quotes/quotes.test.mjs +4 -3
  31. package/dist/resources/receivers/receivers.test.js +31 -2
  32. package/dist/resources/receivers/receivers.test.mjs +4 -3
  33. package/dist/resources/terms-of-service/index.d.mts +15 -0
  34. package/dist/resources/terms-of-service/index.d.ts +15 -0
  35. package/dist/resources/terms-of-service/index.js +44 -0
  36. package/dist/resources/terms-of-service/index.mjs +9 -0
  37. package/dist/resources/terms-of-service/terms-of-service.test.d.mts +2 -0
  38. package/dist/resources/terms-of-service/terms-of-service.test.d.ts +2 -0
  39. package/dist/resources/terms-of-service/terms-of-service.test.js +19674 -0
  40. package/dist/resources/terms-of-service/terms-of-service.test.mjs +60 -0
  41. package/dist/resources/virtual-accounts/virtual-accounts.test.js +31 -2
  42. package/dist/resources/virtual-accounts/virtual-accounts.test.mjs +4 -3
  43. package/dist/resources/wallets/blockchain.d.mts +21 -1
  44. package/dist/resources/wallets/blockchain.d.ts +21 -1
  45. package/dist/resources/wallets/blockchain.js +8 -0
  46. package/dist/resources/wallets/blockchain.mjs +1 -1
  47. package/dist/resources/wallets/blockchain.test.js +96 -2
  48. package/dist/resources/wallets/blockchain.test.mjs +69 -3
  49. package/dist/resources/wallets/offramp.test.js +31 -2
  50. package/dist/resources/wallets/offramp.test.mjs +4 -3
  51. package/dist/resources/webhooks/webhooks.test.js +31 -2
  52. package/dist/resources/webhooks/webhooks.test.mjs +4 -3
  53. package/package.json +1 -1
@@ -18702,7 +18702,7 @@ var import_expect_type = __toESM(require_dist(), 1);
18702
18702
  var import_node_crypto = require("crypto");
18703
18703
 
18704
18704
  // package.json
18705
- var version = "2.2.0";
18705
+ var version = "2.4.0";
18706
18706
 
18707
18707
  // src/internal/blindpay-error.ts
18708
18708
  var BlindPayError = class extends Error {
@@ -18928,6 +18928,9 @@ function createPayinQuotesResource(instanceId, client) {
18928
18928
  getFxRate(_b) {
18929
18929
  var data = __objRest(_b, []);
18930
18930
  return client.post(`/instances/${instanceId}/payin-quotes/fx`, data);
18931
+ },
18932
+ get(id) {
18933
+ return client.get(`/instances/${instanceId}/payin-quotes/${id}`);
18931
18934
  }
18932
18935
  };
18933
18936
  }
@@ -19032,6 +19035,23 @@ function createReceiversResource(instanceId, client) {
19032
19035
  };
19033
19036
  }
19034
19037
 
19038
+ // src/resources/terms-of-service/index.ts
19039
+ function createTermsOfServiceResource(instanceId, client) {
19040
+ return {
19041
+ initiate({
19042
+ idempotency_key,
19043
+ receiver_id,
19044
+ redirect_url
19045
+ }) {
19046
+ return client.post(`/e/instances/${instanceId}/tos`, {
19047
+ idempotency_key,
19048
+ receiver_id,
19049
+ redirect_url
19050
+ });
19051
+ }
19052
+ };
19053
+ }
19054
+
19035
19055
  // src/resources/virtual-accounts/index.ts
19036
19056
  function createVirtualAccountsResource(instanceId, client) {
19037
19057
  return {
@@ -19126,6 +19146,14 @@ function createBlockchainWalletsResource(instanceId, client) {
19126
19146
  mintUsdbStellar(_e) {
19127
19147
  var data = __objRest(_e, []);
19128
19148
  return client.post(`/instances/${instanceId}/mint-usdb-stellar`, data);
19149
+ },
19150
+ mintUsdbSolana(_f) {
19151
+ var data = __objRest(_f, []);
19152
+ return client.post(`/instances/${instanceId}/mint-usdb-solana`, data);
19153
+ },
19154
+ prepareSolanaDelegationTransaction(_g) {
19155
+ var data = __objRest(_g, []);
19156
+ return client.post(`/instances/${instanceId}/prepare-delegate-solana`, data);
19129
19157
  }
19130
19158
  };
19131
19159
  }
@@ -19222,7 +19250,8 @@ var BlindPay = class {
19222
19250
  this.available = createAvailableResource(this.api);
19223
19251
  this.instances = __spreadProps(__spreadValues({}, createInstancesResource(this.instanceId, this.api)), {
19224
19252
  apiKeys: createApiKeysResource(this.instanceId, this.api),
19225
- webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api)
19253
+ webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api),
19254
+ tos: createTermsOfServiceResource(this.instanceId, this.api)
19226
19255
  });
19227
19256
  this.partnerFees = createPartnerFeesResource(this.instanceId, this.api);
19228
19257
  this.payins = __spreadProps(__spreadValues({}, createPayinsResource(this.instanceId, this.api)), {
@@ -8,16 +8,17 @@ import {
8
8
  import {
9
9
  BlindPay,
10
10
  init_client
11
- } from "../../chunk-QCRVXYWF.mjs";
12
- import "../../chunk-IZYPRCCV.mjs";
11
+ } from "../../chunk-4DVSRRBP.mjs";
12
+ import "../../chunk-FG25JHDX.mjs";
13
13
  import "../../chunk-QGNLMN6Z.mjs";
14
14
  import "../../chunk-UC57SCKQ.mjs";
15
15
  import "../../chunk-TBTA7A2P.mjs";
16
16
  import "../../chunk-67XECGMJ.mjs";
17
+ import "../../chunk-Z6EYX4D3.mjs";
17
18
  import "../../chunk-5XJJKYXE.mjs";
18
19
  import "../../chunk-RC5NN5UF.mjs";
19
20
  import "../../chunk-W7NJUABI.mjs";
20
- import "../../chunk-E7M4CJKR.mjs";
21
+ import "../../chunk-OTRFWEEC.mjs";
21
22
  import "../../chunk-3QQCDR3E.mjs";
22
23
  import "../../chunk-LRHWT4JU.mjs";
23
24
  import "../../chunk-U7CKUUO7.mjs";
@@ -18702,7 +18702,7 @@ var import_expect_type = __toESM(require_dist(), 1);
18702
18702
  var import_node_crypto = require("crypto");
18703
18703
 
18704
18704
  // package.json
18705
- var version = "2.2.0";
18705
+ var version = "2.4.0";
18706
18706
 
18707
18707
  // src/internal/blindpay-error.ts
18708
18708
  var BlindPayError = class extends Error {
@@ -18928,6 +18928,9 @@ function createPayinQuotesResource(instanceId, client) {
18928
18928
  getFxRate(_b) {
18929
18929
  var data = __objRest(_b, []);
18930
18930
  return client.post(`/instances/${instanceId}/payin-quotes/fx`, data);
18931
+ },
18932
+ get(id) {
18933
+ return client.get(`/instances/${instanceId}/payin-quotes/${id}`);
18931
18934
  }
18932
18935
  };
18933
18936
  }
@@ -19032,6 +19035,23 @@ function createReceiversResource(instanceId, client) {
19032
19035
  };
19033
19036
  }
19034
19037
 
19038
+ // src/resources/terms-of-service/index.ts
19039
+ function createTermsOfServiceResource(instanceId, client) {
19040
+ return {
19041
+ initiate({
19042
+ idempotency_key,
19043
+ receiver_id,
19044
+ redirect_url
19045
+ }) {
19046
+ return client.post(`/e/instances/${instanceId}/tos`, {
19047
+ idempotency_key,
19048
+ receiver_id,
19049
+ redirect_url
19050
+ });
19051
+ }
19052
+ };
19053
+ }
19054
+
19035
19055
  // src/resources/virtual-accounts/index.ts
19036
19056
  function createVirtualAccountsResource(instanceId, client) {
19037
19057
  return {
@@ -19126,6 +19146,14 @@ function createBlockchainWalletsResource(instanceId, client) {
19126
19146
  mintUsdbStellar(_e) {
19127
19147
  var data = __objRest(_e, []);
19128
19148
  return client.post(`/instances/${instanceId}/mint-usdb-stellar`, data);
19149
+ },
19150
+ mintUsdbSolana(_f) {
19151
+ var data = __objRest(_f, []);
19152
+ return client.post(`/instances/${instanceId}/mint-usdb-solana`, data);
19153
+ },
19154
+ prepareSolanaDelegationTransaction(_g) {
19155
+ var data = __objRest(_g, []);
19156
+ return client.post(`/instances/${instanceId}/prepare-delegate-solana`, data);
19129
19157
  }
19130
19158
  };
19131
19159
  }
@@ -19222,7 +19250,8 @@ var BlindPay = class {
19222
19250
  this.available = createAvailableResource(this.api);
19223
19251
  this.instances = __spreadProps(__spreadValues({}, createInstancesResource(this.instanceId, this.api)), {
19224
19252
  apiKeys: createApiKeysResource(this.instanceId, this.api),
19225
- webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api)
19253
+ webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api),
19254
+ tos: createTermsOfServiceResource(this.instanceId, this.api)
19226
19255
  });
19227
19256
  this.partnerFees = createPartnerFeesResource(this.instanceId, this.api);
19228
19257
  this.payins = __spreadProps(__spreadValues({}, createPayinsResource(this.instanceId, this.api)), {
@@ -19387,6 +19416,42 @@ describe("Payin quotes", () => {
19387
19416
  globalExpect(data).toEqual(mockedFxRate);
19388
19417
  }));
19389
19418
  });
19419
+ describe("Get payin quote", () => {
19420
+ it("should get a payin quote", () => __async(null, null, function* () {
19421
+ const mockedPayinQuote = {
19422
+ id: "qu_000000000000",
19423
+ payment_method: "pix",
19424
+ token: "USDC",
19425
+ request_amount: 1e3,
19426
+ cover_fees: true,
19427
+ currency_type: "sender",
19428
+ expires_at: 1712958191,
19429
+ currency: "BRL",
19430
+ commercial_quotation: 495,
19431
+ blindpay_quotation: 505,
19432
+ receiver_amount: 1010,
19433
+ sender_amount: 5240,
19434
+ partner_fee_amount: 150,
19435
+ flat_fee: 50,
19436
+ total_fee_amount: 1.53,
19437
+ payer_rules: {
19438
+ pix_allowed_tax_ids: ["149.476.037-68"]
19439
+ },
19440
+ blockchain_wallet_id: "bw_000000000000",
19441
+ instance_id: "in_000000000000",
19442
+ partner_fee_id: "pf_000000000000",
19443
+ billing_fee: 100,
19444
+ created_at: "2021-01-01T00:00:00Z",
19445
+ updated_at: "2021-01-01T00:00:00Z"
19446
+ };
19447
+ fetchMock.mockResponseOnce(JSON.stringify(mockedPayinQuote), {
19448
+ headers: { "Content-Type": "application/json" }
19449
+ });
19450
+ const { data, error } = yield blindpay.payins.quotes.get("qu_000000000000");
19451
+ globalExpect(error).toBeNull();
19452
+ globalExpect(data).toEqual(mockedPayinQuote);
19453
+ }));
19454
+ });
19390
19455
  });
19391
19456
  /*! Bundled license information:
19392
19457
 
@@ -8,16 +8,17 @@ import {
8
8
  import {
9
9
  BlindPay,
10
10
  init_client
11
- } from "../../chunk-QCRVXYWF.mjs";
12
- import "../../chunk-IZYPRCCV.mjs";
11
+ } from "../../chunk-4DVSRRBP.mjs";
12
+ import "../../chunk-FG25JHDX.mjs";
13
13
  import "../../chunk-QGNLMN6Z.mjs";
14
14
  import "../../chunk-UC57SCKQ.mjs";
15
15
  import "../../chunk-TBTA7A2P.mjs";
16
16
  import "../../chunk-67XECGMJ.mjs";
17
+ import "../../chunk-Z6EYX4D3.mjs";
17
18
  import "../../chunk-5XJJKYXE.mjs";
18
19
  import "../../chunk-RC5NN5UF.mjs";
19
20
  import "../../chunk-W7NJUABI.mjs";
20
- import "../../chunk-E7M4CJKR.mjs";
21
+ import "../../chunk-OTRFWEEC.mjs";
21
22
  import "../../chunk-3QQCDR3E.mjs";
22
23
  import "../../chunk-LRHWT4JU.mjs";
23
24
  import "../../chunk-U7CKUUO7.mjs";
@@ -89,6 +90,42 @@ var require_payins_quotes_test = __commonJS({
89
90
  globalExpect(data).toEqual(mockedFxRate);
90
91
  }));
91
92
  });
93
+ describe("Get payin quote", () => {
94
+ it("should get a payin quote", () => __async(null, null, function* () {
95
+ const mockedPayinQuote = {
96
+ id: "qu_000000000000",
97
+ payment_method: "pix",
98
+ token: "USDC",
99
+ request_amount: 1e3,
100
+ cover_fees: true,
101
+ currency_type: "sender",
102
+ expires_at: 1712958191,
103
+ currency: "BRL",
104
+ commercial_quotation: 495,
105
+ blindpay_quotation: 505,
106
+ receiver_amount: 1010,
107
+ sender_amount: 5240,
108
+ partner_fee_amount: 150,
109
+ flat_fee: 50,
110
+ total_fee_amount: 1.53,
111
+ payer_rules: {
112
+ pix_allowed_tax_ids: ["149.476.037-68"]
113
+ },
114
+ blockchain_wallet_id: "bw_000000000000",
115
+ instance_id: "in_000000000000",
116
+ partner_fee_id: "pf_000000000000",
117
+ billing_fee: 100,
118
+ created_at: "2021-01-01T00:00:00Z",
119
+ updated_at: "2021-01-01T00:00:00Z"
120
+ };
121
+ fetchMock.mockResponseOnce(JSON.stringify(mockedPayinQuote), {
122
+ headers: { "Content-Type": "application/json" }
123
+ });
124
+ const { data, error } = yield blindpay.payins.quotes.get("qu_000000000000");
125
+ globalExpect(error).toBeNull();
126
+ globalExpect(data).toEqual(mockedPayinQuote);
127
+ }));
128
+ });
92
129
  });
93
130
  }
94
131
  });
@@ -18702,7 +18702,7 @@ var import_expect_type = __toESM(require_dist(), 1);
18702
18702
  var import_node_crypto = require("crypto");
18703
18703
 
18704
18704
  // package.json
18705
- var version = "2.2.0";
18705
+ var version = "2.4.0";
18706
18706
 
18707
18707
  // src/internal/blindpay-error.ts
18708
18708
  var BlindPayError = class extends Error {
@@ -18928,6 +18928,9 @@ function createPayinQuotesResource(instanceId, client) {
18928
18928
  getFxRate(_b) {
18929
18929
  var data = __objRest(_b, []);
18930
18930
  return client.post(`/instances/${instanceId}/payin-quotes/fx`, data);
18931
+ },
18932
+ get(id) {
18933
+ return client.get(`/instances/${instanceId}/payin-quotes/${id}`);
18931
18934
  }
18932
18935
  };
18933
18936
  }
@@ -19032,6 +19035,23 @@ function createReceiversResource(instanceId, client) {
19032
19035
  };
19033
19036
  }
19034
19037
 
19038
+ // src/resources/terms-of-service/index.ts
19039
+ function createTermsOfServiceResource(instanceId, client) {
19040
+ return {
19041
+ initiate({
19042
+ idempotency_key,
19043
+ receiver_id,
19044
+ redirect_url
19045
+ }) {
19046
+ return client.post(`/e/instances/${instanceId}/tos`, {
19047
+ idempotency_key,
19048
+ receiver_id,
19049
+ redirect_url
19050
+ });
19051
+ }
19052
+ };
19053
+ }
19054
+
19035
19055
  // src/resources/virtual-accounts/index.ts
19036
19056
  function createVirtualAccountsResource(instanceId, client) {
19037
19057
  return {
@@ -19126,6 +19146,14 @@ function createBlockchainWalletsResource(instanceId, client) {
19126
19146
  mintUsdbStellar(_e) {
19127
19147
  var data = __objRest(_e, []);
19128
19148
  return client.post(`/instances/${instanceId}/mint-usdb-stellar`, data);
19149
+ },
19150
+ mintUsdbSolana(_f) {
19151
+ var data = __objRest(_f, []);
19152
+ return client.post(`/instances/${instanceId}/mint-usdb-solana`, data);
19153
+ },
19154
+ prepareSolanaDelegationTransaction(_g) {
19155
+ var data = __objRest(_g, []);
19156
+ return client.post(`/instances/${instanceId}/prepare-delegate-solana`, data);
19129
19157
  }
19130
19158
  };
19131
19159
  }
@@ -19222,7 +19250,8 @@ var BlindPay = class {
19222
19250
  this.available = createAvailableResource(this.api);
19223
19251
  this.instances = __spreadProps(__spreadValues({}, createInstancesResource(this.instanceId, this.api)), {
19224
19252
  apiKeys: createApiKeysResource(this.instanceId, this.api),
19225
- webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api)
19253
+ webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api),
19254
+ tos: createTermsOfServiceResource(this.instanceId, this.api)
19226
19255
  });
19227
19256
  this.partnerFees = createPartnerFeesResource(this.instanceId, this.api);
19228
19257
  this.payins = __spreadProps(__spreadValues({}, createPayinsResource(this.instanceId, this.api)), {
@@ -8,16 +8,17 @@ import {
8
8
  import {
9
9
  BlindPay,
10
10
  init_client
11
- } from "../../chunk-QCRVXYWF.mjs";
12
- import "../../chunk-IZYPRCCV.mjs";
11
+ } from "../../chunk-4DVSRRBP.mjs";
12
+ import "../../chunk-FG25JHDX.mjs";
13
13
  import "../../chunk-QGNLMN6Z.mjs";
14
14
  import "../../chunk-UC57SCKQ.mjs";
15
15
  import "../../chunk-TBTA7A2P.mjs";
16
16
  import "../../chunk-67XECGMJ.mjs";
17
+ import "../../chunk-Z6EYX4D3.mjs";
17
18
  import "../../chunk-5XJJKYXE.mjs";
18
19
  import "../../chunk-RC5NN5UF.mjs";
19
20
  import "../../chunk-W7NJUABI.mjs";
20
- import "../../chunk-E7M4CJKR.mjs";
21
+ import "../../chunk-OTRFWEEC.mjs";
21
22
  import "../../chunk-3QQCDR3E.mjs";
22
23
  import "../../chunk-LRHWT4JU.mjs";
23
24
  import "../../chunk-U7CKUUO7.mjs";
@@ -1,9 +1,10 @@
1
1
  import { I as InternalApiClient, g as CurrencyType, S as StablecoinToken, B as BlindpayApiResponse, h as Currency } from '../../api-client-Cw2mNJeR.mjs';
2
2
 
3
+ type PayinPaymentMethod = "ach" | "wire" | "pix" | "spei";
3
4
  type CreatePayinQuoteInput = {
4
5
  blockchain_wallet_id: string;
5
6
  currency_type: CurrencyType;
6
- payment_method: "ach" | "wire" | "pix" | "spei";
7
+ payment_method: PayinPaymentMethod;
7
8
  request_amount: number;
8
9
  token: StablecoinToken;
9
10
  cover_fees: boolean;
@@ -35,9 +36,37 @@ type GetPayinFxRateResponse = {
35
36
  instance_flat_fee: number;
36
37
  instance_percentage_fee: number;
37
38
  };
39
+ type GetPayinQuoteInput = string;
40
+ type GetPayinQuoteResponse = {
41
+ id: string;
42
+ payment_method: PayinPaymentMethod;
43
+ token: StablecoinToken;
44
+ request_amount: number;
45
+ cover_fees: boolean;
46
+ currency_type: CurrencyType;
47
+ expires_at: number | null;
48
+ currency: Extract<Currency, "BRL" | "USD" | "MXN" | "COP" | "ARS">;
49
+ commercial_quotation: number | null;
50
+ blindpay_quotation: number | null;
51
+ receiver_amount: number;
52
+ sender_amount: number;
53
+ partner_fee_amount: number | null;
54
+ flat_fee: number | null;
55
+ total_fee_amount: number | null;
56
+ payer_rules: {
57
+ pix_allowed_tax_ids: string[];
58
+ } | null;
59
+ blockchain_wallet_id: string;
60
+ instance_id: string;
61
+ partner_fee_id: string | null;
62
+ billing_fee: number | null;
63
+ created_at: string;
64
+ updated_at: string;
65
+ };
38
66
  declare function createPayinQuotesResource(instanceId: string, client: InternalApiClient): {
39
67
  create({ ...data }: CreatePayinQuoteInput): Promise<BlindpayApiResponse<CreatePayinQuoteResponse>>;
40
68
  getFxRate({ ...data }: GetPayinFxRateInput): Promise<BlindpayApiResponse<GetPayinFxRateResponse>>;
69
+ get(id: GetPayinQuoteInput): Promise<BlindpayApiResponse<GetPayinQuoteResponse>>;
41
70
  };
42
71
 
43
- export { type CreatePayinQuoteInput, type CreatePayinQuoteResponse, type GetPayinFxRateInput, type GetPayinFxRateResponse, createPayinQuotesResource };
72
+ export { type CreatePayinQuoteInput, type CreatePayinQuoteResponse, type GetPayinFxRateInput, type GetPayinFxRateResponse, type GetPayinQuoteInput, type GetPayinQuoteResponse, type PayinPaymentMethod, createPayinQuotesResource };
@@ -1,9 +1,10 @@
1
1
  import { I as InternalApiClient, g as CurrencyType, S as StablecoinToken, B as BlindpayApiResponse, h as Currency } from '../../api-client-Cw2mNJeR.js';
2
2
 
3
+ type PayinPaymentMethod = "ach" | "wire" | "pix" | "spei";
3
4
  type CreatePayinQuoteInput = {
4
5
  blockchain_wallet_id: string;
5
6
  currency_type: CurrencyType;
6
- payment_method: "ach" | "wire" | "pix" | "spei";
7
+ payment_method: PayinPaymentMethod;
7
8
  request_amount: number;
8
9
  token: StablecoinToken;
9
10
  cover_fees: boolean;
@@ -35,9 +36,37 @@ type GetPayinFxRateResponse = {
35
36
  instance_flat_fee: number;
36
37
  instance_percentage_fee: number;
37
38
  };
39
+ type GetPayinQuoteInput = string;
40
+ type GetPayinQuoteResponse = {
41
+ id: string;
42
+ payment_method: PayinPaymentMethod;
43
+ token: StablecoinToken;
44
+ request_amount: number;
45
+ cover_fees: boolean;
46
+ currency_type: CurrencyType;
47
+ expires_at: number | null;
48
+ currency: Extract<Currency, "BRL" | "USD" | "MXN" | "COP" | "ARS">;
49
+ commercial_quotation: number | null;
50
+ blindpay_quotation: number | null;
51
+ receiver_amount: number;
52
+ sender_amount: number;
53
+ partner_fee_amount: number | null;
54
+ flat_fee: number | null;
55
+ total_fee_amount: number | null;
56
+ payer_rules: {
57
+ pix_allowed_tax_ids: string[];
58
+ } | null;
59
+ blockchain_wallet_id: string;
60
+ instance_id: string;
61
+ partner_fee_id: string | null;
62
+ billing_fee: number | null;
63
+ created_at: string;
64
+ updated_at: string;
65
+ };
38
66
  declare function createPayinQuotesResource(instanceId: string, client: InternalApiClient): {
39
67
  create({ ...data }: CreatePayinQuoteInput): Promise<BlindpayApiResponse<CreatePayinQuoteResponse>>;
40
68
  getFxRate({ ...data }: GetPayinFxRateInput): Promise<BlindpayApiResponse<GetPayinFxRateResponse>>;
69
+ get(id: GetPayinQuoteInput): Promise<BlindpayApiResponse<GetPayinQuoteResponse>>;
41
70
  };
42
71
 
43
- export { type CreatePayinQuoteInput, type CreatePayinQuoteResponse, type GetPayinFxRateInput, type GetPayinFxRateResponse, createPayinQuotesResource };
72
+ export { type CreatePayinQuoteInput, type CreatePayinQuoteResponse, type GetPayinFxRateInput, type GetPayinFxRateResponse, type GetPayinQuoteInput, type GetPayinQuoteResponse, type PayinPaymentMethod, createPayinQuotesResource };
@@ -46,6 +46,9 @@ function createPayinQuotesResource(instanceId, client) {
46
46
  getFxRate(_b) {
47
47
  var data = __objRest(_b, []);
48
48
  return client.post(`/instances/${instanceId}/payin-quotes/fx`, data);
49
+ },
50
+ get(id) {
51
+ return client.get(`/instances/${instanceId}/payin-quotes/${id}`);
49
52
  }
50
53
  };
51
54
  }
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  createPayinQuotesResource,
3
3
  init_quotes
4
- } from "../../chunk-E7M4CJKR.mjs";
4
+ } from "../../chunk-OTRFWEEC.mjs";
5
5
  import "../../chunk-OBKEW4AQ.mjs";
6
6
  init_quotes();
7
7
  export {
@@ -18702,7 +18702,7 @@ var import_expect_type = __toESM(require_dist(), 1);
18702
18702
  var import_node_crypto = require("crypto");
18703
18703
 
18704
18704
  // package.json
18705
- var version = "2.2.0";
18705
+ var version = "2.4.0";
18706
18706
 
18707
18707
  // src/internal/blindpay-error.ts
18708
18708
  var BlindPayError = class extends Error {
@@ -18928,6 +18928,9 @@ function createPayinQuotesResource(instanceId, client) {
18928
18928
  getFxRate(_b) {
18929
18929
  var data = __objRest(_b, []);
18930
18930
  return client.post(`/instances/${instanceId}/payin-quotes/fx`, data);
18931
+ },
18932
+ get(id) {
18933
+ return client.get(`/instances/${instanceId}/payin-quotes/${id}`);
18931
18934
  }
18932
18935
  };
18933
18936
  }
@@ -19032,6 +19035,23 @@ function createReceiversResource(instanceId, client) {
19032
19035
  };
19033
19036
  }
19034
19037
 
19038
+ // src/resources/terms-of-service/index.ts
19039
+ function createTermsOfServiceResource(instanceId, client) {
19040
+ return {
19041
+ initiate({
19042
+ idempotency_key,
19043
+ receiver_id,
19044
+ redirect_url
19045
+ }) {
19046
+ return client.post(`/e/instances/${instanceId}/tos`, {
19047
+ idempotency_key,
19048
+ receiver_id,
19049
+ redirect_url
19050
+ });
19051
+ }
19052
+ };
19053
+ }
19054
+
19035
19055
  // src/resources/virtual-accounts/index.ts
19036
19056
  function createVirtualAccountsResource(instanceId, client) {
19037
19057
  return {
@@ -19126,6 +19146,14 @@ function createBlockchainWalletsResource(instanceId, client) {
19126
19146
  mintUsdbStellar(_e) {
19127
19147
  var data = __objRest(_e, []);
19128
19148
  return client.post(`/instances/${instanceId}/mint-usdb-stellar`, data);
19149
+ },
19150
+ mintUsdbSolana(_f) {
19151
+ var data = __objRest(_f, []);
19152
+ return client.post(`/instances/${instanceId}/mint-usdb-solana`, data);
19153
+ },
19154
+ prepareSolanaDelegationTransaction(_g) {
19155
+ var data = __objRest(_g, []);
19156
+ return client.post(`/instances/${instanceId}/prepare-delegate-solana`, data);
19129
19157
  }
19130
19158
  };
19131
19159
  }
@@ -19222,7 +19250,8 @@ var BlindPay = class {
19222
19250
  this.available = createAvailableResource(this.api);
19223
19251
  this.instances = __spreadProps(__spreadValues({}, createInstancesResource(this.instanceId, this.api)), {
19224
19252
  apiKeys: createApiKeysResource(this.instanceId, this.api),
19225
- webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api)
19253
+ webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api),
19254
+ tos: createTermsOfServiceResource(this.instanceId, this.api)
19226
19255
  });
19227
19256
  this.partnerFees = createPartnerFeesResource(this.instanceId, this.api);
19228
19257
  this.payins = __spreadProps(__spreadValues({}, createPayinsResource(this.instanceId, this.api)), {
@@ -8,16 +8,17 @@ import {
8
8
  import {
9
9
  BlindPay,
10
10
  init_client
11
- } from "../../chunk-QCRVXYWF.mjs";
12
- import "../../chunk-IZYPRCCV.mjs";
11
+ } from "../../chunk-4DVSRRBP.mjs";
12
+ import "../../chunk-FG25JHDX.mjs";
13
13
  import "../../chunk-QGNLMN6Z.mjs";
14
14
  import "../../chunk-UC57SCKQ.mjs";
15
15
  import "../../chunk-TBTA7A2P.mjs";
16
16
  import "../../chunk-67XECGMJ.mjs";
17
+ import "../../chunk-Z6EYX4D3.mjs";
17
18
  import "../../chunk-5XJJKYXE.mjs";
18
19
  import "../../chunk-RC5NN5UF.mjs";
19
20
  import "../../chunk-W7NJUABI.mjs";
20
- import "../../chunk-E7M4CJKR.mjs";
21
+ import "../../chunk-OTRFWEEC.mjs";
21
22
  import "../../chunk-3QQCDR3E.mjs";
22
23
  import "../../chunk-LRHWT4JU.mjs";
23
24
  import "../../chunk-U7CKUUO7.mjs";
@@ -18702,7 +18702,7 @@ var import_expect_type = __toESM(require_dist(), 1);
18702
18702
  var import_node_crypto = require("crypto");
18703
18703
 
18704
18704
  // package.json
18705
- var version = "2.2.0";
18705
+ var version = "2.4.0";
18706
18706
 
18707
18707
  // src/internal/blindpay-error.ts
18708
18708
  var BlindPayError = class extends Error {
@@ -18928,6 +18928,9 @@ function createPayinQuotesResource(instanceId, client) {
18928
18928
  getFxRate(_b) {
18929
18929
  var data = __objRest(_b, []);
18930
18930
  return client.post(`/instances/${instanceId}/payin-quotes/fx`, data);
18931
+ },
18932
+ get(id) {
18933
+ return client.get(`/instances/${instanceId}/payin-quotes/${id}`);
18931
18934
  }
18932
18935
  };
18933
18936
  }
@@ -19032,6 +19035,23 @@ function createReceiversResource(instanceId, client) {
19032
19035
  };
19033
19036
  }
19034
19037
 
19038
+ // src/resources/terms-of-service/index.ts
19039
+ function createTermsOfServiceResource(instanceId, client) {
19040
+ return {
19041
+ initiate({
19042
+ idempotency_key,
19043
+ receiver_id,
19044
+ redirect_url
19045
+ }) {
19046
+ return client.post(`/e/instances/${instanceId}/tos`, {
19047
+ idempotency_key,
19048
+ receiver_id,
19049
+ redirect_url
19050
+ });
19051
+ }
19052
+ };
19053
+ }
19054
+
19035
19055
  // src/resources/virtual-accounts/index.ts
19036
19056
  function createVirtualAccountsResource(instanceId, client) {
19037
19057
  return {
@@ -19126,6 +19146,14 @@ function createBlockchainWalletsResource(instanceId, client) {
19126
19146
  mintUsdbStellar(_e) {
19127
19147
  var data = __objRest(_e, []);
19128
19148
  return client.post(`/instances/${instanceId}/mint-usdb-stellar`, data);
19149
+ },
19150
+ mintUsdbSolana(_f) {
19151
+ var data = __objRest(_f, []);
19152
+ return client.post(`/instances/${instanceId}/mint-usdb-solana`, data);
19153
+ },
19154
+ prepareSolanaDelegationTransaction(_g) {
19155
+ var data = __objRest(_g, []);
19156
+ return client.post(`/instances/${instanceId}/prepare-delegate-solana`, data);
19129
19157
  }
19130
19158
  };
19131
19159
  }
@@ -19222,7 +19250,8 @@ var BlindPay = class {
19222
19250
  this.available = createAvailableResource(this.api);
19223
19251
  this.instances = __spreadProps(__spreadValues({}, createInstancesResource(this.instanceId, this.api)), {
19224
19252
  apiKeys: createApiKeysResource(this.instanceId, this.api),
19225
- webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api)
19253
+ webhookEndpoints: createWebhookEndpointsResource(this.instanceId, this.api),
19254
+ tos: createTermsOfServiceResource(this.instanceId, this.api)
19226
19255
  });
19227
19256
  this.partnerFees = createPartnerFeesResource(this.instanceId, this.api);
19228
19257
  this.payins = __spreadProps(__spreadValues({}, createPayinsResource(this.instanceId, this.api)), {
@@ -8,16 +8,17 @@ import {
8
8
  import {
9
9
  BlindPay,
10
10
  init_client
11
- } from "../../chunk-QCRVXYWF.mjs";
12
- import "../../chunk-IZYPRCCV.mjs";
11
+ } from "../../chunk-4DVSRRBP.mjs";
12
+ import "../../chunk-FG25JHDX.mjs";
13
13
  import "../../chunk-QGNLMN6Z.mjs";
14
14
  import "../../chunk-UC57SCKQ.mjs";
15
15
  import "../../chunk-TBTA7A2P.mjs";
16
16
  import "../../chunk-67XECGMJ.mjs";
17
+ import "../../chunk-Z6EYX4D3.mjs";
17
18
  import "../../chunk-5XJJKYXE.mjs";
18
19
  import "../../chunk-RC5NN5UF.mjs";
19
20
  import "../../chunk-W7NJUABI.mjs";
20
- import "../../chunk-E7M4CJKR.mjs";
21
+ import "../../chunk-OTRFWEEC.mjs";
21
22
  import "../../chunk-3QQCDR3E.mjs";
22
23
  import "../../chunk-LRHWT4JU.mjs";
23
24
  import "../../chunk-U7CKUUO7.mjs";