@develit-services/bank 4.2.0 → 4.2.1

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.
@@ -1,4 +1,4 @@
1
- export { aA as account, aB as accountCredentials, aC as batch, aD as ott, aE as payment, aF as paymentRequest } from '../shared/bank.BOI0GA-f.cjs';
1
+ export { aB as account, aC as accountCredentials, aD as batch, aE as ott, aF as payment, aG as paymentRequest } from '../shared/bank.BCqBwSKC.cjs';
2
2
  import 'drizzle-orm';
3
3
  import 'drizzle-orm/sqlite-core';
4
4
  import '@develit-io/general-codes';
@@ -1,4 +1,4 @@
1
- export { aA as account, aB as accountCredentials, aC as batch, aD as ott, aE as payment, aF as paymentRequest } from '../shared/bank.BOI0GA-f.mjs';
1
+ export { aB as account, aC as accountCredentials, aD as batch, aE as ott, aF as payment, aG as paymentRequest } from '../shared/bank.BCqBwSKC.mjs';
2
2
  import 'drizzle-orm';
3
3
  import 'drizzle-orm/sqlite-core';
4
4
  import '@develit-io/general-codes';
@@ -1,4 +1,4 @@
1
- export { aA as account, aB as accountCredentials, aC as batch, aD as ott, aE as payment, aF as paymentRequest } from '../shared/bank.BOI0GA-f.js';
1
+ export { aB as account, aC as accountCredentials, aD as batch, aE as ott, aF as payment, aG as paymentRequest } from '../shared/bank.BCqBwSKC.js';
2
2
  import 'drizzle-orm';
3
3
  import 'drizzle-orm/sqlite-core';
4
4
  import '@develit-io/general-codes';
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  const backendSdk = require('@develit-io/backend-sdk');
4
- const ott_zod = require('../shared/bank.C2QV_SMx.cjs');
4
+ const ott_zod = require('../shared/bank.DiJmJkDt.cjs');
5
5
  const drizzleOrm = require('drizzle-orm');
6
6
  const cloudflare_workers = require('cloudflare:workers');
7
7
  const d1 = require('drizzle-orm/d1');
@@ -11,7 +11,7 @@ const database_schema = require('../shared/bank.9Yw4KHyl.cjs');
11
11
  const generalCodes = require('@develit-io/general-codes');
12
12
  require('date-fns');
13
13
  require('node:crypto');
14
- const credentialsResolver = require('../shared/bank.Cfu7ZqyP.cjs');
14
+ const credentialsResolver = require('../shared/bank.CioJeFzf.cjs');
15
15
  require('drizzle-orm/zod');
16
16
  require('drizzle-orm/sqlite-core');
17
17
 
