@qonto/embed-sdk 0.61.0 → 0.63.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/cards/{cards.d.ts → client/cards.client.d.ts} +64 -89
- package/dist/cards/client/cards.client.d.ts.map +1 -0
- package/dist/cards/client/cards.client.test.d.ts +2 -0
- package/dist/cards/client/cards.client.test.d.ts.map +1 -0
- package/dist/cards/index.d.ts +40 -10
- package/dist/cards/index.d.ts.map +1 -1
- package/dist/cards/index.server.d.ts +41 -0
- package/dist/cards/index.server.d.ts.map +1 -0
- package/dist/cards/server/cards.server.d.ts +60 -0
- package/dist/cards/server/cards.server.d.ts.map +1 -0
- package/dist/cards/server/cards.server.test.d.ts +2 -0
- package/dist/cards/server/cards.server.test.d.ts.map +1 -0
- package/dist/cards/shared/cards.api.d.ts.map +1 -0
- package/dist/cards/shared/cards.constants.d.ts +11 -0
- package/dist/cards/shared/cards.constants.d.ts.map +1 -0
- package/dist/cards/{cards.helper.d.ts → shared/cards.helper.d.ts} +2 -0
- package/dist/cards/shared/cards.helper.d.ts.map +1 -0
- package/dist/cards/shared/cards.serializer.d.ts +35 -0
- package/dist/cards/shared/cards.serializer.d.ts.map +1 -0
- package/dist/cards/shared/cards.shared.test.d.ts +2 -0
- package/dist/cards/shared/cards.shared.test.d.ts.map +1 -0
- package/dist/cards/{cards.types.d.ts → shared/cards.types.d.ts} +3 -8
- package/dist/cards/shared/cards.types.d.ts.map +1 -0
- package/dist/cards/{cards.validate.d.ts → shared/cards.validate.d.ts} +1 -1
- package/dist/cards/shared/cards.validate.d.ts.map +1 -0
- package/dist/common/operation-settings/operation-settings.d.ts.map +1 -1
- package/dist/index.umd.js +3 -3
- package/dist/mocks/handlers.d.ts +2 -2
- package/dist/mocks/handlers.d.ts.map +1 -1
- package/dist/server/cards/{cards.d.ts → client/cards.client.d.ts} +64 -89
- package/dist/server/cards/client/cards.client.d.ts.map +1 -0
- package/dist/server/cards/client/cards.client.test.d.ts +2 -0
- package/dist/server/cards/client/cards.client.test.d.ts.map +1 -0
- package/dist/server/cards/index.d.ts +40 -10
- package/dist/server/cards/index.d.ts.map +1 -1
- package/dist/server/cards/index.server.d.ts +41 -0
- package/dist/server/cards/index.server.d.ts.map +1 -0
- package/dist/server/cards/server/cards.server.d.ts +60 -0
- package/dist/server/cards/server/cards.server.d.ts.map +1 -0
- package/dist/server/cards/server/cards.server.test.d.ts +2 -0
- package/dist/server/cards/server/cards.server.test.d.ts.map +1 -0
- package/dist/server/cards/shared/cards.api.d.ts.map +1 -0
- package/dist/server/cards/shared/cards.constants.d.ts +11 -0
- package/dist/server/cards/shared/cards.constants.d.ts.map +1 -0
- package/dist/server/cards/{cards.helper.d.ts → shared/cards.helper.d.ts} +2 -0
- package/dist/server/cards/shared/cards.helper.d.ts.map +1 -0
- package/dist/server/cards/shared/cards.serializer.d.ts +35 -0
- package/dist/server/cards/shared/cards.serializer.d.ts.map +1 -0
- package/dist/server/cards/shared/cards.shared.test.d.ts +2 -0
- package/dist/server/cards/shared/cards.shared.test.d.ts.map +1 -0
- package/dist/server/cards/{cards.types.d.ts → shared/cards.types.d.ts} +3 -8
- package/dist/{cards → server/cards/shared}/cards.types.d.ts.map +1 -1
- package/dist/server/cards/{cards.validate.d.ts → shared/cards.validate.d.ts} +1 -1
- package/dist/server/cards/shared/cards.validate.d.ts.map +1 -0
- package/dist/server/common/operation-settings/operation-settings.d.ts.map +1 -1
- package/dist/server/index.server.umd.js +1 -1
- package/dist/server/mocks/handlers.d.ts +2 -2
- package/dist/server/mocks/handlers.d.ts.map +1 -1
- package/dist/server/src/common/operation-settings/operation-settings.js +1 -1
- package/dist/{transactions/transactions.d.ts → server/transactions/client/transactions.client.d.ts} +33 -17
- package/dist/server/transactions/client/transactions.client.d.ts.map +1 -0
- package/dist/server/transactions/client/transactions.client.test.d.ts +2 -0
- package/dist/server/transactions/client/transactions.client.test.d.ts.map +1 -0
- package/dist/server/transactions/index.d.ts +14 -16
- package/dist/server/transactions/index.d.ts.map +1 -1
- package/dist/server/transactions/index.server.d.ts +45 -0
- package/dist/server/transactions/index.server.d.ts.map +1 -0
- package/dist/server/transactions/server/transactions.server.d.ts +70 -0
- package/dist/server/transactions/server/transactions.server.d.ts.map +1 -0
- package/dist/server/transactions/server/transactions.server.test.d.ts +2 -0
- package/dist/server/transactions/server/transactions.server.test.d.ts.map +1 -0
- package/dist/server/transactions/shared/transactions.api.d.ts.map +1 -0
- package/dist/server/transactions/shared/transactions.serializer.d.ts.map +1 -0
- package/dist/server/transactions/shared/transactions.shared.test.d.ts +2 -0
- package/dist/server/transactions/shared/transactions.shared.test.d.ts.map +1 -0
- package/dist/server/transactions/shared/transactions.types.d.ts.map +1 -0
- package/dist/server/transactions/shared/transactions.validation.d.ts +3 -0
- package/dist/server/transactions/shared/transactions.validation.d.ts.map +1 -0
- package/dist/server/types/types.public-api.d.ts +2 -2
- package/dist/server/types/types.public-api.d.ts.map +1 -1
- package/dist/server/ui/ui-elements/transaction-list/create-transaction-list-element.d.ts +1 -1
- package/dist/server/ui/ui-elements/transaction-list/create-transaction-list-element.d.ts.map +1 -1
- package/dist/server/ui/ui-elements/transaction-list/transaction-list.d.ts.map +1 -1
- package/dist/src/cards/client/cards.client.js +1 -0
- package/dist/src/cards/index.js +1 -1
- package/dist/src/cards/shared/cards.api.js +1 -0
- package/dist/src/cards/shared/cards.constants.js +1 -0
- package/dist/src/cards/shared/cards.helper.js +1 -0
- package/dist/src/cards/shared/cards.serializer.js +1 -0
- package/dist/src/cards/{cards.types.js → shared/cards.types.js} +1 -1
- package/dist/src/cards/shared/cards.validate.js +1 -0
- package/dist/src/common/operation-settings/operation-settings.js +1 -1
- package/dist/src/transactions/client/transactions.client.js +1 -0
- package/dist/src/transactions/index.js +1 -1
- package/dist/src/transactions/shared/transactions.api.js +1 -0
- package/dist/src/transactions/shared/transactions.validation.js +1 -0
- package/dist/src/ui/ui-elements/transaction-list/transaction-list.js +2 -2
- package/dist/{server/transactions/transactions.d.ts → transactions/client/transactions.client.d.ts} +33 -17
- package/dist/transactions/client/transactions.client.d.ts.map +1 -0
- package/dist/transactions/client/transactions.client.test.d.ts +2 -0
- package/dist/transactions/client/transactions.client.test.d.ts.map +1 -0
- package/dist/transactions/index.d.ts +14 -16
- package/dist/transactions/index.d.ts.map +1 -1
- package/dist/transactions/index.server.d.ts +45 -0
- package/dist/transactions/index.server.d.ts.map +1 -0
- package/dist/transactions/server/transactions.server.d.ts +70 -0
- package/dist/transactions/server/transactions.server.d.ts.map +1 -0
- package/dist/transactions/server/transactions.server.test.d.ts +2 -0
- package/dist/transactions/server/transactions.server.test.d.ts.map +1 -0
- package/dist/transactions/shared/transactions.api.d.ts.map +1 -0
- package/dist/transactions/shared/transactions.serializer.d.ts.map +1 -0
- package/dist/transactions/shared/transactions.shared.test.d.ts +2 -0
- package/dist/transactions/shared/transactions.shared.test.d.ts.map +1 -0
- package/dist/transactions/shared/transactions.types.d.ts.map +1 -0
- package/dist/transactions/shared/transactions.validation.d.ts +3 -0
- package/dist/transactions/shared/transactions.validation.d.ts.map +1 -0
- package/dist/types/types.public-api.d.ts +2 -2
- package/dist/types/types.public-api.d.ts.map +1 -1
- package/dist/ui/ui-elements/transaction-list/create-transaction-list-element.d.ts +1 -1
- package/dist/ui/ui-elements/transaction-list/create-transaction-list-element.d.ts.map +1 -1
- package/dist/ui/ui-elements/transaction-list/transaction-list.d.ts.map +1 -1
- package/package.json +9 -1
- package/dist/cards/cards.api.d.ts.map +0 -1
- package/dist/cards/cards.d.ts.map +0 -1
- package/dist/cards/cards.helper.d.ts.map +0 -1
- package/dist/cards/cards.public-api.d.ts +0 -10
- package/dist/cards/cards.public-api.d.ts.map +0 -1
- package/dist/cards/cards.serializer.d.ts +0 -72
- package/dist/cards/cards.serializer.d.ts.map +0 -1
- package/dist/cards/cards.test.d.ts +0 -2
- package/dist/cards/cards.test.d.ts.map +0 -1
- package/dist/cards/cards.validate.d.ts.map +0 -1
- package/dist/server/cards/cards.api.d.ts.map +0 -1
- package/dist/server/cards/cards.d.ts.map +0 -1
- package/dist/server/cards/cards.helper.d.ts.map +0 -1
- package/dist/server/cards/cards.public-api.d.ts +0 -10
- package/dist/server/cards/cards.public-api.d.ts.map +0 -1
- package/dist/server/cards/cards.serializer.d.ts +0 -72
- package/dist/server/cards/cards.serializer.d.ts.map +0 -1
- package/dist/server/cards/cards.test.d.ts +0 -2
- package/dist/server/cards/cards.test.d.ts.map +0 -1
- package/dist/server/cards/cards.types.d.ts.map +0 -1
- package/dist/server/cards/cards.validate.d.ts.map +0 -1
- package/dist/server/transactions/transactions.api.d.ts.map +0 -1
- package/dist/server/transactions/transactions.d.ts.map +0 -1
- package/dist/server/transactions/transactions.public-api.d.ts +0 -8
- package/dist/server/transactions/transactions.public-api.d.ts.map +0 -1
- package/dist/server/transactions/transactions.serializer.d.ts.map +0 -1
- package/dist/server/transactions/transactions.test.d.ts +0 -2
- package/dist/server/transactions/transactions.test.d.ts.map +0 -1
- package/dist/server/transactions/transactions.types.d.ts.map +0 -1
- package/dist/server/transactions/transactions.validation.d.ts +0 -3
- package/dist/server/transactions/transactions.validation.d.ts.map +0 -1
- package/dist/src/cards/cards.api.js +0 -1
- package/dist/src/cards/cards.helper.js +0 -1
- package/dist/src/cards/cards.js +0 -1
- package/dist/src/cards/cards.public-api.js +0 -1
- package/dist/src/cards/cards.serializer.js +0 -1
- package/dist/src/cards/cards.validate.js +0 -1
- package/dist/src/transactions/transactions.api.js +0 -1
- package/dist/src/transactions/transactions.js +0 -1
- package/dist/src/transactions/transactions.public-api.js +0 -1
- package/dist/src/transactions/transactions.validation.js +0 -1
- package/dist/transactions/transactions.api.d.ts.map +0 -1
- package/dist/transactions/transactions.d.ts.map +0 -1
- package/dist/transactions/transactions.public-api.d.ts +0 -8
- package/dist/transactions/transactions.public-api.d.ts.map +0 -1
- package/dist/transactions/transactions.serializer.d.ts.map +0 -1
- package/dist/transactions/transactions.test.d.ts +0 -2
- package/dist/transactions/transactions.test.d.ts.map +0 -1
- package/dist/transactions/transactions.types.d.ts.map +0 -1
- package/dist/transactions/transactions.validation.d.ts +0 -3
- package/dist/transactions/transactions.validation.d.ts.map +0 -1
- /package/dist/cards/{cards.api.d.ts → shared/cards.api.d.ts} +0 -0
- /package/dist/server/cards/{cards.api.d.ts → shared/cards.api.d.ts} +0 -0
- /package/dist/server/transactions/{transactions.api.d.ts → shared/transactions.api.d.ts} +0 -0
- /package/dist/server/transactions/{transactions.serializer.d.ts → shared/transactions.serializer.d.ts} +0 -0
- /package/dist/server/transactions/{transactions.types.d.ts → shared/transactions.types.d.ts} +0 -0
- /package/dist/src/transactions/{transactions.serializer.js → shared/transactions.serializer.js} +0 -0
- /package/dist/transactions/{transactions.api.d.ts → shared/transactions.api.d.ts} +0 -0
- /package/dist/transactions/{transactions.serializer.d.ts → shared/transactions.serializer.d.ts} +0 -0
- /package/dist/transactions/{transactions.types.d.ts → shared/transactions.types.d.ts} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{VIRTUAL_CARD_LEVEL as t,PHYSICAL_CARD_LEVEL as i}from"./cards.constants.js";import{isVirtualCardOrderSettings as n}from"./cards.helper.js";import{validateExpectedStringValues as e,validateExpectedBooleanValues as a,validatePresenceOfRequiredParams as r,validateExpectedNumericValues as o}from"../../validation/input-param-validation.js";import{InvalidParametersError as s}from"../../errors/InvalidParametersError.js";const c=[{name:"organizationId"},{name:"membershipId"},{name:"bankAccountId"},{name:"monthlyLimit"},{name:"cardLevel"}],m=[...c,{name:"atmDailyLimit",requiredIfPresent:"hasAtmDailyLimit"},{name:"hasAtmDailyLimit",requiredIfPresent:"hasAtmOption"},{name:"atmMonthlyLimit",requiredIfPresent:"hasAtmOption"},{name:"shipToBusiness"},{name:"cardLevel"}];function d(d){if(!d)throw new s("cardSettings parameter is required for the called function");return n(d)?function(i){return r(i,c),function(i){const{membershipId:n,organizationId:r,bankAccountId:c,hasDailyLimit:m,hasTransactionLimit:d,monthlyLimit:l,dailyLimit:f,transactionLimit:y,activeDays:p,categories:L,cardLevel:w}=i,I=function(i){return i!==t.VIRTUAL?['cardLevel must be "virtual"']:[]}(w),g=e({membershipId:n,organizationId:r,bankAccountId:c}),v=a({hasDailyLimit:m,hasTransactionLimit:d}),b=o({monthlyLimit:l,dailyLimit:f,transactionLimit:y}),A=u(p),D=h(L),O=[...I,...g,...v,...b,...A,...D];if(O.length>0)throw new s(O)}(i),i}(d):function(t){r(t,m),function(t){const{membershipId:n,organizationId:r,bankAccountId:c,hasDailyLimit:m,hasTransactionLimit:d,monthlyLimit:l,dailyLimit:f,transactionLimit:y,activeDays:p,categories:L,cardLevel:w,hasNfcOption:I,hasForeignPaymentOption:g,hasOnlinePaymentOption:v,shipToBusiness:b,hasAtmOption:A,hasAtmDailyLimit:D,atmDailyLimit:O,atmMonthlyLimit:P,address:q,cardDesign:k,typeOfPrint:T}=t,z=function(t){return Object.values(i).includes(t)?[]:['cardLevel must be one of "standard", "plus", "metal"']}(w),B=function(t){const i=null!=t&&"string"!=typeof t,n=!["print","embossed",void 0,null].includes(t);return i||n?['typeOfPrint must be one of "print", "embossed" or null']:[]}(T),j=e({membershipId:n,organizationId:r,bankAccountId:c}),N=a({hasDailyLimit:m,hasTransactionLimit:d,hasAtmOption:A,hasNfcOption:I,hasForeignPaymentOption:g,hasOnlinePaymentOption:v,hasAtmDailyLimit:D,shipToBusiness:b}),R=o({monthlyLimit:l,dailyLimit:f,transactionLimit:y,atmDailyLimit:O,atmMonthlyLimit:P}),S=u(p),M=h(L),C=function(t){return["undefined","string"].includes(typeof t)?[]:["cardDesign must be a string"]}(k),F=function(t,i){if(i)return[];return!t||t.contactName&&t.firstLine&&t.zipCode&&t.city&&t.country?[]:["address must contain at least contactName, firstLine, zipCode, city and country properties"]}(q,b),x=[...z,...j,...N,...R,...S,...M,...B,...C,...F];if(x.length>0)throw new s(x)}(t)}(d)}function l(t){if(!t)throw new s("cardSettings parameter is required for the called function");if(!t.cardId)throw new s("cardId is required for the called function");const i=e({cardId:t.cardId});if(i.length>0)throw new s(i)}function u(t){const i=!Array.isArray(t)||!t.every((t=>Number.isInteger(t)&&t>0&&t<8));return void 0!==t&&i?["activeDays must be an array of integers between 1 and 7"]:[]}function h(t){const i=!Array.isArray(t)||t.some((t=>"string"!=typeof t));return void 0!==t&&i?["categories must be an array of strings"]:[]}function f(t){if(!t)throw new s("cardSettings parameter is required for the called function");if(!t.cardId)throw new s("cardId is required for the called function");const i=e({cardId:t.cardId});if(i.length>0)throw new s(i);let n={};void 0!==t.allowPinReveal&&(n={allowPinReveal:t.allowPinReveal}),void 0!==t.allowBlocking&&(n={...n,allowBlocking:t.allowBlocking});const r=a(n);if(r.length>0)throw new s(r);return t}function y(t){if(!t)throw new s("cardSettings parameter is required for the called function");if(!t.cardId)throw new s("cardId parameter is required for the called function");const i=e({cardId:t.cardId});if(i.length>0)throw new s(i);return t}export{f as validateDisplayCardParams,y as validateGetCardParams,d as validateOrderCardParams,l as validateUnlockCardParams};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{MFA_METHODS as e}from"../constants.js";class t{constructor(){this.mfaPreference=e.PASSKEY,this.debugMode=!1}static getInstance(){return t.instance||(t.instance=new t),t.instance}setSettings(e){e.uiParentElementId&&(this.uiParentElementId=e.uiParentElementId),e.mfaPreference&&(this.mfaPreference=e.mfaPreference),e.debugMode&&(this.debugMode=e.debugMode),e.proxyRequestFunction&&(this.proxyRequestFunction=e.proxyRequestFunction),e.proxyEndpointDescriptor&&(this.proxyEndpointDescriptor=e.proxyEndpointDescriptor)}getUIParentElementId(){return this.uiParentElementId}getMFAPreference(){return this.mfaPreference}getDebugMode(){return this.debugMode}getProxyRequestFunction(){return this.proxyRequestFunction}getProxyEndpointDescriptor(){return this.proxyEndpointDescriptor}clearSettings(){this.uiParentElementId=void 0,this.mfaPreference=e.PASSKEY,this.debugMode=!1,this.proxyRequestFunction=void 0}getSettings(){return{uiParentElementId:this.uiParentElementId,mfaPreference:this.mfaPreference,debugMode:this.debugMode,proxyRequestFunction:this.proxyRequestFunction}}}const n=t.getInstance();export{t as OperationSettingsManager,n as operationSettingsManager};
|
|
1
|
+
import{MFA_METHODS as e}from"../constants.js";class t{constructor(){this.mfaPreference=e.PASSKEY,this.debugMode=!1}static getInstance(){return t.instance||(t.instance=new t),t.instance}setSettings(e){e.uiParentElementId&&(this.uiParentElementId=e.uiParentElementId),e.mfaPreference&&(this.mfaPreference=e.mfaPreference),e.debugMode&&(this.debugMode=e.debugMode),e.proxyRequestFunction&&(this.proxyRequestFunction=e.proxyRequestFunction),e.proxyEndpointDescriptor&&(this.proxyEndpointDescriptor=e.proxyEndpointDescriptor)}getUIParentElementId(){return this.uiParentElementId}getMFAPreference(){return this.mfaPreference}getDebugMode(){return this.debugMode}getProxyRequestFunction(){return this.proxyRequestFunction}getProxyEndpointDescriptor(){return this.proxyEndpointDescriptor}clearSettings(){this.uiParentElementId=void 0,this.mfaPreference=e.PASSKEY,this.debugMode=!1,this.proxyRequestFunction=void 0,this.proxyEndpointDescriptor=void 0}getSettings(){return{uiParentElementId:this.uiParentElementId,mfaPreference:this.mfaPreference,debugMode:this.debugMode,proxyRequestFunction:this.proxyRequestFunction}}}const n=t.getInstance();export{t as OperationSettingsManager,n as operationSettingsManager};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{serializePaginationResponse as n}from"../../common/api-pagination/api-pagination.js";import{callProxyFunction as t}from"../../common/common.utils.js";import{validateClientOperationSettings as o}from"../../validation/operation-settings-validation.js";import{prepareGetTransactionsCall as r,prepareGetTransactionCall as i}from"../shared/transactions.api.js";import{serializeTransaction as e}from"../shared/transactions.serializer.js";import{validateGetTransactionParams as s}from"../shared/transactions.validation.js";async function a(i){const{proxyRequestFunction:s,proxyEndpointDescriptor:a,paginationSettings:p}=o(i?.operationSettings||{},'Client-side transaction operations require either proxyRequestFunction or proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/transactions/server" only in server-side/backend environments.'),c={...i?.transactionSettings||{},paginationSettings:p},d=r(c),m=await t({proxyFunction:s,proxyEndpointDescriptor:a,networkCallDescriptor:d});return{transactions:m.body.transactions.map(e),meta:n(m.body.meta)}}async function p({transactionSettings:n,operationSettings:r}){const{proxyRequestFunction:a,proxyEndpointDescriptor:p}=o(r||{},'Client-side transaction operations require either proxyRequestFunction or proxyEndpointDescriptor. For security, never expose access tokens in the browser. Use "@qonto/embed-sdk/transactions/server" only in server-side/backend environments.'),{transactionId:c}=s(n),d=i({transactionId:c}),m=await t({proxyFunction:a,proxyEndpointDescriptor:p,networkCallDescriptor:d});return e(m.body.transaction)}export{p as getTransaction,a as getTransactions};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{getTransactions as t,getTransaction as n}from"./client/transactions.client.js";const o={getTransactions:t,getTransaction:n};export{o as transactions};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{buildPaginationParams as t}from"../../common/api-pagination/api-pagination.js";import"../../common/auth/auth.js";import"../../common/environment/environment-manager.js";import"../../common/locale/locale-manager.js";import"../../common/operation-settings/operation-settings.js";const n="/v2/transactions";function e({bankAccountId:e,iban:o,status:a,updatedAtFrom:p,updatedAtTo:s,emittedAtFrom:i,emittedAtTo:d,settledAtFrom:m,settledAtTo:r,side:c,operationType:g,withAttachments:_,paginationSettings:u,accessToken:T,stagingToken:h}){const k={method:"GET",headers:{accessToken:T,stagingToken:h}},f=new URLSearchParams;e&&f.append("bank_account_id",e),o&&f.append("iban",o),a&&f.append("status",a),p&&f.append("updated_at_from",p),s&&f.append("updated_at_to",s),i&&f.append("emitted_at_from",i),d&&f.append("emitted_at_to",d),m&&f.append("settled_at_from",m),r&&f.append("settled_at_to",r),c&&f.append("side",c),g&&f.append("operation_type",g),void 0!==_&&f.append("with_attachments",String(_));const l=t(u);for(const[t,n]of l)f.append(t,n);const A=f.toString();return{path:`${n}${A?`?${A}`:""}`,options:k}}function o({transactionId:t,accessToken:e,stagingToken:o}){return{path:`${n}/${t}`,options:{method:"GET",headers:{accessToken:e,stagingToken:o}}}}export{o as prepareGetTransactionCall,e as prepareGetTransactionsCall};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{InvalidParametersError as t}from"../../errors/InvalidParametersError.js";function r(r){if(!r)throw new t("transactionSettings parameter is required for the called function");if(!r.transactionId)throw new t("transactionSettings.transactionId parameter is required for the called function");if(r.transactionId&&"string"!=typeof r.transactionId)throw new t("transactionSettings.transactionId must be a string.");return r}export{r as validateGetTransactionParams};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{__decorate as t}from"../../../../node_modules/.pnpm/@rollup_plugin-typescript@12.1.2_rollup@4.39.0_tslib@2.8.1_typescript@5.8.3/node_modules/tslib/tslib.es6.js";import{str as e}from"../../../../node_modules/.pnpm/@lit_localize@0.12.2/node_modules/@lit/localize/internal/str-tag.js";import{msg as o}from"../../../../node_modules/.pnpm/@lit_localize@0.12.2/node_modules/@lit/localize/init/install.js";import{localized as i}from"../../../../node_modules/.pnpm/@lit_localize@0.12.2/node_modules/@lit/localize/internal/localized-decorator.js";import"../../../../node_modules/.pnpm/@lit_localize@0.12.2/node_modules/@lit/localize/init/runtime.js";import"../../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/reactive-element.js";import{html as a}from"../../../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.js";import{LitElement as
|
|
1
|
+
import{__decorate as t}from"../../../../node_modules/.pnpm/@rollup_plugin-typescript@12.1.2_rollup@4.39.0_tslib@2.8.1_typescript@5.8.3/node_modules/tslib/tslib.es6.js";import{str as e}from"../../../../node_modules/.pnpm/@lit_localize@0.12.2/node_modules/@lit/localize/internal/str-tag.js";import{msg as o}from"../../../../node_modules/.pnpm/@lit_localize@0.12.2/node_modules/@lit/localize/init/install.js";import{localized as i}from"../../../../node_modules/.pnpm/@lit_localize@0.12.2/node_modules/@lit/localize/internal/localized-decorator.js";import"../../../../node_modules/.pnpm/@lit_localize@0.12.2/node_modules/@lit/localize/init/runtime.js";import{transactions as n}from"../../../transactions/index.js";import"../../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/reactive-element.js";import{html as a}from"../../../../node_modules/.pnpm/lit-html@3.3.1/node_modules/lit-html/lit-html.js";import{LitElement as s}from"../../../../node_modules/.pnpm/lit-element@4.2.1/node_modules/lit-element/lit-element.js";import{customElement as l}from"../../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/custom-element.js";import{property as r}from"../../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/property.js";import{state as d}from"../../../../node_modules/.pnpm/@lit_reactive-element@2.1.1/node_modules/@lit/reactive-element/decorators/state.js";import{formatDate as p}from"../../customizable-components/utils/format-date.js";import{TransactionSelectedEvent as m}from"./transaction-list.events.js";import{tableStyles as c}from"../../customizable-components/styles/component-styles/table-styles.js";import{renderLoadingTableRowsMarkup as h}from"../list-utils/list.utils.js";import{setLocale as u,getLocale as g}from"../localize/configure-localization.js";import"../../customizable-components/styles/styles.css.js";import"../../customizable-components/button/qonto-button.js";import"../../customizable-components/text/qonto-text-body.js";let y=class extends s{constructor(){super(...arguments),this.isLoading=!1}connectedCallback(){super.connectedCallback(),u(this.operationSettings?.locale||"en"),this.fetchTransactions()}updated(t){t.has("locale")&&u(this.operationSettings?.locale||"en")}async fetchTransactions(t){if(this.operationSettings){this.isLoading=!0,this.error=void 0;try{const{paginationSettings:e={}}=this.operationSettings,o=await n.getTransactions({transactionSettings:this.transactionSettings,operationSettings:{proxyRequestFunction:this.operationSettings.proxyRequestFunction,proxyEndpointDescriptor:this.operationSettings.proxyEndpointDescriptor,locale:this.operationSettings.locale,paginationSettings:{page:t??e.page??1,itemsPerPage:e.itemsPerPage??20}}});this.transactions=o.transactions,this.paginationState=o.meta}catch(t){console.error("Failed to load transactions:",t),this.error=o("Failed to load transactions. Please try again.")}finally{this.isLoading=!1}}else console.error("operationSettings is required to fetch transfers")}handleRowClick(t){this.dispatchEvent(new m({transaction:t}))}handlePreviousPage(){this.paginationState?.previousPage&&(this.transactions=void 0,this.fetchTransactions(this.paginationState.previousPage))}handleNextPage(){this.paginationState?.nextPage&&(this.transactions=void 0,this.fetchTransactions(this.paginationState.nextPage))}render(){return this.error?a`<qonto-text-body
|
|
2
2
|
data-variant="error"
|
|
3
3
|
data-display-level="body"
|
|
4
4
|
>${this.error}</qonto-text-body
|
|
@@ -47,4 +47,4 @@ import{__decorate as t}from"../../../../node_modules/.pnpm/@rollup_plugin-typesc
|
|
|
47
47
|
>${o("Next")}</qonto-button
|
|
48
48
|
</div>
|
|
49
49
|
</div>`:""}
|
|
50
|
-
`}};y.styles=c,t([
|
|
50
|
+
`}};y.styles=c,t([r({type:Object})],y.prototype,"operationSettings",void 0),t([r({type:Object})],y.prototype,"transactionSettings",void 0),t([d()],y.prototype,"transactions",void 0),t([d()],y.prototype,"paginationState",void 0),t([d()],y.prototype,"isLoading",void 0),t([d()],y.prototype,"error",void 0),y=t([i(),l("qonto-transaction-list")],y);export{y as TransactionList};
|
package/dist/{server/transactions/transactions.d.ts → transactions/client/transactions.client.d.ts}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import type { GetTransactionSettings, GetTransactionsResponse, GetTransactionsSettings, Transaction } from '
|
|
1
|
+
import { type ClientOperationSettings } from '@validation/operation-settings-validation';
|
|
2
|
+
import type { GetTransactionSettings, GetTransactionsResponse, GetTransactionsSettings, Transaction } from '../shared/transactions.types';
|
|
3
3
|
/**
|
|
4
4
|
* This is the common parameter format all the transaction functions expect
|
|
5
5
|
* as their only parameter. It consists of a `transactionSettings` object and an
|
|
@@ -7,6 +7,11 @@ import type { GetTransactionSettings, GetTransactionsResponse, GetTransactionsSe
|
|
|
7
7
|
* properties will be different depending on the function being called. Read the
|
|
8
8
|
* docs of each transaction related function to see the expected properties of
|
|
9
9
|
* the `transactionSettings` object.
|
|
10
|
+
*
|
|
11
|
+
* @remarks
|
|
12
|
+
* This is the client-side implementation that uses the proxy endpoint mechanism.
|
|
13
|
+
* For security, never expose access tokens in the browser.
|
|
14
|
+
* Use "\@qonto/embed-sdk/transactions/server" only in server-side/backend environments.
|
|
10
15
|
*/
|
|
11
16
|
export interface TransactionParams<T> {
|
|
12
17
|
/**
|
|
@@ -15,42 +20,53 @@ export interface TransactionParams<T> {
|
|
|
15
20
|
* this object.
|
|
16
21
|
*/
|
|
17
22
|
transactionSettings?: T;
|
|
18
|
-
|
|
23
|
+
/**
|
|
24
|
+
* Client-side operation settings. Must include `proxyEndpointDescriptor`.
|
|
25
|
+
*/
|
|
26
|
+
operationSettings?: ClientOperationSettings;
|
|
19
27
|
}
|
|
20
28
|
/**
|
|
21
29
|
* Fetches the list of transactions for the current user with optional filtering.
|
|
30
|
+
*
|
|
31
|
+
* @remarks
|
|
32
|
+
* This is the client-side implementation that requires `proxyEndpointDescriptor`.
|
|
33
|
+
* For security, never expose access tokens in the browser.
|
|
34
|
+
* Use "\@qonto/embed-sdk/transactions/server" only in server-side/backend environments.
|
|
35
|
+
*
|
|
22
36
|
* @param getTransactionsParams - An object containing:
|
|
23
37
|
* - `transactionSettings`: An object with optional filtering parameters such as
|
|
24
38
|
* `bankAccountId`, `iban`, `status`, `side`, `operationType`, date ranges, and
|
|
25
39
|
* attachment filters.
|
|
26
|
-
* - `operationSettings`: An object with operation-level settings
|
|
27
|
-
* `
|
|
28
|
-
* `
|
|
29
|
-
*
|
|
30
|
-
* `paginationSettings` property under `operationSettings`, which accepts an
|
|
31
|
-
* object with the page and itemsPerPage properties. See {@link TransactionParams}.
|
|
40
|
+
* - `operationSettings`: An object with operation-level settings including
|
|
41
|
+
* `proxyEndpointDescriptor` (required), and optional
|
|
42
|
+
* `paginationSettings` for managing pagination (accepts an object with `page`
|
|
43
|
+
* and `itemsPerPage` properties). See {@link TransactionParams}.
|
|
32
44
|
* @returns A promise that resolves to an array of transactions and a `meta`
|
|
33
45
|
* object containing pagination state.
|
|
34
46
|
* @throws `InvalidParametersError` If any of the values provided under
|
|
35
47
|
* operationSettings or transactionSettings is invalid.
|
|
36
|
-
* @throws `AuthenticationError` If
|
|
37
|
-
* `
|
|
48
|
+
* @throws `AuthenticationError` If
|
|
49
|
+
* `proxyEndpointDescriptor` is missing within `operationSettings`.
|
|
38
50
|
* @throws `EmbedApiError` If the API request fails or returns an error.
|
|
39
51
|
*/
|
|
40
52
|
export declare function getTransactions(getTransactionsParams?: TransactionParams<GetTransactionsSettings>): Promise<GetTransactionsResponse>;
|
|
41
53
|
/**
|
|
42
54
|
* Fetches a single transaction of the current user by ID.
|
|
55
|
+
*
|
|
56
|
+
* @remarks
|
|
57
|
+
* This is the client-side implementation that requires `proxyEndpointDescriptor`.
|
|
58
|
+
* For security, never expose access tokens in the browser.
|
|
59
|
+
* Use "\@qonto/embed-sdk/transactions/server" only in server-side/backend environments.
|
|
60
|
+
*
|
|
43
61
|
* @param getTransactionParams - An object containing:
|
|
44
62
|
* - `transactionSettings`: An object with the `transactionId` property (string).
|
|
45
|
-
* - `operationSettings`: An object with operation-level settings
|
|
46
|
-
* `
|
|
47
|
-
* `accessToken`, `stagingToken`, `mfaPreference`, and other optional parameters.
|
|
63
|
+
* - `operationSettings`: An object with operation-level settings including
|
|
64
|
+
* `proxyEndpointDescriptor` (required).
|
|
48
65
|
* See {@link TransactionParams}.
|
|
49
66
|
* @returns A promise that resolves to a transaction.
|
|
50
67
|
* @throws `InvalidParametersError` If the `transactionId` parameter is not a string or is missing.
|
|
51
|
-
* @throws `AuthenticationError` If
|
|
52
|
-
* `operationSettings`.
|
|
68
|
+
* @throws `AuthenticationError` If `proxyEndpointDescriptor` is missing within `operationSettings`.
|
|
53
69
|
* @throws `EmbedApiError` If the API request fails or returns an error.
|
|
54
70
|
*/
|
|
55
71
|
export declare function getTransaction({ transactionSettings, operationSettings, }: TransactionParams<GetTransactionSettings>): Promise<Transaction>;
|
|
56
|
-
//# sourceMappingURL=transactions.d.ts.map
|
|
72
|
+
//# sourceMappingURL=transactions.client.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.client.d.ts","sourceRoot":"","sources":["../../../src/transactions/client/transactions.client.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,KAAK,uBAAuB,EAE7B,MAAM,2CAA2C,CAAC;AAOnD,OAAO,KAAK,EACV,sBAAsB,EACtB,uBAAuB,EACvB,uBAAuB,EACvB,WAAW,EAEZ,MAAM,8BAA8B,CAAC;AAGtC;;;;;;;;;;;;GAYG;AACH,MAAM,WAAW,iBAAiB,CAAC,CAAC;IAClC;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,CAAC,CAAC;IACxB;;OAEG;IACH,iBAAiB,CAAC,EAAE,uBAAuB,CAAC;CAC7C;AAED;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,wBAAsB,eAAe,CACnC,qBAAqB,CAAC,EAAE,iBAAiB,CAAC,uBAAuB,CAAC,GACjE,OAAO,CAAC,uBAAuB,CAAC,CA6BlC;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAsB,cAAc,CAAC,EACnC,mBAAmB,EACnB,iBAAiB,GAClB,EAAE,iBAAiB,CAAC,sBAAsB,CAAC,GAAG,OAAO,CAAC,WAAW,CAAC,CAwBlE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.client.test.d.ts","sourceRoot":"","sources":["../../../src/transactions/client/transactions.client.test.ts"],"names":[],"mappings":""}
|
|
@@ -1,6 +1,10 @@
|
|
|
1
|
+
import { getTransaction, getTransactions } from './client/transactions.client';
|
|
1
2
|
/**
|
|
2
|
-
* The transactions namespace contains all the functions related to transaction operations.
|
|
3
|
-
*
|
|
3
|
+
* The transactions namespace contains all the client-side functions related to transaction operations.
|
|
4
|
+
* This version uses proxy-based authentication (proxyEndpointDescriptor)
|
|
5
|
+
* and is designed for browser environments.
|
|
6
|
+
*
|
|
7
|
+
* For server-side operations using access tokens, import from '\@qonto/embed-sdk/server/transactions'.
|
|
4
8
|
*
|
|
5
9
|
* It can be accessed like this:
|
|
6
10
|
* ```ts
|
|
@@ -17,12 +21,9 @@
|
|
|
17
21
|
* bankAccountId: 'account_123'
|
|
18
22
|
* },
|
|
19
23
|
* operationSettings: {
|
|
20
|
-
* // For client side authentication, you
|
|
21
|
-
* //
|
|
22
|
-
* //
|
|
23
|
-
* proxyRequestFunction: async (payload: string) => {}
|
|
24
|
-
* // Or, for server side authentication, you can provide an access token directly
|
|
25
|
-
* accessToken: 'your_token'
|
|
24
|
+
* // For client side authentication, you must provide a proxy endpoint descriptor (recommended for
|
|
25
|
+
* // security reasons). Read more in the Proxy endpoint descriptor implementation documentation.
|
|
26
|
+
* // proxyEndpointDescriptor: { path: '/v2/transactions', method: 'GET' }
|
|
26
27
|
* }
|
|
27
28
|
* });
|
|
28
29
|
*
|
|
@@ -30,18 +31,15 @@
|
|
|
30
31
|
* const transaction = await transactions.getTransaction({
|
|
31
32
|
* transactionSettings: { transactionId: 'txn_123' },
|
|
32
33
|
* operationSettings: {
|
|
33
|
-
*
|
|
34
|
-
* // security reasons). Read more in <a href="https://docs.qonto.com/api-reference/sdk-libraries/doc-pages/proxy-endpoint-implementation">Proxy request implementation</a>
|
|
35
|
-
* // article.
|
|
36
|
-
* proxyRequestFunction: async (payload: string) => {}
|
|
37
|
-
* // Or, for server side authentication, you can provide an access token directly
|
|
38
|
-
* accessToken: 'your_token'
|
|
34
|
+
* proxyEndpointDescriptor: { path: '/v2/transactions/:transactionId', method: 'GET' }
|
|
39
35
|
* }
|
|
40
36
|
* });
|
|
41
37
|
* ```
|
|
42
38
|
*/
|
|
43
39
|
export declare const transactions: {
|
|
44
|
-
getTransactions: typeof
|
|
45
|
-
getTransaction: typeof
|
|
40
|
+
getTransactions: typeof getTransactions;
|
|
41
|
+
getTransaction: typeof getTransaction;
|
|
46
42
|
};
|
|
43
|
+
export type * from './shared/transactions.types';
|
|
44
|
+
export type { ClientOperationSettings, ClientOperationSettingsWithUI, } from '@validation/operation-settings-validation';
|
|
47
45
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/transactions/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/transactions/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAE/E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AACH,eAAO,MAAM,YAAY;;;CAGxB,CAAC;AAGF,mBAAmB,6BAA6B,CAAC;AACjD,YAAY,EACV,uBAAuB,EACvB,6BAA6B,GAC9B,MAAM,2CAA2C,CAAC"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { getTransaction, getTransactions } from './server/transactions.server';
|
|
2
|
+
/**
|
|
3
|
+
* The transactions namespace contains all the server-side functions related to transaction operations.
|
|
4
|
+
* This version uses access token-based authentication and is designed for server environments.
|
|
5
|
+
*
|
|
6
|
+
* For client-side operations using proxy functions, import from '\@qonto/embed-sdk/transactions'.
|
|
7
|
+
*
|
|
8
|
+
* It can be accessed like this:
|
|
9
|
+
* ```ts
|
|
10
|
+
* import { transactions } from '@qonto/embed-sdk/server/transactions';
|
|
11
|
+
* ```
|
|
12
|
+
*
|
|
13
|
+
* Then, the transactions object contains the functions to perform transaction operations:
|
|
14
|
+
* ```ts
|
|
15
|
+
* // Fetch all transactions with optional filtering
|
|
16
|
+
* const { transactions: txns, meta } = await transactions.getTransactions({
|
|
17
|
+
* transactionSettings: {
|
|
18
|
+
* status: 'completed',
|
|
19
|
+
* side: 'debit',
|
|
20
|
+
* bankAccountId: 'account_123'
|
|
21
|
+
* },
|
|
22
|
+
* operationSettings: {
|
|
23
|
+
* // For server side authentication, you can provide an access token directly
|
|
24
|
+
* accessToken: 'your_token',
|
|
25
|
+
* // Optional staging token for testing
|
|
26
|
+
* stagingToken: 'staging_token'
|
|
27
|
+
* }
|
|
28
|
+
* });
|
|
29
|
+
*
|
|
30
|
+
* // Fetch a specific transaction by ID
|
|
31
|
+
* const transaction = await transactions.getTransaction({
|
|
32
|
+
* transactionSettings: { transactionId: 'txn_123' },
|
|
33
|
+
* operationSettings: {
|
|
34
|
+
* accessToken: 'your_token'
|
|
35
|
+
* }
|
|
36
|
+
* });
|
|
37
|
+
* ```
|
|
38
|
+
*/
|
|
39
|
+
export declare const transactions: {
|
|
40
|
+
getTransactions: typeof getTransactions;
|
|
41
|
+
getTransaction: typeof getTransaction;
|
|
42
|
+
};
|
|
43
|
+
export type * from './shared/transactions.types';
|
|
44
|
+
export type { ServerOperationSettings } from '@validation/operation-settings-validation';
|
|
45
|
+
//# sourceMappingURL=index.server.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.server.d.ts","sourceRoot":"","sources":["../../src/transactions/index.server.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAE/E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AACH,eAAO,MAAM,YAAY;;;CAGxB,CAAC;AAGF,mBAAmB,6BAA6B,CAAC;AACjD,YAAY,EAAE,uBAAuB,EAAE,MAAM,2CAA2C,CAAC"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import type { ServerOperationSettings } from '@validation/operation-settings-validation';
|
|
2
|
+
import type { GetTransactionSettings, GetTransactionsResponse, GetTransactionsSettings, Transaction } from '../shared/transactions.types';
|
|
3
|
+
/**
|
|
4
|
+
* This is the common parameter format all the transaction functions expect
|
|
5
|
+
* as their only parameter. It consists of a `transactionSettings` object and an
|
|
6
|
+
* optional `operationSettings` object. The `transactionSettings` object's
|
|
7
|
+
* properties will be different depending on the function being called. Read the
|
|
8
|
+
* docs of each transaction related function to see the expected properties of
|
|
9
|
+
* the `transactionSettings` object.
|
|
10
|
+
*
|
|
11
|
+
* @remarks
|
|
12
|
+
* This is the server-side implementation that uses the access token flow.
|
|
13
|
+
* For client-side usage with proxy functions, import from '\@qonto/embed-sdk/transactions'.
|
|
14
|
+
*/
|
|
15
|
+
export interface TransactionParams<T> {
|
|
16
|
+
/**
|
|
17
|
+
* An object with the parameters relevant to different transaction operations.
|
|
18
|
+
* Read the documentation of each function to see the expected properties of
|
|
19
|
+
* this object.
|
|
20
|
+
*/
|
|
21
|
+
transactionSettings?: T;
|
|
22
|
+
/**
|
|
23
|
+
* Server-side operation settings. Can include `accessToken` and `stagingToken`.
|
|
24
|
+
* If not provided, falls back to globally configured authentication.
|
|
25
|
+
*/
|
|
26
|
+
operationSettings?: ServerOperationSettings;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Fetches the list of transactions for the current user with optional filtering.
|
|
30
|
+
*
|
|
31
|
+
* @remarks
|
|
32
|
+
* This is the server-side implementation that uses access tokens. For client-side
|
|
33
|
+
* usage with proxy functions, import from '\@qonto/embed-sdk/transactions'.
|
|
34
|
+
*
|
|
35
|
+
* @param getTransactionsParams - An object containing:
|
|
36
|
+
* - `transactionSettings`: An object with optional filtering parameters such as
|
|
37
|
+
* `bankAccountId`, `iban`, `status`, `side`, `operationType`, date ranges, and
|
|
38
|
+
* attachment filters.
|
|
39
|
+
* - `operationSettings`: An object with operation-level settings including optional
|
|
40
|
+
* `accessToken` and `stagingToken`. Also allows managing pagination by passing the
|
|
41
|
+
* `paginationSettings` property, which accepts an object with `page` and
|
|
42
|
+
* `itemsPerPage` properties. See {@link TransactionParams}.
|
|
43
|
+
* @returns A promise that resolves to an array of transactions and a `meta`
|
|
44
|
+
* object containing pagination state.
|
|
45
|
+
* @throws `InvalidParametersError` If any of the values provided under
|
|
46
|
+
* operationSettings or transactionSettings is invalid.
|
|
47
|
+
* @throws `AuthenticationError` If no valid access token is available (neither in
|
|
48
|
+
* `operationSettings` nor globally configured).
|
|
49
|
+
* @throws `EmbedApiError` If the API request fails or returns an error.
|
|
50
|
+
*/
|
|
51
|
+
export declare function getTransactions(getTransactionsParams?: TransactionParams<GetTransactionsSettings>): Promise<GetTransactionsResponse>;
|
|
52
|
+
/**
|
|
53
|
+
* Fetches a single transaction of the current user by ID.
|
|
54
|
+
*
|
|
55
|
+
* @remarks
|
|
56
|
+
* This is the server-side implementation that uses access tokens. For client-side
|
|
57
|
+
* usage with proxy functions, import from '\@qonto/embed-sdk/transactions'.
|
|
58
|
+
*
|
|
59
|
+
* @param getTransactionParams - An object containing:
|
|
60
|
+
* - `transactionSettings`: An object with the `transactionId` property (string).
|
|
61
|
+
* - `operationSettings`: An object with operation-level settings including optional
|
|
62
|
+
* `accessToken` and `stagingToken`. See {@link TransactionParams}.
|
|
63
|
+
* @returns A promise that resolves to a transaction.
|
|
64
|
+
* @throws `InvalidParametersError` If the `transactionId` parameter is not a string or is missing.
|
|
65
|
+
* @throws `AuthenticationError` If no valid access token is available (neither in
|
|
66
|
+
* `operationSettings` nor globally configured).
|
|
67
|
+
* @throws `EmbedApiError` If the API request fails or returns an error.
|
|
68
|
+
*/
|
|
69
|
+
export declare function getTransaction({ transactionSettings, operationSettings, }: TransactionParams<GetTransactionSettings>): Promise<Transaction>;
|
|
70
|
+
//# sourceMappingURL=transactions.server.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.server.d.ts","sourceRoot":"","sources":["../../../src/transactions/server/transactions.server.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,2CAA2C,CAAC;AAOzF,OAAO,KAAK,EACV,sBAAsB,EACtB,uBAAuB,EACvB,uBAAuB,EACvB,WAAW,EACZ,MAAM,8BAA8B,CAAC;AAGtC;;;;;;;;;;;GAWG;AACH,MAAM,WAAW,iBAAiB,CAAC,CAAC;IAClC;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,CAAC,CAAC;IACxB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,uBAAuB,CAAC;CAC7C;AAED;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAsB,eAAe,CACnC,qBAAqB,CAAC,EAAE,iBAAiB,CAAC,uBAAuB,CAAC,GACjE,OAAO,CAAC,uBAAuB,CAAC,CAqBlC;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAsB,cAAc,CAAC,EACnC,mBAAmB,EACnB,iBAAiB,GAClB,EAAE,iBAAiB,CAAC,sBAAsB,CAAC,GAAG,OAAO,CAAC,WAAW,CAAC,CAalE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.server.test.d.ts","sourceRoot":"","sources":["../../../src/transactions/server/transactions.server.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.api.d.ts","sourceRoot":"","sources":["../../../src/transactions/shared/transactions.api.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,4BAA4B,EAC5B,kBAAkB,EACnB,MAAM,6CAA6C,CAAC;AACrD,OAAO,EACL,KAAK,qBAAqB,EAE3B,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2CAA2C,CAAC;AAEnF,OAAO,KAAK,EACV,sBAAsB,EACtB,uBAAuB,EACvB,qBAAqB,EACtB,MAAM,sBAAsB,CAAC;AAE9B,UAAU,qBAAsB,SAAQ,uBAAuB;IAC7D,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;CACzC;AAED,UAAU,oBAAqB,SAAQ,sBAAsB;IAC3D,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,UAAU,0BAA0B;IAClC,YAAY,EAAE,qBAAqB,EAAE,CAAC;IACtC,IAAI,EAAE,4BAA4B,CAAC;CACpC;AAED,KAAK,yBAAyB,GAAG,qBAAqB,GAAG,iBAAiB,CAAC;AAI3E,wBAAgB,0BAA0B,CAAC,EACzC,aAAa,EACb,IAAI,EACJ,MAAM,EACN,aAAa,EACb,WAAW,EACX,aAAa,EACb,WAAW,EACX,aAAa,EACb,WAAW,EACX,IAAI,EACJ,aAAa,EACb,eAAe,EACf,kBAAkB,EAClB,WAAW,EACX,YAAY,GACb,EAAE,yBAAyB,GAAG,qBAAqB,CAqCnD;AAED,wBAAsB,eAAe,CACnC,MAAM,EAAE,qBAAqB,GAC5B,OAAO,CAAC,0BAA0B,CAAC,CAYrC;AAED,wBAAgB,yBAAyB,CAAC,EACxC,aAAa,EACb,WAAW,EACX,YAAY,GACb,EAAE,oBAAoB,GAAG,qBAAqB,CAW9C;AAED,wBAAsB,cAAc,CAClC,MAAM,EAAE,oBAAoB,GAC3B,OAAO,CAAC,qBAAqB,CAAC,CAQhC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.serializer.d.ts","sourceRoot":"","sources":["../../../src/transactions/shared/transactions.serializer.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,WAAW,EAChB,KAAK,qBAAqB,EAC3B,MAAM,sBAAsB,CAAC;AAE9B;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAClC,eAAe,EAAE,qBAAqB,GACrC,WAAW,CAkDb"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.shared.test.d.ts","sourceRoot":"","sources":["../../../src/transactions/shared/transactions.shared.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.types.d.ts","sourceRoot":"","sources":["../../../src/transactions/shared/transactions.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,6CAA6C,CAAC;AACnF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAA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,MAAM,CAAC;IACrB,8EAA8E;IAC9E,IAAI,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC;IAC1B,kFAAkF;IAClF,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,sEAAsE;IACtE,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC,wDAAwD;IACxD,aAAa,EAAE,MAAM,CAAC;CACvB;AAED;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAC3B,CAAC,OAAO,oBAAoB,CAAC,CAAC,MAAM,OAAO,oBAAoB,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transactions.validation.d.ts","sourceRoot":"","sources":["../../../src/transactions/shared/transactions.validation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAGnE,wBAAgB,4BAA4B,CAC1C,MAAM,EAAE,sBAAsB,GAAG,SAAS,GACzC,sBAAsB,CAiBxB"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import type { AuthLinkRequestParams, AuthLinkRequestResult, AuthLinkRequestSettings, PostAuthAction } from '@auth-links/shared/auth-links.types';
|
|
2
2
|
import type { Beneficiary, GetBeneficiariesResponse } from '@beneficiaries/shared/beneficiaries.types';
|
|
3
|
-
import type { Card, CardOrderSettings, PhysicalCardOrderSettings, VirtualCardOrderSettings } from '@cards/cards.types';
|
|
3
|
+
import type { Card, CardOrderSettings, PhysicalCardOrderSettings, VirtualCardOrderSettings } from '@cards/shared/cards.types';
|
|
4
4
|
import type { PaginationState } from '@common/api-pagination/api-pagination.types';
|
|
5
5
|
import type { Locale } from '@common/locale/locale.types';
|
|
6
6
|
import type { ACCOUNT_STATUS, BankAccount } from '@organizations/shared/organizations.types';
|
|
7
7
|
import type { CreatePaymentLinkSettings, Item, PaymentLinkParams } from '@payment-links/payment-links.types';
|
|
8
8
|
import type { CreateSepaTransferResponse, GetSepaTransfersResponse, NewSepaTransfer, SepaTransfer, SepaTransferStatus, VopCheckResult, VopVerificationResult } from '@sepa-transfers/shared/sepa-transfers.types';
|
|
9
|
-
import type { GetTransactionSettings, GetTransactionsResponse, GetTransactionsSettings, Transaction, TransactionDataObject } from '@transactions/transactions.types';
|
|
9
|
+
import type { GetTransactionSettings, GetTransactionsResponse, GetTransactionsSettings, Transaction, TransactionDataObject } from '@transactions/shared/transactions.types';
|
|
10
10
|
export type { Card, VirtualCardOrderSettings, PhysicalCardOrderSettings, CardOrderSettings, Beneficiary, GetBeneficiariesResponse, SepaTransfer, SepaTransferStatus, NewSepaTransfer, GetSepaTransfersResponse, CreateSepaTransferResponse, Transaction, TransactionDataObject, GetTransactionsResponse, GetTransactionsSettings, GetTransactionSettings, VopVerificationResult, VopCheckResult, PaginationState, Locale, BankAccount, ACCOUNT_STATUS, Item, CreatePaymentLinkSettings, PaymentLinkParams, AuthLinkRequestParams, AuthLinkRequestResult, AuthLinkRequestSettings, PostAuthAction, };
|
|
11
11
|
//# sourceMappingURL=types.public-api.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.public-api.d.ts","sourceRoot":"","sources":["../../src/types/types.public-api.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,cAAc,EACf,MAAM,qCAAqC,CAAC;AAE7C,OAAO,KAAK,EACV,WAAW,EACX,wBAAwB,EACzB,MAAM,2CAA2C,CAAC;AAEnD,OAAO,KAAK,EACV,IAAI,EACJ,iBAAiB,EACjB,yBAAyB,EACzB,wBAAwB,EACzB,MAAM,
|
|
1
|
+
{"version":3,"file":"types.public-api.d.ts","sourceRoot":"","sources":["../../src/types/types.public-api.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,cAAc,EACf,MAAM,qCAAqC,CAAC;AAE7C,OAAO,KAAK,EACV,WAAW,EACX,wBAAwB,EACzB,MAAM,2CAA2C,CAAC;AAEnD,OAAO,KAAK,EACV,IAAI,EACJ,iBAAiB,EACjB,yBAAyB,EACzB,wBAAwB,EACzB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,6CAA6C,CAAC;AACnF,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAE1D,OAAO,KAAK,EACV,cAAc,EACd,WAAW,EACZ,MAAM,2CAA2C,CAAC;AAEnD,OAAO,KAAK,EACV,yBAAyB,EACzB,IAAI,EACJ,iBAAiB,EAClB,MAAM,oCAAoC,CAAC;AAE5C,OAAO,KAAK,EACV,0BAA0B,EAC1B,wBAAwB,EACxB,eAAe,EACf,YAAY,EACZ,kBAAkB,EAClB,cAAc,EACd,qBAAqB,EACtB,MAAM,6CAA6C,CAAC;AAErD,OAAO,KAAK,EACV,sBAAsB,EACtB,uBAAuB,EACvB,uBAAuB,EACvB,WAAW,EACX,qBAAqB,EACtB,MAAM,yCAAyC,CAAC;AAEjD,YAAY,EACV,IAAI,EACJ,wBAAwB,EACxB,yBAAyB,EACzB,iBAAiB,EACjB,WAAW,EACX,wBAAwB,EACxB,YAAY,EACZ,kBAAkB,EAClB,eAAe,EACf,wBAAwB,EACxB,0BAA0B,EAC1B,WAAW,EACX,qBAAqB,EACrB,uBAAuB,EACvB,uBAAuB,EACvB,sBAAsB,EACtB,qBAAqB,EACrB,cAAc,EACd,eAAe,EACf,MAAM,EACN,WAAW,EACX,cAAc,EACd,IAAI,EACJ,yBAAyB,EACzB,iBAAiB,EACjB,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,cAAc,GACf,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import './transaction-list';
|
|
2
|
-
import type { GetTransactionsSettings } from '@transactions/transactions.types';
|
|
2
|
+
import type { GetTransactionsSettings } from '@transactions/shared/transactions.types';
|
|
3
3
|
import type { UIElementCreatorParams } from '@ui/ui-elements.types';
|
|
4
4
|
/**
|
|
5
5
|
* Creates and renders a transaction list UI element.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-transaction-list-element.d.ts","sourceRoot":"","sources":["../../../../src/ui/ui-elements/transaction-list/create-transaction-list-element.ts"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,CAAC;AAG5B,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"create-transaction-list-element.d.ts","sourceRoot":"","sources":["../../../../src/ui/ui-elements/transaction-list/create-transaction-list-element.ts"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,CAAC;AAG5B,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,yCAAyC,CAAC;AAEvF,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAIpE;;;;;;;;GAQG;AACH,wBAAgB,4BAA4B,CAAC,EAC3C,gBAAgB,EAChB,iBAAiB,EACjB,iBAAiB,GAClB,EAAE,sBAAsB,CAAC,uBAAuB,CAAC,GAAG,IAAI,CAyBxD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transaction-list.d.ts","sourceRoot":"","sources":["../../../../src/ui/ui-elements/transaction-list/transaction-list.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"transaction-list.d.ts","sourceRoot":"","sources":["../../../../src/ui/ui-elements/transaction-list/transaction-list.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,uBAAuB,EAGxB,MAAM,QAAQ,CAAC;AAChB,OAAO,EAAE,UAAU,EAAQ,MAAM,KAAK,CAAC;AAKvC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2CAA2C,CAAC;AAMnF,OAAO,iDAAiD,CAAC;AACzD,OAAO,sDAAsD,CAAC;AAC9D,OAAO,uDAAuD,CAAC;AAE/D,qBAEa,eAAgB,SAAQ,UAAU;IAC7C,MAAM,CAAC,MAAM,0BAAe;IAG5B,iBAAiB,EAAE,iBAAiB,GAAG,SAAS,CAAC;IAGjD,mBAAmB,EAAE,uBAAuB,GAAG,SAAS,CAAC;IAGzD,OAAO,CAAC,YAAY,CAA4B;IAGhD,OAAO,CAAC,eAAe,CAA8B;IAGrD,OAAO,CAAC,SAAS,CAAkB;IAGnC,OAAO,CAAC,KAAK,CAAqB;IAElC,iBAAiB;IAMjB,OAAO,CAAC,iBAAiB,EAAE,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC;YAMjC,iBAAiB;IAkC/B,OAAO,CAAC,cAAc;IAItB,OAAO,CAAC,kBAAkB;IAO1B,OAAO,CAAC,cAAc;IAOtB,MAAM;CAsEP"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@qonto/embed-sdk",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.63.0",
|
|
4
4
|
"description": "Library to embed Qonto features in your application",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -18,6 +18,10 @@
|
|
|
18
18
|
"types": "./dist/cards/index.d.ts",
|
|
19
19
|
"import": "./dist/src/cards/index.js"
|
|
20
20
|
},
|
|
21
|
+
"./server/cards": {
|
|
22
|
+
"types": "./dist/server/cards/index.server.d.ts",
|
|
23
|
+
"import": "./dist/server/src/cards/index.server.js"
|
|
24
|
+
},
|
|
21
25
|
"./beneficiaries": {
|
|
22
26
|
"types": "./dist/beneficiaries/index.d.ts",
|
|
23
27
|
"import": "./dist/src/beneficiaries/index.js"
|
|
@@ -38,6 +42,10 @@
|
|
|
38
42
|
"types": "./dist/transactions/index.d.ts",
|
|
39
43
|
"import": "./dist/src/transactions/index.js"
|
|
40
44
|
},
|
|
45
|
+
"./server/transactions": {
|
|
46
|
+
"types": "./dist/server/transactions/index.server.d.ts",
|
|
47
|
+
"import": "./dist/server/src/transactions/index.server.js"
|
|
48
|
+
},
|
|
41
49
|
"./auth-links": {
|
|
42
50
|
"types": "./dist/auth-links/index.d.ts",
|
|
43
51
|
"import": "./dist/src/auth-links/index.js"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cards.api.d.ts","sourceRoot":"","sources":["../../src/cards/cards.api.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAC;AAInF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAErE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2CAA2C,CAAC;AAEnF,OAAO,KAAK,EAAE,cAAc,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAEzE,UAAU,cAAc;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,UAAU,aAAa;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,UAAU,6BAA6B;IACrC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,MAAM,sBAAsB,GAAG,mBAAmB,GACtD,IAAI,CAAC,iBAAiB,EAAE,aAAa,GAAG,cAAc,GAAG,eAAe,CAAC,CAAC;AAE5E,wBAAgB,mBAAmB,CAAC,EAClC,YAAY,EACZ,WAAW,EACX,YAAY,GACb,EAAE;IACD,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB,GAAG,qBAAqB,CAiBxB;AAED,wBAAsB,QAAQ,CAAC,EAC7B,YAAY,EACZ,WAAW,EACX,YAAY,GACb,EAAE,cAAc,GAAG,OAAO,CAAC,cAAc,EAAE,CAAC,CAY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@ -1,10 +0,0 @@
|
|
|
1
|
-
import { displayCard, getCard, getCards, orderCard, unlockCard } from './cards';
|
|
2
|
-
declare const cards: {
|
|
3
|
-
getCards: typeof getCards;
|
|
4
|
-
getCard: typeof getCard;
|
|
5
|
-
orderCard: typeof orderCard;
|
|
6
|
-
unlockCard: typeof unlockCard;
|
|
7
|
-
displayCard: typeof displayCard;
|
|
8
|
-
};
|
|
9
|
-
export { cards };
|
|
10
|
-
//# sourceMappingURL=cards.public-api.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cards.public-api.d.ts","sourceRoot":"","sources":["../../src/cards/cards.public-api.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAEhF,QAAA,MAAM,KAAK;;;;;;CAMV,CAAC;AAEF,OAAO,EAAE,KAAK,EAAE,CAAC"}
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import { type Card, type CardDataObject, type CardOrderSettings, type UnlockCardSettings } from '@cards/cards.types';
|
|
2
|
-
import type { CardParams } from './cards';
|
|
3
|
-
export declare function serializeOrderCardPayload(payload: CardOrderSettings): {
|
|
4
|
-
actionId: string;
|
|
5
|
-
actionData: {
|
|
6
|
-
idempotencyKey: string;
|
|
7
|
-
body: {
|
|
8
|
-
card: {
|
|
9
|
-
payment_monthly_limit: number;
|
|
10
|
-
payment_daily_limit: number | undefined;
|
|
11
|
-
payment_daily_limit_option: boolean | undefined;
|
|
12
|
-
payment_transaction_limit: number | undefined;
|
|
13
|
-
payment_transaction_limit_option: boolean | undefined;
|
|
14
|
-
active_days: number[];
|
|
15
|
-
holder_id: string;
|
|
16
|
-
organization_id: string;
|
|
17
|
-
bank_account_id: string;
|
|
18
|
-
categories: string[];
|
|
19
|
-
card_level: import("@cards/cards.types").VirtualCardLevel;
|
|
20
|
-
};
|
|
21
|
-
};
|
|
22
|
-
};
|
|
23
|
-
} | {
|
|
24
|
-
actionId: string;
|
|
25
|
-
actionData: {
|
|
26
|
-
idempotencyKey: string;
|
|
27
|
-
body: {
|
|
28
|
-
card: {
|
|
29
|
-
address?: {
|
|
30
|
-
contact_name: string | undefined;
|
|
31
|
-
first_line: string | undefined;
|
|
32
|
-
second_line: string | undefined;
|
|
33
|
-
third_line: string | undefined;
|
|
34
|
-
zipcode: string | undefined;
|
|
35
|
-
city: string | undefined;
|
|
36
|
-
country: string | undefined;
|
|
37
|
-
} | undefined;
|
|
38
|
-
ship_to_business_address: boolean;
|
|
39
|
-
atm_option: boolean | undefined;
|
|
40
|
-
nfc_option: boolean | undefined;
|
|
41
|
-
foreign_option: boolean | undefined;
|
|
42
|
-
online_option: boolean | undefined;
|
|
43
|
-
atm_daily_limit: number | undefined;
|
|
44
|
-
atm_monthly_limit: number | undefined;
|
|
45
|
-
type_of_print?: ("embossed" | "print" | null) | undefined;
|
|
46
|
-
payment_monthly_limit: number;
|
|
47
|
-
payment_daily_limit: number | undefined;
|
|
48
|
-
payment_daily_limit_option: boolean | undefined;
|
|
49
|
-
payment_transaction_limit: number | undefined;
|
|
50
|
-
payment_transaction_limit_option: boolean | undefined;
|
|
51
|
-
active_days: number[];
|
|
52
|
-
holder_id: string;
|
|
53
|
-
organization_id: string;
|
|
54
|
-
bank_account_id: string;
|
|
55
|
-
categories: string[];
|
|
56
|
-
card_level: import("@cards/cards.types").PhysicalCardLevel;
|
|
57
|
-
card_design: ("standard.recycled.plastic.2023" | "plus.black.2023" | "plus.recycled.plastic.silver.2023" | "plus.recycled.plastic.black.2023" | "plus.recycled.plastic.lilac.2023" | "metal.graphite.black.2019" | "metal.mineral.gray.2024" | "metal.sand.gold.2024" | "virtual.default.2017" | "virtual.blueberry.2025" | "virtual.sakura.2025" | "virtual.plum.2025" | "virtual.dawn.2025" | "virtual.together.or.nothing.2025" | "virtual.gus.gus.2025" | "virtual.forever.bound.2025" | "virtual.puzzle.2025" | "flash.default.2021" | "advertising.default.2023") | undefined;
|
|
58
|
-
};
|
|
59
|
-
};
|
|
60
|
-
};
|
|
61
|
-
};
|
|
62
|
-
export declare function serializeCard(cardDataObject: CardDataObject): Card;
|
|
63
|
-
export declare function filterValidCategories(categories: string[] | undefined): string[];
|
|
64
|
-
export declare function serializeUnlockCardPayload(payload: CardParams<UnlockCardSettings>): {
|
|
65
|
-
actionId: string;
|
|
66
|
-
actionData: {
|
|
67
|
-
body: {
|
|
68
|
-
cardId: string;
|
|
69
|
-
};
|
|
70
|
-
};
|
|
71
|
-
};
|
|
72
|
-
//# sourceMappingURL=cards.serializer.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cards.serializer.d.ts","sourceRoot":"","sources":["../../src/cards/cards.serializer.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,IAAI,EAET,KAAK,cAAc,EACnB,KAAK,iBAAiB,EAEtB,KAAK,kBAAkB,EAExB,MAAM,oBAAoB,CAAC;AAI5B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAE1C,wBAAgB,yBAAyB,CAAC,OAAO,EAAE,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAMnE;AA8ED,wBAAgB,aAAa,CAAC,cAAc,EAAE,cAAc,GAAG,IAAI,CA2DlE;AAED,wBAAgB,qBAAqB,CAAC,UAAU,EAAE,MAAM,EAAE,GAAG,SAAS,YAKrE;AAED,wBAAgB,0BAA0B,CACxC,OAAO,EAAE,UAAU,CAAC,kBAAkB,CAAC;;;;;;;EAUxC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cards.test.d.ts","sourceRoot":"","sources":["../../src/cards/cards.test.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cards.validate.d.ts","sourceRoot":"","sources":["../../src/cards/cards.validate.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EAGxB,KAAK,kBAAkB,EACvB,KAAK,wBAAwB,EAC9B,MAAM,oBAAoB,CAAC;AA2B5B,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,iBAAiB,mCAWhE;AAED,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,kBAAkB,QAelE;AA2ND,wBAAgB,yBAAyB,CAAC,MAAM,EAAE,mBAAmB,uBAkCpE;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CAAC,MAAM,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;YAAR,MAAM;EAiB7D"}
|