@qonto/embed-sdk 0.66.0 → 0.67.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.
- package/dist/index.umd.js +3 -3
- package/dist/sepa-transfers/bulk-transfers/bulk-transfers.d.ts +4 -4
- package/dist/sepa-transfers/bulk-transfers/client/bulk-transfers.client.d.ts +3 -3
- package/dist/sepa-transfers/bulk-transfers/client/bulk-transfers.client.d.ts.map +1 -1
- package/dist/sepa-transfers/bulk-transfers/index.d.ts +1 -1
- package/dist/sepa-transfers/client/sepa-transfers.client.d.ts +8 -9
- package/dist/sepa-transfers/client/sepa-transfers.client.d.ts.map +1 -1
- package/dist/sepa-transfers/index.d.ts +3 -3
- package/dist/sepa-transfers/sepa-transfers.d.ts +10 -10
- package/dist/sepa-transfers/sepa-transfers.d.ts.map +1 -1
- package/dist/server/_virtual/index.js +1 -1
- package/dist/server/_virtual/index2.js +1 -1
- package/dist/server/node_modules/.pnpm/@amplitude_analytics-core@2.43.1/node_modules/@amplitude/analytics-core/lib/esm/utils/observable.js +1 -1
- package/dist/server/node_modules/.pnpm/@amplitude_analytics-core@2.43.1/node_modules/@amplitude/analytics-core/lib/esm/utils/safe-stringify.js +1 -1
- package/dist/server/node_modules/.pnpm/@amplitude_plugin-autocapture-browser@1.24.2/node_modules/@amplitude/plugin-autocapture-browser/lib/esm/autocapture/track-thrashed-cursor.js +1 -1
- package/dist/server/node_modules/.pnpm/@amplitude_plugin-autocapture-browser@1.24.2/node_modules/@amplitude/plugin-autocapture-browser/lib/esm/autocapture-plugin.js +1 -1
- package/dist/server/node_modules/.pnpm/@amplitude_plugin-autocapture-browser@1.24.2/node_modules/@amplitude/plugin-autocapture-browser/lib/esm/frustration-plugin.js +1 -1
- package/dist/server/node_modules/.pnpm/@amplitude_plugin-autocapture-browser@1.24.2/node_modules/@amplitude/plugin-autocapture-browser/lib/esm/observables.js +1 -1
- package/dist/server/node_modules/.pnpm/@amplitude_plugin-network-capture-browser@1.9.10/node_modules/@amplitude/plugin-network-capture-browser/lib/esm/network-capture-plugin.js +1 -1
- package/dist/server/sepa-transfers/bulk-transfers/bulk-transfers.d.ts +4 -4
- package/dist/server/sepa-transfers/bulk-transfers/client/bulk-transfers.client.d.ts +3 -3
- package/dist/server/sepa-transfers/bulk-transfers/client/bulk-transfers.client.d.ts.map +1 -1
- package/dist/server/sepa-transfers/bulk-transfers/index.d.ts +1 -1
- package/dist/server/sepa-transfers/client/sepa-transfers.client.d.ts +8 -9
- package/dist/server/sepa-transfers/client/sepa-transfers.client.d.ts.map +1 -1
- package/dist/server/sepa-transfers/index.d.ts +3 -3
- package/dist/server/sepa-transfers/sepa-transfers.d.ts +10 -10
- package/dist/server/sepa-transfers/sepa-transfers.d.ts.map +1 -1
- package/dist/src/sepa-transfers/bulk-transfers/client/bulk-transfers.client.js +1 -1
- package/dist/src/sepa-transfers/client/sepa-transfers.client.js +1 -1
- package/dist/src/sepa-transfers/sepa-transfers.js +1 -1
- package/package.json +1 -1
|
@@ -5,13 +5,13 @@ import '../ui/ui-elements/sca-passkey/qonto-sca-passkey-waiting.ts';
|
|
|
5
5
|
* Fetches the list of SEPA transfers for the current user.
|
|
6
6
|
* @param getSepaTransfersParams - An object containing:
|
|
7
7
|
* - `operationSettings`: An object with operation-level settings such as
|
|
8
|
-
* `
|
|
8
|
+
* `proxyEndpointDescriptor` (preferred over using the access token flow),
|
|
9
9
|
* `accessToken`, `stagingToken`, `paginationSettings`, and other optional
|
|
10
10
|
* parameters.
|
|
11
11
|
* @returns A promise that resolves to an object containing an array of SEPA
|
|
12
12
|
* transfers and a `meta` object containing pagination state.
|
|
13
13
|
* @throws `InvalidParametersError` If any parameter validation fails.
|
|
14
|
-
* @throws `AuthenticationError` If both the `
|
|
14
|
+
* @throws `AuthenticationError` If both the `proxyEndpointDescriptor` and
|
|
15
15
|
* `accessToken` are invalid or missing within `operationSettings`.
|
|
16
16
|
* @throws `EmbedApiError` If the API request fails or returns an error.
|
|
17
17
|
*/
|
|
@@ -21,13 +21,13 @@ export declare function getSepaTransfers(getSepaTransfersParams?: SepaTransferPa
|
|
|
21
21
|
* @param getSepaTransferParams - An object containing:
|
|
22
22
|
* - `sepaTransferSettings`: An object with the `sepaTransferId` property (string).
|
|
23
23
|
* - `operationSettings`: An object with operation-level settings such as
|
|
24
|
-
* `
|
|
24
|
+
* `proxyEndpointDescriptor` (preferred over using the access token flow),
|
|
25
25
|
* `accessToken`, `stagingToken`, and other optional
|
|
26
26
|
* parameters.
|
|
27
27
|
* @returns A promise that resolves to a SEPA transfer.
|
|
28
28
|
* @throws `InvalidParametersError` If the `sepaTransferId` parameter is not a string
|
|
29
29
|
* or missing, or if any parameter validation fails.
|
|
30
|
-
* @throws `AuthenticationError` If both the `
|
|
30
|
+
* @throws `AuthenticationError` If both the `proxyEndpointDescriptor` and
|
|
31
31
|
* `accessToken` are invalid or missing within `operationSettings`.
|
|
32
32
|
* @throws `EmbedApiError` If the API request fails or returns an error.
|
|
33
33
|
*/
|
|
@@ -61,14 +61,14 @@ export declare function getSepaTransfer({ sepaTransferSettings, operationSetting
|
|
|
61
61
|
* the process and require the user to give the transfer data after the VoP
|
|
62
62
|
* result.
|
|
63
63
|
* - `operationSettings`: An object with operation-level settings such as
|
|
64
|
-
* `
|
|
64
|
+
* `proxyEndpointDescriptor` (preferred over using the access token flow),
|
|
65
65
|
* `accessToken`, `stagingToken`, `idempotencyKey`, `mfaPreference`,
|
|
66
66
|
* `uiParentElementId`, and other optional parameters.
|
|
67
67
|
* @returns As the first yielded value, a promise that resolves to the VoP check
|
|
68
68
|
* result.
|
|
69
69
|
* @returns As the final return value, a promise that resolves to the created
|
|
70
70
|
* SEPA transfer.
|
|
71
|
-
* @throws `AuthenticationError` If both the `
|
|
71
|
+
* @throws `AuthenticationError` If both the `proxyEndpointDescriptor` and
|
|
72
72
|
* `accessToken` are invalid or missing within `operationSettings`.
|
|
73
73
|
* @throws `InvalidParametersError` If the `transfer` parameter is not an object
|
|
74
74
|
* or is missing, or if the required properties of the transfer object are
|
|
@@ -135,13 +135,13 @@ export declare function createSepaTransfer({ sepaTransferSettings, operationSett
|
|
|
135
135
|
* @param cancelSepaTransferParams - An object containing:
|
|
136
136
|
* - `sepaTransferSettings`: An object with the `sepaTransferId` property (string).
|
|
137
137
|
* - `operationSettings`: An object with operation-level settings such as
|
|
138
|
-
* `
|
|
138
|
+
* `proxyEndpointDescriptor` (preferred over using the access token flow),
|
|
139
139
|
* `accessToken`, `stagingToken`, and other optional
|
|
140
140
|
* parameters.
|
|
141
141
|
* @returns A promise that resolves without return value.
|
|
142
142
|
* @throws `InvalidParametersError` If the `sepaTransferId` parameter is missing
|
|
143
143
|
* or not a string, or if any parameter validation fails.
|
|
144
|
-
* @throws `AuthenticationError` If both the `
|
|
144
|
+
* @throws `AuthenticationError` If both the `proxyEndpointDescriptor` and
|
|
145
145
|
* `accessToken` are invalid or missing within `operationSettings`.
|
|
146
146
|
* @throws `EmbedApiError` If the API request fails or returns an error.
|
|
147
147
|
*/
|
|
@@ -155,14 +155,14 @@ export declare function cancelSepaTransfer({ sepaTransferSettings, operationSett
|
|
|
155
155
|
* - `sepaTransferSettings`: An object with the `callbackUrl` property, which
|
|
156
156
|
* will be used to return the user to the desired location after completion.
|
|
157
157
|
* - `operationSettings`: An object with operation-level settings such as
|
|
158
|
-
* `
|
|
158
|
+
* `proxyEndpointDescriptor` (preferred over using the access token flow),
|
|
159
159
|
* `accessToken`, `stagingToken`, `locale`, and other optional
|
|
160
160
|
* parameters.
|
|
161
161
|
* @returns A promise that resolves to an object representing the Embed Auth Link.
|
|
162
162
|
* This object contains a `url` property with the link to start the SEPA transfer.
|
|
163
163
|
* @throws `InvalidParametersError` If the callbackUrl is invalid or missing, or
|
|
164
164
|
* if any parameter validation fails.
|
|
165
|
-
* @throws `AuthenticationError` If both the `
|
|
165
|
+
* @throws `AuthenticationError` If both the `proxyEndpointDescriptor` and
|
|
166
166
|
* `accessToken` are invalid or missing within `operationSettings`.
|
|
167
167
|
* @throws `EmbedApiError` If the API request fails or returns an error.
|
|
168
168
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sepa-transfers.d.ts","sourceRoot":"","sources":["../../../src/sepa-transfers/sepa-transfers.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,qCAAqC,CAAC;AAwCjF,OAAO,KAAK,EACV,4BAA4B,EAC5B,wBAAwB,EACxB,eAAe,EACf,wBAAwB,EACxB,eAAe,EAEf,YAAY,EACZ,+BAA+B,EAE/B,kBAAkB,EAGlB,qBAAqB,EACtB,MAAM,+BAA+B,CAAC;AAgBvC,OAAO,4DAA4D,CAAC;AAEpE;;;;;;;;;;;;;GAaG;AACH,wBAAsB,gBAAgB,CACpC,sBAAsB,CAAC,EAAE,kBAAkB,CAAC,KAAK,CAAC,GACjD,OAAO,CAAC,wBAAwB,CAAC,CAuDnC;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,eAAe,CAAC,EACpC,oBAAoB,EACpB,iBAAiB,GAClB,EAAE,kBAAkB,CAAC,eAAe,CAAC,GAAG,OAAO,CAAC,YAAY,CAAC,CA2B7D;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgGG;AACH,wBAAuB,kBAAkB,CAAC,EACxC,oBAAoB,EACpB,iBAAiB,GAClB,EAAE,kBAAkB,CACnB,eAAe,GAAG,4BAA4B,CAC/C,GAAG,cAAc,CAAC,qBAAqB,EAAE,YAAY,GAAG,SAAS,CAAC,
|
|
1
|
+
{"version":3,"file":"sepa-transfers.d.ts","sourceRoot":"","sources":["../../../src/sepa-transfers/sepa-transfers.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,qCAAqC,CAAC;AAwCjF,OAAO,KAAK,EACV,4BAA4B,EAC5B,wBAAwB,EACxB,eAAe,EACf,wBAAwB,EACxB,eAAe,EAEf,YAAY,EACZ,+BAA+B,EAE/B,kBAAkB,EAGlB,qBAAqB,EACtB,MAAM,+BAA+B,CAAC;AAgBvC,OAAO,4DAA4D,CAAC;AAEpE;;;;;;;;;;;;;GAaG;AACH,wBAAsB,gBAAgB,CACpC,sBAAsB,CAAC,EAAE,kBAAkB,CAAC,KAAK,CAAC,GACjD,OAAO,CAAC,wBAAwB,CAAC,CAuDnC;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,eAAe,CAAC,EACpC,oBAAoB,EACpB,iBAAiB,GAClB,EAAE,kBAAkB,CAAC,eAAe,CAAC,GAAG,OAAO,CAAC,YAAY,CAAC,CA2B7D;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgGG;AACH,wBAAuB,kBAAkB,CAAC,EACxC,oBAAoB,EACpB,iBAAiB,GAClB,EAAE,kBAAkB,CACnB,eAAe,GAAG,4BAA4B,CAC/C,GAAG,cAAc,CAAC,qBAAqB,EAAE,YAAY,GAAG,SAAS,CAAC,CAiJlE;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,kBAAkB,CAAC,EACvC,oBAAoB,EACpB,iBAAiB,GAClB,EAAE,kBAAkB,CAAC,wBAAwB,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAwB9D;AA+BD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAsB,+BAA+B,CAAC,EACpD,oBAAoB,EACpB,iBAAiB,GAClB,EAAE,kBAAkB,CAAC,+BAA+B,CAAC,GAAG,OAAO,CAAC,qBAAqB,CAAC,CAyBtF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{tracker as e}from"../../../common/analytics/analytics-tracker.js";import{serializePaginationResponse as r}from"../../../common/api-pagination/api-pagination.js";import{authManager as n}from"../../../common/auth/auth.js";import{callProxyFunction as
|
|
1
|
+
import{tracker as e}from"../../../common/analytics/analytics-tracker.js";import{serializePaginationResponse as r}from"../../../common/api-pagination/api-pagination.js";import{authManager as n}from"../../../common/auth/auth.js";import{callProxyFunction as s}from"../../../common/common.utils.js";import{VOP_DECISIONS as o}from"../../../common/constants.js";import{isRunningInBrowser as t}from"../../../common/runtime/runtime.validation.js";import{validateClientOperationSettings as a}from"../../../validation/operation-settings-validation.js";import{InvalidRuntimeError as i,RUNTIME_ENVIRONMENT as p}from"../../../errors/InvalidRuntimeError.js";import{prepareCreateBulkTransferCall as c,prepareGetBulkTransfersCall as m,prepareVerifySepaPayeesCall as d,prepareGetBulkTransferCall as u}from"../shared/bulk-transfers.api.js";import{serializeToBulkVopVerificationResult as f,serializeBulkTransfer as l}from"../shared/bulk-transfers.serializer.js";import{validateCreateBulkTransferParams as k,validateBulkTransferParams as y}from"../shared/bulk-transfers.validate.js";import b from"../../../../node_modules/.pnpm/uuid@13.0.0/node_modules/uuid/dist/v4.js";async function T(n){e.sepaTransferBulkList();const{proxyEndpointDescriptor:o,paginationSettings:t}=a(n?.operationSettings,'Client-side bulk transfer operations require proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/server/sepa-transfers" and access sepaTransfers.bulkTransfers only in server-side/backend environments.'),i=m({paginationSettings:t}),p=await s({proxyEndpointDescriptor:o,networkCallDescriptor:i}),c=p.body.bulk_transfers.map(l),d=r(p.body.meta);return{bulkTransfers:c,...d?{meta:d}:{}}}async function v({bulkTransferSettings:r,operationSettings:n}){e.sepaTransferBulkGet();const o=y(r?.bulkTransferId),{proxyEndpointDescriptor:t}=a(n,'Client-side bulk transfer operations require proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/server/sepa-transfers" and access sepaTransfers.bulkTransfers only in server-side/backend environments.'),i=u({bulkTransferId:o}),p=await s({proxyEndpointDescriptor:t,networkCallDescriptor:i});return l(p.body.bulk_transfer)}async function*g({bulkTransferSettings:r,operationSettings:m}){e.sepaTransferBulkCreate();const{proxyEndpointDescriptor:u}=a(m,'Client-side bulk transfer operations require proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/server/sepa-transfers" and access sepaTransfers.bulkTransfers only in server-side/backend environments.');if(!t())throw new i(p.BROWSER);const y=n.getStagingToken(),T=m?.idempotencyKey||b();k(r);const v=new Map;for(const e of r.bulkTransfers){const r=e.beneficiary.iban;r&&!v.has(r)&&v.set(r,{name:e.beneficiary.name,iban:r})}const g=Array.from(v.values()),x=await async function({sepaPayees:e,proxyEndpointDescriptor:r}){const n=d({sepaPayees:e});return(await s({proxyEndpointDescriptor:r,networkCallDescriptor:n})).body}({sepaPayees:g,proxyEndpointDescriptor:u});if((yield x.requests.map(f))===o.REJECT)return;const D=c({bulkTransfers:r.bulkTransfers,bankAccountId:r.bankAccountId,stagingToken:y||void 0,idempotencyKey:T}),E=(await s({proxyEndpointDescriptor:u,networkCallDescriptor:D})).body.bulk_transfer;return{bulkTransfer:l(E),meta:{idempotencyKey:T}}}export{g as createBulkTransfer,v as getBulkTransfer,T as getBulkTransfers};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{authLinks as e}from"../../auth-links/index.js";import{tracker as r}from"../../common/analytics/analytics-tracker.js";import{serializePaginationResponse as
|
|
1
|
+
import{authLinks as e}from"../../auth-links/index.js";import{tracker as r}from"../../common/analytics/analytics-tracker.js";import{serializePaginationResponse as n}from"../../common/api-pagination/api-pagination.js";import{authManager as t}from"../../common/auth/auth.js";import{callProxyFunction as o}from"../../common/common.utils.js";import{VOP_DECISIONS as s,HTTP_CODES as i,AUTH_LINK_ACTIONS as a}from"../../common/constants.js";import{isRunningInBrowser as p}from"../../common/runtime/runtime.validation.js";import{validateClientOperationSettings as c}from"../../validation/operation-settings-validation.js";import{EmbedApiError as d}from"../../errors/EmbedApiError.js";import{InvalidParametersError as m}from"../../errors/InvalidParametersError.js";import{InvalidRuntimeError as f,RUNTIME_ENVIRONMENT as y}from"../../errors/InvalidRuntimeError.js";import{serializePreconditionRequiredResponse as l}from"../../sca/sca.serializer.js";import{prepareCreateSepaTransferCall as u,prepareGetSepaTransfersCall as k,prepareCancelSepaTransferCall as E,prepareGetSepaTransferCall as g,prepareVerifySepaPayeeCall as v}from"../shared/sepa-transfers.api.js";import{serializeToVopVerificationResult as b,serializeSepaTransfer as w}from"../shared/sepa-transfers.serializer.js";import{findBeneficiary as D,createSepaTransferScaElement as S,waitForSepaTransferScaResult as T,decorateUrlWithExtraParams as x}from"../shared/sepa-transfers.utils.js";import{validateTransferBeneficiaryParams as C,validateCreateSepaTransferParams as j,validateGetSepaTransferCreationFlowLinkParams as h,validateCancelSepaTransferParams as q,validateGetSepaTransferParams as I}from"../shared/sepa-transfers.validate.js";import"../../ui/ui-elements/sca-passkey/qonto-sca-passkey-waiting.js";import P from"../../../node_modules/.pnpm/uuid@13.0.0/node_modules/uuid/dist/v4.js";async function R(e){r.sepaTransferList();const{proxyEndpointDescriptor:t,paginationSettings:s}=c(e?.operationSettings,'Client-side operations require proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/server/sepa-transfers" only in server-side/backend environments.'),i=k({paginationSettings:s}),a=await o({proxyEndpointDescriptor:t,networkCallDescriptor:i}),p=a.body.transfers.map(w),d=n(a.body.meta);return{transfers:p,...d?{meta:d}:{}}}async function U({sepaTransferSettings:e,operationSettings:n}){r.sepaTransferGet();const t=I(e?.sepaTransferId),{proxyEndpointDescriptor:s}=c(n,'Client-side operations require proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/server/sepa-transfers" only in server-side/backend environments.'),i=g({sepaTransferId:t}),a=await o({proxyEndpointDescriptor:s,networkCallDescriptor:i});return w(a.body.transfer)}async function*F({sepaTransferSettings:e,operationSettings:n}){r.sepaTransferCreate();const{proxyEndpointDescriptor:a,uiParentElementId:k,locale:E}=c(n),g=t.getStagingToken(),x=n?.idempotencyKey||P();let h;C(e);const q=await D({sepaTransferSettings:e,operationSettings:n}),I={name:q.name,iban:q.iban},R=await async function({sepaPayee:e,operationSettings:r}){const{proxyEndpointDescriptor:n}=c(r,'Client-side operations require proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/server/sepa-transfers" only in server-side/backend environments.'),t=v({sepaPayee:e}),s=await o({proxyEndpointDescriptor:n,networkCallDescriptor:t});return s.body}({sepaPayee:I,operationSettings:n}),U=yield b(R);let F;if("string"==typeof U){if(U===s.REJECT)return}else{if(U.vopDecision===s.REJECT)return;F=U.sepaTransferSettings}const _={...e,...F};j(_);const A={..._,beneficiary:q};if(A.beneficiary?.trusted){const e=u({transfer:A,vopProofToken:R.proof_token.token,idempotencyKey:x});h=(await o({proxyEndpointDescriptor:a,networkCallDescriptor:e})).body.transfer}else{if(!p())throw new f(y.BROWSER);if(!k)throw new m("operationSettings.uiParentElementId is required for creating transfers to untrusted beneficiaries. This operation requires UI interaction for SCA.");const e=u({transfer:A,vopProofToken:R.proof_token.token,stagingToken:g||void 0,idempotencyKey:x});let r;try{h=(await o({proxyEndpointDescriptor:a,networkCallDescriptor:e})).body.transfer}catch(e){if(!(e instanceof d&&e.code===i.PRECONDITION_REQUIRED))throw e;r=l(e.data.body).scaSessionToken}const n=S({networkCallDescriptor:e,scaSessionToken:r,operationSettings:{uiParentElementId:k,locale:E}});try{h=await T(n)}finally{n.remove()}}return{transfer:w(h),meta:{idempotencyKey:x}}}async function _({sepaTransferSettings:e,operationSettings:n}){r.sepaTransferCancel();const t=q(e?.sepaTransferId),{proxyEndpointDescriptor:s}=c(n,'Client-side operations require proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/server/sepa-transfers" only in server-side/backend environments.'),i=E({sepaTransferId:t});await o({proxyEndpointDescriptor:s,networkCallDescriptor:i})}async function A({sepaTransferSettings:n,operationSettings:t}){r.sepaTransferCreationFlowLink();const o=h(n),{proxyEndpointDescriptor:s}=c(t,'Client-side operations require proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/server/sepa-transfers" only in server-side/backend environments.'),i=await e.request({requestSettings:{action:a.SEPA_TRANSFER_CREATE,callbackUrl:o},operationSettings:{proxyEndpointDescriptor:s}});return{...i,url:x(i.url,t)}}export{_ as cancelSepaTransfer,F as createSepaTransfer,U as getSepaTransfer,A as getSepaTransferCreationFlowLink,R as getSepaTransfers};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"../common/auth/auth.js";import{validatePresenceOfAuthToken as t}from"../common/auth/auth.validate.js";import{callProxyFunction as o}from"../common/common.utils.js";import{validateOperationSettingsParams as a}from"../validation/operation-settings-validation.js";import"../common/environment/environment-manager.js";import"../common/locale/locale-manager.js";import"../common/operation-settings/operation-settings.js";import{serializePaginationResponse as n}from"../common/api-pagination/api-pagination.js";import{prepareGetSepaTransfersCall as s,getSepaTransfers as i}from"./shared/sepa-transfers.api.js";import{serializeSepaTransfer as e}from"./shared/sepa-transfers.serializer.js";import"../ui/ui-elements/sca-passkey/qonto-sca-passkey-waiting.js";async function r(r){const{stagingToken:m,
|
|
1
|
+
import"../common/auth/auth.js";import{validatePresenceOfAuthToken as t}from"../common/auth/auth.validate.js";import{callProxyFunction as o}from"../common/common.utils.js";import{validateOperationSettingsParams as a}from"../validation/operation-settings-validation.js";import"../common/environment/environment-manager.js";import"../common/locale/locale-manager.js";import"../common/operation-settings/operation-settings.js";import{serializePaginationResponse as n}from"../common/api-pagination/api-pagination.js";import{prepareGetSepaTransfersCall as s,getSepaTransfers as i}from"./shared/sepa-transfers.api.js";import{serializeSepaTransfer as e}from"./shared/sepa-transfers.serializer.js";import"../ui/ui-elements/sca-passkey/qonto-sca-passkey-waiting.js";async function r(r){const{stagingToken:m,proxyEndpointDescriptor:p,accessToken:c,paginationSettings:g}=a(r?.operationSettings||{});if(p){const t=s({paginationSettings:g}),a=await o({proxyEndpointDescriptor:p,networkCallDescriptor:t}),i=a.body.transfers.map(e),r=n(a.body.meta);return{transfers:i,...r?{meta:r}:{}}}{const o=c||t(),a=await i({accessToken:o,stagingToken:m,paginationSettings:g}),s=a.transfers.map(e),r=n(a.meta);return{transfers:s,...r?{meta:r}:{}}}}export{r as getSepaTransfers};
|