@@ -816,6 +816,7 @@ let BankServiceBase = class extends backendSdk.develitWorker(cloudflare_workers.
816
816
  const byConnector = Map.groupBy(allPRs, (pr) => pr.connectorKey);
817
817
  let processed = 0;
818
818
  let statusChanged = 0;
819
+ let skippedNoBankRefId = 0;
819
820
  const eventsToEmit = [];
820
821
  for (const [connectorKey, requests] of byConnector) {
821
822
  let connector;
@@ -828,10 +829,30 @@ let BankServiceBase = class extends backendSdk.develitWorker(cloudflare_workers.
828
829
  continue;
829
830
  }
830
831
  for (const pr of requests) {
832
+ if (!pr.bankRefId && pr.connectorKey === "DBU") {
833
+ skippedNoBankRefId++;
834
+ console.warn(
835
+ "[_resolvePaymentRequestStatuses] Skipping DBU PR without bankRefId",
836
+ {
837
+ prId: pr.id,
838
+ status: pr.status,
839
+ connectorKey: pr.connectorKey,
840
+ createdAt: pr.createdAt
841
+ }
842
+ );
843
+ continue;
844
+ }
831
845
  try {
832
846
  const paymentId = pr.bankRefId ?? pr.id;
833
847
  const newStatus = await connector.getPaymentStatus({ paymentId });
834
848
  if (newStatus !== pr.status) {
849
+ console.log("[_resolvePaymentRequestStatuses] Status changed", {
850
+ prId: pr.id,
851
+ connectorKey: pr.connectorKey,
852
+ bankRefId: pr.bankRefId,
853
+ oldStatus: pr.status,
854
+ newStatus
855
+ });
835
856
  await credentialsResolver.updatePaymentRequestStatusCommand(this.db, {
836
857
  id: pr.id,
837
858
  status: newStatus,
@@ -844,17 +865,34 @@ let BankServiceBase = class extends backendSdk.develitWorker(cloudflare_workers.
844
865
  }
845
866
  processed++;
846
867
  } catch (err) {
847
- this.logError({
848
- message: `Failed to resolve status for PR ${pr.id}: ${err}`
849
- });
868
+ console.error(
869
+ "[_resolvePaymentRequestStatuses] Failed to get payment status",
870
+ {
871
+ prId: pr.id,
872
+ connectorKey: pr.connectorKey,
873
+ status: pr.status,
874
+ bankRefId: pr.bankRefId,
875
+ error: err instanceof Error ? err.message : String(err)
876
+ }
877
+ );
850
878
  }
851
879
  }
852
880
  }
853
881
  if (eventsToEmit.length > 0) {
854
- await this.pushToQueue(
855
- this.env.QUEUE_BUS_QUEUE,
856
- eventsToEmit
857
- );
882
+ try {
883
+ await this.pushToQueue(
884
+ this.env.QUEUE_BUS_QUEUE,
885
+ eventsToEmit
886
+ );
887
+ } catch (err) {
888
+ console.error(
889
+ "[_resolvePaymentRequestStatuses] Failed to push events to queue",
890
+ {
891
+ eventCount: eventsToEmit.length,
892
+ error: err instanceof Error ? err.message : String(err)
893
+ }
894
+ );
895
+ }
858
896
  }
859
897
  const affectedBatchIds = [
860
898
  ...new Set(
@@ -862,7 +900,32 @@ let BankServiceBase = class extends backendSdk.develitWorker(cloudflare_workers.
862
900
  )
863
901
  ];
864
902
  for (const batchId of affectedBatchIds) {
865
- await this._deriveBatchStatus(batchId);
903
+ try {
904
+ await this._deriveBatchStatus(batchId);
905
+ } catch (err) {
906
+ console.error(
907
+ "[_resolvePaymentRequestStatuses] Failed to derive batch status",
908
+ {
909
+ batchId,
910
+ error: err instanceof Error ? err.message : String(err)
911
+ }
912
+ );
913
+ }
914
+ }
915
+ console.log("[_resolvePaymentRequestStatuses] Summary", {
916
+ total: allPRs.length,
917
+ processed,
918
+ statusChanged,
919
+ skippedNoBankRefId
920
+ });
921
+ if (skippedNoBankRefId > 5) {
922
+ console.warn(
923
+ "[_resolvePaymentRequestStatuses] HIGH NUMBER of PRs without bankRefId",
924
+ {
925
+ count: skippedNoBankRefId,
926
+ note: "These PRs may be orphaned - payment sent but bankRefId not saved"
927
+ }
928
+ );
866
929
  }
867
930
  return { processed, statusChanged };
868
931
  }
@@ -877,8 +940,9 @@ let BankServiceBase = class extends backendSdk.develitWorker(cloudflare_workers.
877
940
  if (!batch || batch.status === "COMPLETED" || batch.status === "FAILED")
878
941
  return;
879
942
  if (allPRs.length === 0) return;
943
+ const connectorKey = allPRs[0]?.connectorKey;
880
944
  const allTerminal = allPRs.every(
881
- (pr) => ott_zod.isTerminalStatus(pr.status)
945
+ (pr) => ott_zod.isTerminalStatus(pr.status, connectorKey)
882
946
  );
883
947
  const allAuthorizedOrHigher = allPRs.every((pr) => pr.status !== "OPENED");
884
948
  if (allTerminal) {
@@ -899,16 +963,49 @@ let BankServiceBase = class extends backendSdk.develitWorker(cloudflare_workers.
899
963
  null,
900
964
  { successMessage: "Payment request statuses updated" },
901
965
  async () => {
966
+ const startTime = Date.now();
967
+ console.log("[updatePaymentRequestStatuses] Starting", {
968
+ timestamp: (/* @__PURE__ */ new Date()).toISOString()
969
+ });
902
970
  const nonTerminalPRs = await ott_zod.getNonTerminalPaymentRequestsQuery(this.db);
903
971
  if (nonTerminalPRs.length === 0) {
972
+ console.log(
973
+ "[updatePaymentRequestStatuses] No non-terminal PRs found",
974
+ {
975
+ duration: `${Date.now() - startTime}ms`
976
+ }
977
+ );
904
978
  return { processed: 0, statusChanged: 0 };
905
979
  }
980
+ const byConnector = nonTerminalPRs.reduce(
981
+ (acc, pr) => {
982
+ const key = pr.connectorKey || "unknown";
983
+ acc[key] = (acc[key] || 0) + 1;
984
+ return acc;
985
+ },
986
+ {}
987
+ );
988
+ console.log("[updatePaymentRequestStatuses] By connector", byConnector);
906
989
  const now = Date.now();
907
990
  const pollableIds = [];
908
991
  for (const pr of nonTerminalPRs) {
909
992
  const status = pr.status;
993
+ if (ott_zod.isTerminalStatus(status, pr.connectorKey)) {
994
+ continue;
995
+ }
910
996
  if (status === "OPENED" || status === "AUTHORIZED") {
911
997
  if (pr.createdAt != null && now - pr.createdAt.getTime() > this.POLLING_TIMEOUT_MS) {
998
+ console.warn(
999
+ "[updatePaymentRequestStatuses] Closing PR due to timeout",
1000
+ {
1001
+ prId: pr.id,
1002
+ status: pr.status,
1003
+ connectorKey: pr.connectorKey,
1004
+ createdAt: pr.createdAt,
1005
+ bankRefId: pr.bankRefId,
1006
+ age: `${Math.floor((now - pr.createdAt.getTime()) / (24 * 60 * 60 * 1e3))} days`
1007
+ }
1008
+ );
912
1009
  await credentialsResolver.updatePaymentRequestStatusCommand(this.db, {
913
1010
  id: pr.id,
914
1011
  status: "CLOSED",
@@ -918,14 +1015,20 @@ let BankServiceBase = class extends backendSdk.develitWorker(cloudflare_workers.
918
1015
  continue;
919
1016
  }
920
1017
  pollableIds.push(pr.id);
921
- } else if (status === "COMPLETED" || status === "BOOKED") {
922
- if (pr.processedAt != null && now - pr.processedAt.getTime() > this.COMPLETED_POLLING_WINDOW_MS) {
923
- continue;
924
- }
925
- pollableIds.push(pr.id);
926
1018
  }
927
1019
  }
928
- return this._resolvePaymentRequestStatuses(pollableIds);
1020
+ const result = await this._resolvePaymentRequestStatuses(pollableIds);
1021
+ const duration = Date.now() - startTime;
1022
+ console.log("[updatePaymentRequestStatuses] Completed", {
1023
+ duration: `${duration}ms`,
1024
+ metrics: {
1025
+ total: nonTerminalPRs.length,
1026
+ polled: pollableIds.length,
1027
+ processed: result.processed,
1028
+ statusChanged: result.statusChanged
1029
+ }
1030
+ });
1031
+ return result;
929
1032
  }
930
1033
  );
931
1034
  }
@@ -1,6 +1,6 @@
1
1
  import * as drizzle_orm from 'drizzle-orm';
2
- import { B as BatchSelectType, P as PaymentRequestSelectType, A as AccountSelectType, a as PaymentSelectType, L as LastSyncMetadata, C as ConnectorConfig, b as ConfigEnvironmentBank, t as tables, c as ConnectorKey, I as IBankConnector, d as PaymentType, e as CurrencyCode, H as HandleAuthorizationCallbackInput, f as HandleAuthorizationCallbackOutput } from '../shared/bank.BOI0GA-f.cjs';
3
- import { S as SendPaymentInput, a as SendPaymentOutput, b as SendPaymentSyncInput, c as SendPaymentSyncOutput, F as FinbricksSupportedBanksResponse } from '../shared/bank.DUd_XvqB.cjs';
2
+ import { B as BatchSelectType, P as PaymentRequestSelectType, A as AccountSelectType, a as PaymentSelectType, L as LastSyncMetadata, C as ConnectorConfig, b as ConfigEnvironmentBank, t as tables, c as ConnectorKey, I as IBankConnector, d as PaymentType, e as CurrencyCode, H as HandleAuthorizationCallbackInput, f as HandleAuthorizationCallbackOutput } from '../shared/bank.BCqBwSKC.cjs';
3
+ import { S as SendPaymentInput, a as SendPaymentOutput, b as SendPaymentSyncInput, c as SendPaymentSyncOutput, F as FinbricksSupportedBanksResponse } from '../shared/bank.mHFTrKBv.cjs';
4
4
  import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
5
5
  import { WorkflowInstanceStatus, IRPCResponse } from '@develit-io/backend-sdk';
6
6
  import { WorkerEntrypoint } from 'cloudflare:workers';
@@ -2703,15 +2703,15 @@ declare const getBatchesInputSchema: z.ZodObject<{
2703
2703
  filterBatchAccountId: z.ZodOptional<z.ZodUnion<readonly [z.ZodUUID, z.ZodArray<z.ZodUUID>]>>;
2704
2704
  filterBatchStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
2705
2705
  AUTHORIZED: "AUTHORIZED";
2706
+ COMPLETED: "COMPLETED";
2706
2707
  PROCESSING: "PROCESSING";
2707
2708
  READY_TO_SIGN: "READY_TO_SIGN";
2708
- COMPLETED: "COMPLETED";
2709
2709
  FAILED: "FAILED";
2710
2710
  }>, z.ZodArray<z.ZodEnum<{
2711
2711
  AUTHORIZED: "AUTHORIZED";
2712
+ COMPLETED: "COMPLETED";
2712
2713
  PROCESSING: "PROCESSING";
2713
2714
  READY_TO_SIGN: "READY_TO_SIGN";
2714
- COMPLETED: "COMPLETED";
2715
2715
  FAILED: "FAILED";
2716
2716
  }>>]>>;
2717
2717
  }, z.core.$strip>;
@@ -2948,20 +2948,20 @@ declare const getPaymentsInputSchema: z.ZodObject<{
2948
2948
  filterPaymentDateFrom: z.ZodOptional<z.ZodDate>;
2949
2949
  filterPaymentDateTo: z.ZodOptional<z.ZodDate>;
2950
2950
  filterPaymentStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
2951
- PROCESSING: "PROCESSING";
2952
- PENDING: "PENDING";
2953
2951
  BOOKED: "BOOKED";
2954
- CANCELLED: "CANCELLED";
2955
2952
  REJECTED: "REJECTED";
2953
+ PENDING: "PENDING";
2954
+ PROCESSING: "PROCESSING";
2955
+ CANCELLED: "CANCELLED";
2956
2956
  SCHEDULED: "SCHEDULED";
2957
2957
  HOLD: "HOLD";
2958
2958
  INFO: "INFO";
2959
2959
  }>, z.ZodArray<z.ZodEnum<{
2960
- PROCESSING: "PROCESSING";
2961
- PENDING: "PENDING";
2962
2960
  BOOKED: "BOOKED";
2963
- CANCELLED: "CANCELLED";
2964
2961
  REJECTED: "REJECTED";
2962
+ PENDING: "PENDING";
2963
+ PROCESSING: "PROCESSING";
2964
+ CANCELLED: "CANCELLED";
2965
2965
  SCHEDULED: "SCHEDULED";
2966
2966
  HOLD: "HOLD";
2967
2967
  INFO: "INFO";
@@ -3597,19 +3597,19 @@ declare const getPaymentRequestsInputSchema: z.ZodObject<{
3597
3597
  filterAccountId: z.ZodOptional<z.ZodUnion<readonly [z.ZodUUID, z.ZodArray<z.ZodUUID>]>>;
3598
3598
  filterStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
3599
3599
  AUTHORIZED: "AUTHORIZED";
3600
+ OPENED: "OPENED";
3600
3601
  COMPLETED: "COMPLETED";
3601
3602
  BOOKED: "BOOKED";
3602
- REJECTED: "REJECTED";
3603
- OPENED: "OPENED";
3604
3603
  SETTLED: "SETTLED";
3604
+ REJECTED: "REJECTED";
3605
3605
  CLOSED: "CLOSED";
3606
3606
  }>, z.ZodArray<z.ZodEnum<{
3607
3607
  AUTHORIZED: "AUTHORIZED";
3608
+ OPENED: "OPENED";
3608
3609
  COMPLETED: "COMPLETED";
3609
3610
  BOOKED: "BOOKED";
3610
- REJECTED: "REJECTED";
3611
- OPENED: "OPENED";
3612
3611
  SETTLED: "SETTLED";
3612
+ REJECTED: "REJECTED";
3613
3613
  CLOSED: "CLOSED";
3614
3614
  }>>]>>;
3615
3615
  filterPaymentType: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
@@ -1,6 +1,6 @@
1
1
  import * as drizzle_orm from 'drizzle-orm';
2
- import { B as BatchSelectType, P as PaymentRequestSelectType, A as AccountSelectType, a as PaymentSelectType, L as LastSyncMetadata, C as ConnectorConfig, b as ConfigEnvironmentBank, t as tables, c as ConnectorKey, I as IBankConnector, d as PaymentType, e as CurrencyCode, H as HandleAuthorizationCallbackInput, f as HandleAuthorizationCallbackOutput } from '../shared/bank.BOI0GA-f.mjs';
3
- import { S as SendPaymentInput, a as SendPaymentOutput, b as SendPaymentSyncInput, c as SendPaymentSyncOutput, F as FinbricksSupportedBanksResponse } from '../shared/bank.CT-uUhZB.mjs';
2
+ import { B as BatchSelectType, P as PaymentRequestSelectType, A as AccountSelectType, a as PaymentSelectType, L as LastSyncMetadata, C as ConnectorConfig, b as ConfigEnvironmentBank, t as tables, c as ConnectorKey, I as IBankConnector, d as PaymentType, e as CurrencyCode, H as HandleAuthorizationCallbackInput, f as HandleAuthorizationCallbackOutput } from '../shared/bank.BCqBwSKC.mjs';
3
+ import { S as SendPaymentInput, a as SendPaymentOutput, b as SendPaymentSyncInput, c as SendPaymentSyncOutput, F as FinbricksSupportedBanksResponse } from '../shared/bank.BnCJmT6k.mjs';
4
4
  import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
5
5
  import { WorkflowInstanceStatus, IRPCResponse } from '@develit-io/backend-sdk';
6
6
  import { WorkerEntrypoint } from 'cloudflare:workers';
@@ -2703,15 +2703,15 @@ declare const getBatchesInputSchema: z.ZodObject<{
2703
2703
  filterBatchAccountId: z.ZodOptional<z.ZodUnion<readonly [z.ZodUUID, z.ZodArray<z.ZodUUID>]>>;
2704
2704
  filterBatchStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
2705
2705
  AUTHORIZED: "AUTHORIZED";
2706
+ COMPLETED: "COMPLETED";
2706
2707
  PROCESSING: "PROCESSING";
2707
2708
  READY_TO_SIGN: "READY_TO_SIGN";
2708
- COMPLETED: "COMPLETED";
2709
2709
  FAILED: "FAILED";
2710
2710
  }>, z.ZodArray<z.ZodEnum<{
2711
2711
  AUTHORIZED: "AUTHORIZED";
2712
+ COMPLETED: "COMPLETED";
2712
2713
  PROCESSING: "PROCESSING";
2713
2714
  READY_TO_SIGN: "READY_TO_SIGN";
2714
- COMPLETED: "COMPLETED";
2715
2715
  FAILED: "FAILED";
2716
2716
  }>>]>>;
2717
2717
  }, z.core.$strip>;
@@ -2948,20 +2948,20 @@ declare const getPaymentsInputSchema: z.ZodObject<{
2948
2948
  filterPaymentDateFrom: z.ZodOptional<z.ZodDate>;
2949
2949
  filterPaymentDateTo: z.ZodOptional<z.ZodDate>;
2950
2950
  filterPaymentStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
2951
- PROCESSING: "PROCESSING";
2952
- PENDING: "PENDING";
2953
2951
  BOOKED: "BOOKED";
2954
- CANCELLED: "CANCELLED";
2955
2952
  REJECTED: "REJECTED";
2953
+ PENDING: "PENDING";
2954
+ PROCESSING: "PROCESSING";
2955
+ CANCELLED: "CANCELLED";
2956
2956
  SCHEDULED: "SCHEDULED";
2957
2957
  HOLD: "HOLD";
2958
2958
  INFO: "INFO";
2959
2959
  }>, z.ZodArray<z.ZodEnum<{
2960
- PROCESSING: "PROCESSING";
2961
- PENDING: "PENDING";
2962
2960
  BOOKED: "BOOKED";
2963
- CANCELLED: "CANCELLED";
2964
2961
  REJECTED: "REJECTED";
2962
+ PENDING: "PENDING";
2963
+ PROCESSING: "PROCESSING";
2964
+ CANCELLED: "CANCELLED";
2965
2965
  SCHEDULED: "SCHEDULED";
2966
2966
  HOLD: "HOLD";
2967
2967
  INFO: "INFO";
@@ -3597,19 +3597,19 @@ declare const getPaymentRequestsInputSchema: z.ZodObject<{
3597
3597
  filterAccountId: z.ZodOptional<z.ZodUnion<readonly [z.ZodUUID, z.ZodArray<z.ZodUUID>]>>;
3598
3598
  filterStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
3599
3599
  AUTHORIZED: "AUTHORIZED";
3600
+ OPENED: "OPENED";
3600
3601
  COMPLETED: "COMPLETED";
3601
3602
  BOOKED: "BOOKED";
3602
- REJECTED: "REJECTED";
3603
- OPENED: "OPENED";
3604
3603
  SETTLED: "SETTLED";
3604
+ REJECTED: "REJECTED";
3605
3605
  CLOSED: "CLOSED";
3606
3606
  }>, z.ZodArray<z.ZodEnum<{
3607
3607
  AUTHORIZED: "AUTHORIZED";
3608
+ OPENED: "OPENED";
3608
3609
  COMPLETED: "COMPLETED";
3609
3610
  BOOKED: "BOOKED";
3610
- REJECTED: "REJECTED";
3611
- OPENED: "OPENED";
3612
3611
  SETTLED: "SETTLED";
3612
+ REJECTED: "REJECTED";
3613
3613
  CLOSED: "CLOSED";
3614
3614
  }>>]>>;
3615
3615
  filterPaymentType: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
@@ -1,6 +1,6 @@
1
1
  import * as drizzle_orm from 'drizzle-orm';
2
- import { B as BatchSelectType, P as PaymentRequestSelectType, A as AccountSelectType, a as PaymentSelectType, L as LastSyncMetadata, C as ConnectorConfig, b as ConfigEnvironmentBank, t as tables, c as ConnectorKey, I as IBankConnector, d as PaymentType, e as CurrencyCode, H as HandleAuthorizationCallbackInput, f as HandleAuthorizationCallbackOutput } from '../shared/bank.BOI0GA-f.js';
3
- import { S as SendPaymentInput, a as SendPaymentOutput, b as SendPaymentSyncInput, c as SendPaymentSyncOutput, F as FinbricksSupportedBanksResponse } from '../shared/bank.DDmes7Gx.js';
2
+ import { B as BatchSelectType, P as PaymentRequestSelectType, A as AccountSelectType, a as PaymentSelectType, L as LastSyncMetadata, C as ConnectorConfig, b as ConfigEnvironmentBank, t as tables, c as ConnectorKey, I as IBankConnector, d as PaymentType, e as CurrencyCode, H as HandleAuthorizationCallbackInput, f as HandleAuthorizationCallbackOutput } from '../shared/bank.BCqBwSKC.js';
3
+ import { S as SendPaymentInput, a as SendPaymentOutput, b as SendPaymentSyncInput, c as SendPaymentSyncOutput, F as FinbricksSupportedBanksResponse } from '../shared/bank.BmX_IG66.js';
4
4
  import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
5
5
  import { WorkflowInstanceStatus, IRPCResponse } from '@develit-io/backend-sdk';
6
6
  import { WorkerEntrypoint } from 'cloudflare:workers';
@@ -2703,15 +2703,15 @@ declare const getBatchesInputSchema: z.ZodObject<{
2703
2703
  filterBatchAccountId: z.ZodOptional<z.ZodUnion<readonly [z.ZodUUID, z.ZodArray<z.ZodUUID>]>>;
2704
2704
  filterBatchStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
2705
2705
  AUTHORIZED: "AUTHORIZED";
2706
+ COMPLETED: "COMPLETED";
2706
2707
  PROCESSING: "PROCESSING";
2707
2708
  READY_TO_SIGN: "READY_TO_SIGN";
2708
- COMPLETED: "COMPLETED";
2709
2709
  FAILED: "FAILED";
2710
2710
  }>, z.ZodArray<z.ZodEnum<{
2711
2711
  AUTHORIZED: "AUTHORIZED";
2712
+ COMPLETED: "COMPLETED";
2712
2713
  PROCESSING: "PROCESSING";
2713
2714
  READY_TO_SIGN: "READY_TO_SIGN";
2714
- COMPLETED: "COMPLETED";
2715
2715
  FAILED: "FAILED";
2716
2716
  }>>]>>;
2717
2717
  }, z.core.$strip>;
@@ -2948,20 +2948,20 @@ declare const getPaymentsInputSchema: z.ZodObject<{
2948
2948
  filterPaymentDateFrom: z.ZodOptional<z.ZodDate>;
2949
2949
  filterPaymentDateTo: z.ZodOptional<z.ZodDate>;
2950
2950
  filterPaymentStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
2951
- PROCESSING: "PROCESSING";
2952
- PENDING: "PENDING";
2953
2951
  BOOKED: "BOOKED";
2954
- CANCELLED: "CANCELLED";
2955
2952
  REJECTED: "REJECTED";
2953
+ PENDING: "PENDING";
2954
+ PROCESSING: "PROCESSING";
2955
+ CANCELLED: "CANCELLED";
2956
2956
  SCHEDULED: "SCHEDULED";
2957
2957
  HOLD: "HOLD";
2958
2958
  INFO: "INFO";
2959
2959
  }>, z.ZodArray<z.ZodEnum<{
2960
- PROCESSING: "PROCESSING";
2961
- PENDING: "PENDING";
2962
2960
  BOOKED: "BOOKED";
2963
- CANCELLED: "CANCELLED";
2964
2961
  REJECTED: "REJECTED";
2962
+ PENDING: "PENDING";
2963
+ PROCESSING: "PROCESSING";
2964
+ CANCELLED: "CANCELLED";
2965
2965
  SCHEDULED: "SCHEDULED";
2966
2966
  HOLD: "HOLD";
2967
2967
  INFO: "INFO";
@@ -3597,19 +3597,19 @@ declare const getPaymentRequestsInputSchema: z.ZodObject<{
3597
3597
  filterAccountId: z.ZodOptional<z.ZodUnion<readonly [z.ZodUUID, z.ZodArray<z.ZodUUID>]>>;
3598
3598
  filterStatus: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
3599
3599
  AUTHORIZED: "AUTHORIZED";
3600
+ OPENED: "OPENED";
3600
3601
  COMPLETED: "COMPLETED";
3601
3602
  BOOKED: "BOOKED";
3602
- REJECTED: "REJECTED";
3603
- OPENED: "OPENED";
3604
3603
  SETTLED: "SETTLED";
3604
+ REJECTED: "REJECTED";
3605
3605
  CLOSED: "CLOSED";
3606
3606
  }>, z.ZodArray<z.ZodEnum<{
3607
3607
  AUTHORIZED: "AUTHORIZED";
3608
+ OPENED: "OPENED";
3608
3609
  COMPLETED: "COMPLETED";
3609
3610
  BOOKED: "BOOKED";
3610
- REJECTED: "REJECTED";
3611
- OPENED: "OPENED";
3612
3611
  SETTLED: "SETTLED";
3612
+ REJECTED: "REJECTED";
3613
3613
  CLOSED: "CLOSED";
3614
3614
  }>>]>>;
3615
3615
  filterPaymentType: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{