@develit-services/bank 0.0.24 → 0.0.26
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/export/worker.cjs +1 -1
- package/dist/export/worker.d.cts +4 -4
- package/dist/export/worker.d.mts +4 -4
- package/dist/export/worker.d.ts +4 -4
- package/dist/export/worker.mjs +1 -1
- package/dist/shared/{bank.B5x2DseV.mjs → bank.C03cnXOh.mjs} +3 -3
- package/dist/shared/{bank.2vXXoFi2.cjs → bank.CfvkOFs5.cjs} +3 -3
- package/dist/types.cjs +1 -1
- package/dist/types.mjs +1 -1
- package/package.json +1 -1
package/dist/export/worker.cjs
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const backendSdk = require('@develit-io/backend-sdk');
|
|
6
|
-
const db = require('../shared/bank.
|
|
6
|
+
const db = require('../shared/bank.CfvkOFs5.cjs');
|
|
7
7
|
const cloudflare_workers = require('cloudflare:workers');
|
|
8
8
|
const d1 = require('drizzle-orm/d1');
|
|
9
9
|
const zod = require('zod');
|
package/dist/export/worker.d.cts
CHANGED
|
@@ -242,15 +242,15 @@ declare class BankServiceBase extends BankServiceBase_base {
|
|
|
242
242
|
paymentsToBatch: SendPaymentInput[];
|
|
243
243
|
}): Promise<IRPCResponse<{
|
|
244
244
|
status: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | null;
|
|
245
|
+
batchPaymentInitiatedAt: Date | null;
|
|
246
|
+
authorizationUrls: string | string[] | null;
|
|
245
247
|
accountId: string | null;
|
|
248
|
+
payments: PaymentInsertType[];
|
|
249
|
+
metadata: object | null;
|
|
246
250
|
id: string;
|
|
247
251
|
createdAt: Date | null;
|
|
248
252
|
updatedAt: Date | null;
|
|
249
253
|
deletedAt: Date | null;
|
|
250
|
-
batchPaymentInitiatedAt: Date | null;
|
|
251
|
-
authorizationUrls: string | string[] | null;
|
|
252
|
-
payments: PaymentInsertType[];
|
|
253
|
-
metadata: object | null;
|
|
254
254
|
}[] | undefined>>;
|
|
255
255
|
processBatch(input: ProcessBatchInput): Promise<IRPCResponse<void>>;
|
|
256
256
|
queue(b: MessageBatch<SendPaymentInput>): Promise<void>;
|
package/dist/export/worker.d.mts
CHANGED
|
@@ -242,15 +242,15 @@ declare class BankServiceBase extends BankServiceBase_base {
|
|
|
242
242
|
paymentsToBatch: SendPaymentInput[];
|
|
243
243
|
}): Promise<IRPCResponse<{
|
|
244
244
|
status: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | null;
|
|
245
|
+
batchPaymentInitiatedAt: Date | null;
|
|
246
|
+
authorizationUrls: string | string[] | null;
|
|
245
247
|
accountId: string | null;
|
|
248
|
+
payments: PaymentInsertType[];
|
|
249
|
+
metadata: object | null;
|
|
246
250
|
id: string;
|
|
247
251
|
createdAt: Date | null;
|
|
248
252
|
updatedAt: Date | null;
|
|
249
253
|
deletedAt: Date | null;
|
|
250
|
-
batchPaymentInitiatedAt: Date | null;
|
|
251
|
-
authorizationUrls: string | string[] | null;
|
|
252
|
-
payments: PaymentInsertType[];
|
|
253
|
-
metadata: object | null;
|
|
254
254
|
}[] | undefined>>;
|
|
255
255
|
processBatch(input: ProcessBatchInput): Promise<IRPCResponse<void>>;
|
|
256
256
|
queue(b: MessageBatch<SendPaymentInput>): Promise<void>;
|
package/dist/export/worker.d.ts
CHANGED
|
@@ -242,15 +242,15 @@ declare class BankServiceBase extends BankServiceBase_base {
|
|
|
242
242
|
paymentsToBatch: SendPaymentInput[];
|
|
243
243
|
}): Promise<IRPCResponse<{
|
|
244
244
|
status: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | null;
|
|
245
|
+
batchPaymentInitiatedAt: Date | null;
|
|
246
|
+
authorizationUrls: string | string[] | null;
|
|
245
247
|
accountId: string | null;
|
|
248
|
+
payments: PaymentInsertType[];
|
|
249
|
+
metadata: object | null;
|
|
246
250
|
id: string;
|
|
247
251
|
createdAt: Date | null;
|
|
248
252
|
updatedAt: Date | null;
|
|
249
253
|
deletedAt: Date | null;
|
|
250
|
-
batchPaymentInitiatedAt: Date | null;
|
|
251
|
-
authorizationUrls: string | string[] | null;
|
|
252
|
-
payments: PaymentInsertType[];
|
|
253
|
-
metadata: object | null;
|
|
254
254
|
}[] | undefined>>;
|
|
255
255
|
processBatch(input: ProcessBatchInput): Promise<IRPCResponse<void>>;
|
|
256
256
|
queue(b: MessageBatch<SendPaymentInput>): Promise<void>;
|
package/dist/export/worker.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { uuidv4, useResult, createInternalError, develitWorker, first, RPCResponse, action, service } from '@develit-io/backend-sdk';
|
|
2
|
-
import { P as PAYMENT_TYPES, t as tables, F as FinbricksConnector, M as MockConnector, a as MockCobsConnector, E as ErsteConnector, g as getPaymentDirection } from '../shared/bank.
|
|
2
|
+
import { P as PAYMENT_TYPES, t as tables, F as FinbricksConnector, M as MockConnector, a as MockCobsConnector, E as ErsteConnector, g as getPaymentDirection } from '../shared/bank.C03cnXOh.mjs';
|
|
3
3
|
import { WorkerEntrypoint } from 'cloudflare:workers';
|
|
4
4
|
import { drizzle } from 'drizzle-orm/d1';
|
|
5
5
|
import { z } from 'zod';
|
|
@@ -198,7 +198,7 @@ const mapFinbricksBatchStatus = (status) => {
|
|
|
198
198
|
};
|
|
199
199
|
const mapFinbricksTransactionToPayment = (tx, account) => {
|
|
200
200
|
const isIncoming = tx.creditDebitIndicator === "CRDT";
|
|
201
|
-
const related = tx.entryDetails
|
|
201
|
+
const related = tx.entryDetails?.transactionDetails?.relatedParties;
|
|
202
202
|
const base = {
|
|
203
203
|
id: uuidv4(),
|
|
204
204
|
bankRefId: tx.entryReference || tx.fbxReference,
|
|
@@ -206,10 +206,10 @@ const mapFinbricksTransactionToPayment = (tx, account) => {
|
|
|
206
206
|
currency: tx.amount?.currency || "CZK",
|
|
207
207
|
paymentType: "DOMESTIC",
|
|
208
208
|
status: mapFinbricksStatus(tx.status),
|
|
209
|
-
message: tx.entryDetails.transactionDetails
|
|
209
|
+
message: tx.entryDetails.transactionDetails?.remittanceInformation?.unstructured || tx.entryDetails.transactionDetails?.additionalRemittanceInformation || null,
|
|
210
210
|
processedAt: new Date(tx.bookingDate.date),
|
|
211
211
|
...mapReferencesToPayment(
|
|
212
|
-
tx.entryDetails.transactionDetails
|
|
212
|
+
tx.entryDetails.transactionDetails?.remittanceInformation?.structured?.creditorReferenceInformation?.reference || tx.entryDetails.transactionDetails?.references?.endToEndIdentification
|
|
213
213
|
),
|
|
214
214
|
debtorHolderName: isIncoming ? related.debtor?.name || "Unknown" : "Unknown",
|
|
215
215
|
creditorHolderName: isIncoming ? "Unknown" : related.creditor?.name || "Unknown",
|
|
@@ -200,7 +200,7 @@ const mapFinbricksBatchStatus = (status) => {
|
|
|
200
200
|
};
|
|
201
201
|
const mapFinbricksTransactionToPayment = (tx, account) => {
|
|
202
202
|
const isIncoming = tx.creditDebitIndicator === "CRDT";
|
|
203
|
-
const related = tx.entryDetails
|
|
203
|
+
const related = tx.entryDetails?.transactionDetails?.relatedParties;
|
|
204
204
|
const base = {
|
|
205
205
|
id: backendSdk.uuidv4(),
|
|
206
206
|
bankRefId: tx.entryReference || tx.fbxReference,
|
|
@@ -208,10 +208,10 @@ const mapFinbricksTransactionToPayment = (tx, account) => {
|
|
|
208
208
|
currency: tx.amount?.currency || "CZK",
|
|
209
209
|
paymentType: "DOMESTIC",
|
|
210
210
|
status: mapFinbricksStatus(tx.status),
|
|
211
|
-
message: tx.entryDetails.transactionDetails
|
|
211
|
+
message: tx.entryDetails.transactionDetails?.remittanceInformation?.unstructured || tx.entryDetails.transactionDetails?.additionalRemittanceInformation || null,
|
|
212
212
|
processedAt: new Date(tx.bookingDate.date),
|
|
213
213
|
...mapReferencesToPayment(
|
|
214
|
-
tx.entryDetails.transactionDetails
|
|
214
|
+
tx.entryDetails.transactionDetails?.remittanceInformation?.structured?.creditorReferenceInformation?.reference || tx.entryDetails.transactionDetails?.references?.endToEndIdentification
|
|
215
215
|
),
|
|
216
216
|
debtorHolderName: isIncoming ? related.debtor?.name || "Unknown" : "Unknown",
|
|
217
217
|
creditorHolderName: isIncoming ? "Unknown" : related.creditor?.name || "Unknown",
|
package/dist/types.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const db = require('./shared/bank.
|
|
3
|
+
const db = require('./shared/bank.CfvkOFs5.cjs');
|
|
4
4
|
const database_schema = require('./shared/bank.P9gDUycr.cjs');
|
|
5
5
|
const generalCodes = require('@develit-io/general-codes');
|
|
6
6
|
require('@develit-io/backend-sdk');
|
package/dist/types.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { B as BATCH_STATUES, B as BATCH_STATUSES, C as COUNTRY_CODES, E as ErsteConnector, c as FINBRICKS_ENDPOINTS, b as FinbricksClient, F as FinbricksConnector, I as IBankConnector, a as MockCobsConnector, M as MockConnector, e as PAYMENT_DIRECTIONS, d as PAYMENT_STATUSES, P as PAYMENT_TYPES, p as paymentInsertTypeZod, s as signFinbricksJws, u as useFinbricksFetch } from './shared/bank.
|
|
1
|
+
export { B as BATCH_STATUES, B as BATCH_STATUSES, C as COUNTRY_CODES, E as ErsteConnector, c as FINBRICKS_ENDPOINTS, b as FinbricksClient, F as FinbricksConnector, I as IBankConnector, a as MockCobsConnector, M as MockConnector, e as PAYMENT_DIRECTIONS, d as PAYMENT_STATUSES, P as PAYMENT_TYPES, p as paymentInsertTypeZod, s as signFinbricksJws, u as useFinbricksFetch } from './shared/bank.C03cnXOh.mjs';
|
|
2
2
|
export { C as CONNECTOR_KEYS, T as TOKEN_TYPES } from './shared/bank.C9jAvwna.mjs';
|
|
3
3
|
export { BANK_CODES, CURRENCY_CODES } from '@develit-io/general-codes';
|
|
4
4
|
import '@develit-io/backend-sdk';
|