@develit-services/bank 0.8.2 → 0.8.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/README.md +82 -6
  2. package/dist/database/schema.cjs +9 -7
  3. package/dist/database/schema.d.cts +1 -1
  4. package/dist/database/schema.d.mts +1 -1
  5. package/dist/database/schema.d.ts +1 -1
  6. package/dist/database/schema.mjs +1 -1
  7. package/dist/export/worker.cjs +221 -43
  8. package/dist/export/worker.d.cts +24 -8
  9. package/dist/export/worker.d.mts +24 -8
  10. package/dist/export/worker.d.ts +24 -8
  11. package/dist/export/worker.mjs +212 -34
  12. package/dist/export/workflows.cjs +71 -52
  13. package/dist/export/workflows.mjs +71 -52
  14. package/dist/export/wrangler.d.cts +1 -2
  15. package/dist/export/wrangler.d.mts +1 -2
  16. package/dist/export/wrangler.d.ts +1 -2
  17. package/dist/shared/{bank.Du70-Kk_.d.ts → bank.6faPHUEY.d.ts} +211 -1
  18. package/dist/shared/{bank.Bs7mkXbR.cjs → bank.BOnP9p9Y.cjs} +15 -2
  19. package/dist/shared/{bank.BJ7LqYtJ.d.cts → bank.BaMRCHk-.d.cts} +707 -126
  20. package/dist/shared/{bank.BJ7LqYtJ.d.mts → bank.BaMRCHk-.d.mts} +707 -126
  21. package/dist/shared/{bank.BJ7LqYtJ.d.ts → bank.BaMRCHk-.d.ts} +707 -126
  22. package/dist/shared/{bank.Du70-Kk_.d.cts → bank.BoWCMu5n.d.cts} +211 -1
  23. package/dist/shared/bank.C-T1FQxg.cjs +17 -0
  24. package/dist/shared/{bank.993UA65l.mjs → bank.C4VOdIx1.mjs} +57 -5
  25. package/dist/shared/{bank.BC06Rbrx.d.cts → bank.CQBfbG8u.d.cts} +0 -1
  26. package/dist/shared/{bank.BC06Rbrx.d.mts → bank.CQBfbG8u.d.mts} +0 -1
  27. package/dist/shared/{bank.BC06Rbrx.d.ts → bank.CQBfbG8u.d.ts} +0 -1
  28. package/dist/shared/{bank.Ce-NBBw1.cjs → bank.CQURey1E.cjs} +64 -7
  29. package/dist/shared/{bank.CGIeLo8U.mjs → bank.Cpy9PULF.mjs} +14 -3
  30. package/dist/shared/bank.DDHrdFgy.mjs +15 -0
  31. package/dist/shared/{bank.Du70-Kk_.d.mts → bank.DOL1uM4n.d.mts} +211 -1
  32. package/dist/shared/{bank.CeRbuycV.mjs → bank.DRrBrAdI.mjs} +62 -8
  33. package/dist/shared/{bank.IVhZ_RlH.cjs → bank.SQ4Mmr8u.cjs} +57 -3
  34. package/dist/types.cjs +25 -23
  35. package/dist/types.d.cts +29 -180
  36. package/dist/types.d.mts +29 -180
  37. package/dist/types.d.ts +29 -180
  38. package/dist/types.mjs +2 -2
  39. package/package.json +1 -1
  40. package/dist/shared/bank.Cp0yvOdq.cjs +0 -15
  41. package/dist/shared/bank.fIGTiPnp.mjs +0 -13
@@ -33,7 +33,7 @@ declare const CHARGE_BEARERS: readonly ["SHA", "OUR", "BEN"];
33
33
  type ChargeBearer = (typeof CHARGE_BEARERS)[number];
34
34
  declare const INSTRUCTION_PRIORITIES: readonly ["NORM", "HIGH", "INST"];
35
35
  type InstructionPriority = (typeof INSTRUCTION_PRIORITIES)[number];
36
- declare const PAYMENT_STATUSES: readonly ["PREPARED", "FAILED", "PENDING", "COMPLETED", "CREATED"];
36
+ declare const PAYMENT_STATUSES: readonly ["CREATED", "PREPARED", "SIGNED", "PENDING", "COMPLETED", "FAILED"];
37
37
  type PaymentStatus = (typeof PAYMENT_STATUSES)[number];
38
38
  declare const PAYMENT_DIRECTIONS: readonly ["INCOMING", "OUTGOING"];
39
39
  type PaymentDirection = (typeof PAYMENT_DIRECTIONS)[number];
@@ -134,7 +134,7 @@ declare abstract class IBankConnector {
134
134
  * @deprecated Use initiateDomesticPayment instead.
135
135
  * Delegates to initiateDomesticPayment for backward compatibility.
136
136
  */
137
- initiateSinglePayment(payment: BatchedPayment): Promise<InitiatedPayment>;
137
+ initiatePaymentRequest(payment: BatchedPayment): Promise<InitiatedPayment>;
138
138
  /**
139
139
  * Initiates a single domestic payment.
140
140
  * @param payment - Payment details in batched format
@@ -2629,7 +2629,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2629
2629
  tableName: "batch";
2630
2630
  dataType: "string";
2631
2631
  columnType: "SQLiteText";
2632
- data: "FAILED" | "OPEN" | "PROCESSING" | "READY_TO_SIGN" | "SIGNED" | "SIGNATURE_FAILED";
2632
+ data: "SIGNED" | "FAILED" | "OPEN" | "PROCESSING" | "READY_TO_SIGN" | "SIGNATURE_FAILED";
2633
2633
  driverParam: string;
2634
2634
  notNull: false;
2635
2635
  hasDefault: false;
@@ -2642,7 +2642,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2642
2642
  generated: undefined;
2643
2643
  }, {}, {
2644
2644
  length: number | undefined;
2645
- $type: "FAILED" | "OPEN" | "PROCESSING" | "READY_TO_SIGN" | "SIGNED" | "SIGNATURE_FAILED";
2645
+ $type: "SIGNED" | "FAILED" | "OPEN" | "PROCESSING" | "READY_TO_SIGN" | "SIGNATURE_FAILED";
2646
2646
  }>;
2647
2647
  statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
2648
2648
  name: "status_reason";
@@ -2682,33 +2682,588 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2682
2682
  }, {}, {
2683
2683
  $type: object;
2684
2684
  }>;
2685
- payments: drizzle_orm_sqlite_core.SQLiteColumn<{
2686
- name: "payments";
2685
+ metadata: drizzle_orm_sqlite_core.SQLiteColumn<{
2686
+ name: "metadata";
2687
2687
  tableName: "batch";
2688
2688
  dataType: "json";
2689
2689
  columnType: "SQLiteTextJson";
2690
- data: BatchedPayment[];
2690
+ data: BatchMetadata;
2691
+ driverParam: string;
2692
+ notNull: false;
2693
+ hasDefault: false;
2694
+ isPrimaryKey: false;
2695
+ isAutoincrement: false;
2696
+ hasRuntimeDefault: false;
2697
+ enumValues: undefined;
2698
+ baseColumn: never;
2699
+ identity: undefined;
2700
+ generated: undefined;
2701
+ }, {}, {
2702
+ $type: BatchMetadata;
2703
+ }>;
2704
+ paymentType: drizzle_orm_sqlite_core.SQLiteColumn<{
2705
+ name: "payment_type";
2706
+ tableName: "batch";
2707
+ dataType: "string";
2708
+ columnType: "SQLiteText";
2709
+ data: "SEPA" | "SWIFT" | "DOMESTIC" | "UNKNOWN";
2710
+ driverParam: string;
2711
+ notNull: false;
2712
+ hasDefault: false;
2713
+ isPrimaryKey: false;
2714
+ isAutoincrement: false;
2715
+ hasRuntimeDefault: false;
2716
+ enumValues: ["SEPA", "SWIFT", "DOMESTIC", "UNKNOWN"];
2717
+ baseColumn: never;
2718
+ identity: undefined;
2719
+ generated: undefined;
2720
+ }, {}, {
2721
+ length: number | undefined;
2722
+ $type: "SEPA" | "SWIFT" | "DOMESTIC" | "UNKNOWN";
2723
+ }>;
2724
+ paymentsChecksum: drizzle_orm_sqlite_core.SQLiteColumn<{
2725
+ name: "payments_checksum";
2726
+ tableName: "batch";
2727
+ dataType: "string";
2728
+ columnType: "SQLiteText";
2729
+ data: string;
2730
+ driverParam: string;
2731
+ notNull: false;
2732
+ hasDefault: false;
2733
+ isPrimaryKey: false;
2734
+ isAutoincrement: false;
2735
+ hasRuntimeDefault: false;
2736
+ enumValues: [string, ...string[]];
2737
+ baseColumn: never;
2738
+ identity: undefined;
2739
+ generated: undefined;
2740
+ }, {}, {
2741
+ length: number | undefined;
2742
+ }>;
2743
+ id: drizzle_orm_sqlite_core.SQLiteColumn<{
2744
+ name: "id";
2745
+ tableName: "batch";
2746
+ dataType: "string";
2747
+ columnType: "SQLiteText";
2748
+ data: string;
2749
+ driverParam: string;
2750
+ notNull: true;
2751
+ hasDefault: false;
2752
+ isPrimaryKey: true;
2753
+ isAutoincrement: false;
2754
+ hasRuntimeDefault: false;
2755
+ enumValues: [string, ...string[]];
2756
+ baseColumn: never;
2757
+ identity: undefined;
2758
+ generated: undefined;
2759
+ }, {}, {
2760
+ length: number | undefined;
2761
+ }>;
2762
+ createdAt: drizzle_orm_sqlite_core.SQLiteColumn<{
2763
+ name: "created_at";
2764
+ tableName: "batch";
2765
+ dataType: "date";
2766
+ columnType: "SQLiteTimestamp";
2767
+ data: Date;
2768
+ driverParam: number;
2769
+ notNull: false;
2770
+ hasDefault: true;
2771
+ isPrimaryKey: false;
2772
+ isAutoincrement: false;
2773
+ hasRuntimeDefault: false;
2774
+ enumValues: undefined;
2775
+ baseColumn: never;
2776
+ identity: undefined;
2777
+ generated: undefined;
2778
+ }, {}, {}>;
2779
+ createdBy: drizzle_orm_sqlite_core.SQLiteColumn<{
2780
+ name: "created_by";
2781
+ tableName: "batch";
2782
+ dataType: "string";
2783
+ columnType: "SQLiteText";
2784
+ data: string;
2785
+ driverParam: string;
2786
+ notNull: false;
2787
+ hasDefault: true;
2788
+ isPrimaryKey: false;
2789
+ isAutoincrement: false;
2790
+ hasRuntimeDefault: false;
2791
+ enumValues: [string, ...string[]];
2792
+ baseColumn: never;
2793
+ identity: undefined;
2794
+ generated: undefined;
2795
+ }, {}, {
2796
+ length: number | undefined;
2797
+ }>;
2798
+ updatedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
2799
+ name: "updated_at";
2800
+ tableName: "batch";
2801
+ dataType: "date";
2802
+ columnType: "SQLiteTimestamp";
2803
+ data: Date;
2804
+ driverParam: number;
2805
+ notNull: false;
2806
+ hasDefault: true;
2807
+ isPrimaryKey: false;
2808
+ isAutoincrement: false;
2809
+ hasRuntimeDefault: false;
2810
+ enumValues: undefined;
2811
+ baseColumn: never;
2812
+ identity: undefined;
2813
+ generated: undefined;
2814
+ }, {}, {}>;
2815
+ updatedBy: drizzle_orm_sqlite_core.SQLiteColumn<{
2816
+ name: "updated_by";
2817
+ tableName: "batch";
2818
+ dataType: "string";
2819
+ columnType: "SQLiteText";
2820
+ data: string;
2821
+ driverParam: string;
2822
+ notNull: false;
2823
+ hasDefault: true;
2824
+ isPrimaryKey: false;
2825
+ isAutoincrement: false;
2826
+ hasRuntimeDefault: false;
2827
+ enumValues: [string, ...string[]];
2828
+ baseColumn: never;
2829
+ identity: undefined;
2830
+ generated: undefined;
2831
+ }, {}, {
2832
+ length: number | undefined;
2833
+ }>;
2834
+ deletedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
2835
+ name: "deleted_at";
2836
+ tableName: "batch";
2837
+ dataType: "date";
2838
+ columnType: "SQLiteTimestamp";
2839
+ data: Date;
2840
+ driverParam: number;
2841
+ notNull: false;
2842
+ hasDefault: true;
2843
+ isPrimaryKey: false;
2844
+ isAutoincrement: false;
2845
+ hasRuntimeDefault: false;
2846
+ enumValues: undefined;
2847
+ baseColumn: never;
2848
+ identity: undefined;
2849
+ generated: undefined;
2850
+ }, {}, {}>;
2851
+ deletedBy: drizzle_orm_sqlite_core.SQLiteColumn<{
2852
+ name: "deleted_by";
2853
+ tableName: "batch";
2854
+ dataType: "string";
2855
+ columnType: "SQLiteText";
2856
+ data: string;
2857
+ driverParam: string;
2858
+ notNull: false;
2859
+ hasDefault: true;
2860
+ isPrimaryKey: false;
2861
+ isAutoincrement: false;
2862
+ hasRuntimeDefault: false;
2863
+ enumValues: [string, ...string[]];
2864
+ baseColumn: never;
2865
+ identity: undefined;
2866
+ generated: undefined;
2867
+ }, {}, {
2868
+ length: number | undefined;
2869
+ }>;
2870
+ };
2871
+ dialect: "sqlite";
2872
+ }>;
2873
+
2874
+ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2875
+ name: "payment";
2876
+ schema: undefined;
2877
+ columns: {
2878
+ correlationId: drizzle_orm_sqlite_core.SQLiteColumn<{
2879
+ name: "correlation_id";
2880
+ tableName: "payment";
2881
+ dataType: "string";
2882
+ columnType: "SQLiteText";
2883
+ data: string;
2884
+ driverParam: string;
2885
+ notNull: true;
2886
+ hasDefault: false;
2887
+ isPrimaryKey: false;
2888
+ isAutoincrement: false;
2889
+ hasRuntimeDefault: false;
2890
+ enumValues: [string, ...string[]];
2891
+ baseColumn: never;
2892
+ identity: undefined;
2893
+ generated: undefined;
2894
+ }, {}, {
2895
+ length: number | undefined;
2896
+ }>;
2897
+ refId: drizzle_orm_sqlite_core.SQLiteColumn<{
2898
+ name: "ref_id";
2899
+ tableName: "payment";
2900
+ dataType: "string";
2901
+ columnType: "SQLiteText";
2902
+ data: string;
2903
+ driverParam: string;
2904
+ notNull: false;
2905
+ hasDefault: false;
2906
+ isPrimaryKey: false;
2907
+ isAutoincrement: false;
2908
+ hasRuntimeDefault: false;
2909
+ enumValues: [string, ...string[]];
2910
+ baseColumn: never;
2911
+ identity: undefined;
2912
+ generated: undefined;
2913
+ }, {}, {
2914
+ length: number | undefined;
2915
+ }>;
2916
+ bankRefId: drizzle_orm_sqlite_core.SQLiteColumn<{
2917
+ name: "bank_ref_id";
2918
+ tableName: "payment";
2919
+ dataType: "string";
2920
+ columnType: "SQLiteText";
2921
+ data: string;
2922
+ driverParam: string;
2923
+ notNull: true;
2924
+ hasDefault: false;
2925
+ isPrimaryKey: false;
2926
+ isAutoincrement: false;
2927
+ hasRuntimeDefault: false;
2928
+ enumValues: [string, ...string[]];
2929
+ baseColumn: never;
2930
+ identity: undefined;
2931
+ generated: undefined;
2932
+ }, {}, {
2933
+ length: number | undefined;
2934
+ }>;
2935
+ accountId: drizzle_orm_sqlite_core.SQLiteColumn<{
2936
+ name: "account_id";
2937
+ tableName: "payment";
2938
+ dataType: "string";
2939
+ columnType: "SQLiteText";
2940
+ data: string;
2941
+ driverParam: string;
2942
+ notNull: true;
2943
+ hasDefault: false;
2944
+ isPrimaryKey: false;
2945
+ isAutoincrement: false;
2946
+ hasRuntimeDefault: false;
2947
+ enumValues: [string, ...string[]];
2948
+ baseColumn: never;
2949
+ identity: undefined;
2950
+ generated: undefined;
2951
+ }, {}, {
2952
+ length: number | undefined;
2953
+ }>;
2954
+ connectorKey: drizzle_orm_sqlite_core.SQLiteColumn<{
2955
+ name: "connector_key";
2956
+ tableName: "payment";
2957
+ dataType: "string";
2958
+ columnType: "SQLiteText";
2959
+ data: "ERSTE" | "FINBRICKS" | "MOCK" | "CREDITAS" | "MOCK_COBS" | "FIO" | "MONETA" | "DBU" | "CSAS" | "AIRBANK" | "KB" | "CSOB";
2960
+ driverParam: string;
2961
+ notNull: true;
2962
+ hasDefault: false;
2963
+ isPrimaryKey: false;
2964
+ isAutoincrement: false;
2965
+ hasRuntimeDefault: false;
2966
+ enumValues: ["ERSTE", "FINBRICKS", "MOCK", "CREDITAS", "MOCK_COBS", "FIO", "MONETA", "DBU", "CSAS", "AIRBANK", "KB", "CSOB"];
2967
+ baseColumn: never;
2968
+ identity: undefined;
2969
+ generated: undefined;
2970
+ }, {}, {
2971
+ length: number | undefined;
2972
+ $type: "ERSTE" | "FINBRICKS" | "MOCK" | "CREDITAS" | "MOCK_COBS" | "FIO" | "MONETA" | "DBU" | "CSAS" | "AIRBANK" | "KB" | "CSOB";
2973
+ }>;
2974
+ amount: drizzle_orm_sqlite_core.SQLiteColumn<{
2975
+ name: "amount";
2976
+ tableName: "payment";
2977
+ dataType: "number";
2978
+ columnType: "SQLiteReal";
2979
+ data: number;
2980
+ driverParam: number;
2981
+ notNull: true;
2982
+ hasDefault: false;
2983
+ isPrimaryKey: false;
2984
+ isAutoincrement: false;
2985
+ hasRuntimeDefault: false;
2986
+ enumValues: undefined;
2987
+ baseColumn: never;
2988
+ identity: undefined;
2989
+ generated: undefined;
2990
+ }, {}, {}>;
2991
+ direction: drizzle_orm_sqlite_core.SQLiteColumn<{
2992
+ name: "direction";
2993
+ tableName: "payment";
2994
+ dataType: "string";
2995
+ columnType: "SQLiteText";
2996
+ data: "INCOMING" | "OUTGOING";
2997
+ driverParam: string;
2998
+ notNull: true;
2999
+ hasDefault: false;
3000
+ isPrimaryKey: false;
3001
+ isAutoincrement: false;
3002
+ hasRuntimeDefault: false;
3003
+ enumValues: [string, ...string[]];
3004
+ baseColumn: never;
3005
+ identity: undefined;
3006
+ generated: undefined;
3007
+ }, {}, {
3008
+ length: number | undefined;
3009
+ $type: "INCOMING" | "OUTGOING";
3010
+ }>;
3011
+ paymentType: drizzle_orm_sqlite_core.SQLiteColumn<{
3012
+ name: "payment_type";
3013
+ tableName: "payment";
3014
+ dataType: "string";
3015
+ columnType: "SQLiteText";
3016
+ data: "SEPA" | "SWIFT" | "DOMESTIC" | "UNKNOWN";
3017
+ driverParam: string;
3018
+ notNull: true;
3019
+ hasDefault: false;
3020
+ isPrimaryKey: false;
3021
+ isAutoincrement: false;
3022
+ hasRuntimeDefault: false;
3023
+ enumValues: [string, ...string[]];
3024
+ baseColumn: never;
3025
+ identity: undefined;
3026
+ generated: undefined;
3027
+ }, {}, {
3028
+ length: number | undefined;
3029
+ $type: "SEPA" | "SWIFT" | "DOMESTIC" | "UNKNOWN";
3030
+ }>;
3031
+ currency: drizzle_orm_sqlite_core.SQLiteColumn<{
3032
+ name: "currency";
3033
+ tableName: "payment";
3034
+ dataType: "string";
3035
+ columnType: "SQLiteText";
3036
+ data: "CZK" | "EUR" | "USD" | "PLN" | "RON" | "GBP" | "RUB" | "HUF" | "CHF" | "DKK" | "SEK" | "HRK" | "NOK" | "BGN" | "TRY" | "AUD" | "CAD" | "JPY" | "CNY" | "INR" | "BRL" | "MXN" | "ZAR" | "SGD" | "HKD" | "KRW" | "MYR" | "THB" | "IDR" | "PHP" | "AED" | "SAR" | "ILS" | "EGP" | "NGN" | "PKR" | "COP" | "CLP" | "PEN" | "VND" | "KZT" | "UAH" | "BTC" | "ETH" | "ADA" | "DOT" | "ATOM" | "XRP" | "LTC" | "SOL" | "DOGE" | "MATIC" | "AVAX";
3037
+ driverParam: string;
3038
+ notNull: true;
3039
+ hasDefault: false;
3040
+ isPrimaryKey: false;
3041
+ isAutoincrement: false;
3042
+ hasRuntimeDefault: false;
3043
+ enumValues: [string, ...string[]];
3044
+ baseColumn: never;
3045
+ identity: undefined;
3046
+ generated: undefined;
3047
+ }, {}, {
3048
+ length: number | undefined;
3049
+ $type: "CZK" | "EUR" | "USD" | "PLN" | "RON" | "GBP" | "RUB" | "HUF" | "CHF" | "DKK" | "SEK" | "HRK" | "NOK" | "BGN" | "TRY" | "AUD" | "CAD" | "JPY" | "CNY" | "INR" | "BRL" | "MXN" | "ZAR" | "SGD" | "HKD" | "KRW" | "MYR" | "THB" | "IDR" | "PHP" | "AED" | "SAR" | "ILS" | "EGP" | "NGN" | "PKR" | "COP" | "CLP" | "PEN" | "VND" | "KZT" | "UAH" | "BTC" | "ETH" | "ADA" | "DOT" | "ATOM" | "XRP" | "LTC" | "SOL" | "DOGE" | "MATIC" | "AVAX";
3050
+ }>;
3051
+ status: drizzle_orm_sqlite_core.SQLiteColumn<{
3052
+ name: "status";
3053
+ tableName: "payment";
3054
+ dataType: "string";
3055
+ columnType: "SQLiteText";
3056
+ data: "CREATED" | "PREPARED" | "SIGNED" | "PENDING" | "COMPLETED" | "FAILED";
3057
+ driverParam: string;
3058
+ notNull: true;
3059
+ hasDefault: false;
3060
+ isPrimaryKey: false;
3061
+ isAutoincrement: false;
3062
+ hasRuntimeDefault: false;
3063
+ enumValues: [string, ...string[]];
3064
+ baseColumn: never;
3065
+ identity: undefined;
3066
+ generated: undefined;
3067
+ }, {}, {
3068
+ length: number | undefined;
3069
+ $type: "CREATED" | "PREPARED" | "SIGNED" | "PENDING" | "COMPLETED" | "FAILED";
3070
+ }>;
3071
+ statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
3072
+ name: "status_reason";
3073
+ tableName: "payment";
3074
+ dataType: "string";
3075
+ columnType: "SQLiteText";
3076
+ data: string;
3077
+ driverParam: string;
3078
+ notNull: false;
3079
+ hasDefault: false;
3080
+ isPrimaryKey: false;
3081
+ isAutoincrement: false;
3082
+ hasRuntimeDefault: false;
3083
+ enumValues: [string, ...string[]];
3084
+ baseColumn: never;
3085
+ identity: undefined;
3086
+ generated: undefined;
3087
+ }, {}, {
3088
+ length: number | undefined;
3089
+ }>;
3090
+ batchId: drizzle_orm_sqlite_core.SQLiteColumn<{
3091
+ name: "bank_execution_batch_id";
3092
+ tableName: "payment";
3093
+ dataType: "string";
3094
+ columnType: "SQLiteText";
3095
+ data: string;
3096
+ driverParam: string;
3097
+ notNull: false;
3098
+ hasDefault: false;
3099
+ isPrimaryKey: false;
3100
+ isAutoincrement: false;
3101
+ hasRuntimeDefault: false;
3102
+ enumValues: [string, ...string[]];
3103
+ baseColumn: never;
3104
+ identity: undefined;
3105
+ generated: undefined;
3106
+ }, {}, {
3107
+ length: number | undefined;
3108
+ }>;
3109
+ initiatedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
3110
+ name: "initiated_at";
3111
+ tableName: "payment";
3112
+ dataType: "date";
3113
+ columnType: "SQLiteTimestamp";
3114
+ data: Date;
3115
+ driverParam: number;
3116
+ notNull: false;
3117
+ hasDefault: false;
3118
+ isPrimaryKey: false;
3119
+ isAutoincrement: false;
3120
+ hasRuntimeDefault: false;
3121
+ enumValues: undefined;
3122
+ baseColumn: never;
3123
+ identity: undefined;
3124
+ generated: undefined;
3125
+ }, {}, {}>;
3126
+ vs: drizzle_orm_sqlite_core.SQLiteColumn<{
3127
+ name: "vs";
3128
+ tableName: "payment";
3129
+ dataType: "string";
3130
+ columnType: "SQLiteText";
3131
+ data: string;
3132
+ driverParam: string;
3133
+ notNull: false;
3134
+ hasDefault: false;
3135
+ isPrimaryKey: false;
3136
+ isAutoincrement: false;
3137
+ hasRuntimeDefault: false;
3138
+ enumValues: [string, ...string[]];
3139
+ baseColumn: never;
3140
+ identity: undefined;
3141
+ generated: undefined;
3142
+ }, {}, {
3143
+ length: number | undefined;
3144
+ }>;
3145
+ ss: drizzle_orm_sqlite_core.SQLiteColumn<{
3146
+ name: "ss";
3147
+ tableName: "payment";
3148
+ dataType: "string";
3149
+ columnType: "SQLiteText";
3150
+ data: string;
3151
+ driverParam: string;
3152
+ notNull: false;
3153
+ hasDefault: false;
3154
+ isPrimaryKey: false;
3155
+ isAutoincrement: false;
3156
+ hasRuntimeDefault: false;
3157
+ enumValues: [string, ...string[]];
3158
+ baseColumn: never;
3159
+ identity: undefined;
3160
+ generated: undefined;
3161
+ }, {}, {
3162
+ length: number | undefined;
3163
+ }>;
3164
+ ks: drizzle_orm_sqlite_core.SQLiteColumn<{
3165
+ name: "ks";
3166
+ tableName: "payment";
3167
+ dataType: "string";
3168
+ columnType: "SQLiteText";
3169
+ data: string;
3170
+ driverParam: string;
3171
+ notNull: false;
3172
+ hasDefault: false;
3173
+ isPrimaryKey: false;
3174
+ isAutoincrement: false;
3175
+ hasRuntimeDefault: false;
3176
+ enumValues: [string, ...string[]];
3177
+ baseColumn: never;
3178
+ identity: undefined;
3179
+ generated: undefined;
3180
+ }, {}, {
3181
+ length: number | undefined;
3182
+ }>;
3183
+ message: drizzle_orm_sqlite_core.SQLiteColumn<{
3184
+ name: "message";
3185
+ tableName: "payment";
3186
+ dataType: "string";
3187
+ columnType: "SQLiteText";
3188
+ data: string;
3189
+ driverParam: string;
3190
+ notNull: false;
3191
+ hasDefault: false;
3192
+ isPrimaryKey: false;
3193
+ isAutoincrement: false;
3194
+ hasRuntimeDefault: false;
3195
+ enumValues: [string, ...string[]];
3196
+ baseColumn: never;
3197
+ identity: undefined;
3198
+ generated: undefined;
3199
+ }, {}, {
3200
+ length: number | undefined;
3201
+ }>;
3202
+ chargeBearer: drizzle_orm_sqlite_core.SQLiteColumn<{
3203
+ name: "charge_bearer";
3204
+ tableName: "payment";
3205
+ dataType: "string";
3206
+ columnType: "SQLiteText";
3207
+ data: "SHA" | "OUR" | "BEN";
2691
3208
  driverParam: string;
2692
- notNull: true;
3209
+ notNull: false;
2693
3210
  hasDefault: false;
2694
3211
  isPrimaryKey: false;
2695
3212
  isAutoincrement: false;
2696
3213
  hasRuntimeDefault: false;
2697
- enumValues: undefined;
3214
+ enumValues: ["SHA", "OUR", "BEN"];
2698
3215
  baseColumn: never;
2699
3216
  identity: undefined;
2700
3217
  generated: undefined;
2701
3218
  }, {}, {
2702
- $type: BatchedPayment[];
3219
+ length: number | undefined;
3220
+ $type: "SHA" | "OUR" | "BEN";
2703
3221
  }>;
2704
- metadata: drizzle_orm_sqlite_core.SQLiteColumn<{
2705
- name: "metadata";
2706
- tableName: "batch";
3222
+ instructionPriority: drizzle_orm_sqlite_core.SQLiteColumn<{
3223
+ name: "instruction_priority";
3224
+ tableName: "payment";
3225
+ dataType: "string";
3226
+ columnType: "SQLiteText";
3227
+ data: "NORM" | "HIGH" | "INST";
3228
+ driverParam: string;
3229
+ notNull: false;
3230
+ hasDefault: false;
3231
+ isPrimaryKey: false;
3232
+ isAutoincrement: false;
3233
+ hasRuntimeDefault: false;
3234
+ enumValues: ["NORM", "HIGH", "INST"];
3235
+ baseColumn: never;
3236
+ identity: undefined;
3237
+ generated: undefined;
3238
+ }, {}, {
3239
+ length: number | undefined;
3240
+ $type: "NORM" | "HIGH" | "INST";
3241
+ }>;
3242
+ processedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
3243
+ name: "processed_at";
3244
+ tableName: "payment";
3245
+ dataType: "date";
3246
+ columnType: "SQLiteTimestamp";
3247
+ data: Date;
3248
+ driverParam: number;
3249
+ notNull: false;
3250
+ hasDefault: false;
3251
+ isPrimaryKey: false;
3252
+ isAutoincrement: false;
3253
+ hasRuntimeDefault: false;
3254
+ enumValues: undefined;
3255
+ baseColumn: never;
3256
+ identity: undefined;
3257
+ generated: undefined;
3258
+ }, {}, {}>;
3259
+ creditor: drizzle_orm_sqlite_core.SQLiteColumn<{
3260
+ name: "creditor";
3261
+ tableName: "payment";
2707
3262
  dataType: "json";
2708
3263
  columnType: "SQLiteTextJson";
2709
- data: BatchMetadata;
3264
+ data: BankAccountMetadata;
2710
3265
  driverParam: string;
2711
- notNull: false;
3266
+ notNull: true;
2712
3267
  hasDefault: false;
2713
3268
  isPrimaryKey: false;
2714
3269
  isAutoincrement: false;
@@ -2718,31 +3273,49 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2718
3273
  identity: undefined;
2719
3274
  generated: undefined;
2720
3275
  }, {}, {
2721
- $type: BatchMetadata;
3276
+ $type: BankAccountMetadata;
2722
3277
  }>;
2723
- paymentType: drizzle_orm_sqlite_core.SQLiteColumn<{
2724
- name: "payment_type";
2725
- tableName: "batch";
3278
+ creditorIban: drizzle_orm_sqlite_core.SQLiteColumn<{
3279
+ name: "creditor_iban";
3280
+ tableName: "payment";
2726
3281
  dataType: "string";
2727
3282
  columnType: "SQLiteText";
2728
- data: "SEPA" | "SWIFT" | "DOMESTIC" | "UNKNOWN";
3283
+ data: string;
2729
3284
  driverParam: string;
2730
3285
  notNull: false;
2731
3286
  hasDefault: false;
2732
3287
  isPrimaryKey: false;
2733
3288
  isAutoincrement: false;
2734
3289
  hasRuntimeDefault: false;
2735
- enumValues: ["SEPA", "SWIFT", "DOMESTIC", "UNKNOWN"];
3290
+ enumValues: [string, ...string[]];
2736
3291
  baseColumn: never;
2737
3292
  identity: undefined;
2738
3293
  generated: undefined;
2739
3294
  }, {}, {
2740
3295
  length: number | undefined;
2741
- $type: "SEPA" | "SWIFT" | "DOMESTIC" | "UNKNOWN";
2742
3296
  }>;
2743
- paymentsChecksum: drizzle_orm_sqlite_core.SQLiteColumn<{
2744
- name: "payments_checksum";
2745
- tableName: "batch";
3297
+ debtor: drizzle_orm_sqlite_core.SQLiteColumn<{
3298
+ name: "debtor";
3299
+ tableName: "payment";
3300
+ dataType: "json";
3301
+ columnType: "SQLiteTextJson";
3302
+ data: BankAccountMetadata;
3303
+ driverParam: string;
3304
+ notNull: true;
3305
+ hasDefault: false;
3306
+ isPrimaryKey: false;
3307
+ isAutoincrement: false;
3308
+ hasRuntimeDefault: false;
3309
+ enumValues: undefined;
3310
+ baseColumn: never;
3311
+ identity: undefined;
3312
+ generated: undefined;
3313
+ }, {}, {
3314
+ $type: BankAccountMetadata;
3315
+ }>;
3316
+ debtorIban: drizzle_orm_sqlite_core.SQLiteColumn<{
3317
+ name: "debtor_iban";
3318
+ tableName: "payment";
2746
3319
  dataType: "string";
2747
3320
  columnType: "SQLiteText";
2748
3321
  data: string;
@@ -2761,7 +3334,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2761
3334
  }>;
2762
3335
  id: drizzle_orm_sqlite_core.SQLiteColumn<{
2763
3336
  name: "id";
2764
- tableName: "batch";
3337
+ tableName: "payment";
2765
3338
  dataType: "string";
2766
3339
  columnType: "SQLiteText";
2767
3340
  data: string;
@@ -2780,7 +3353,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2780
3353
  }>;
2781
3354
  createdAt: drizzle_orm_sqlite_core.SQLiteColumn<{
2782
3355
  name: "created_at";
2783
- tableName: "batch";
3356
+ tableName: "payment";
2784
3357
  dataType: "date";
2785
3358
  columnType: "SQLiteTimestamp";
2786
3359
  data: Date;
@@ -2797,7 +3370,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2797
3370
  }, {}, {}>;
2798
3371
  createdBy: drizzle_orm_sqlite_core.SQLiteColumn<{
2799
3372
  name: "created_by";
2800
- tableName: "batch";
3373
+ tableName: "payment";
2801
3374
  dataType: "string";
2802
3375
  columnType: "SQLiteText";
2803
3376
  data: string;
@@ -2816,7 +3389,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2816
3389
  }>;
2817
3390
  updatedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
2818
3391
  name: "updated_at";
2819
- tableName: "batch";
3392
+ tableName: "payment";
2820
3393
  dataType: "date";
2821
3394
  columnType: "SQLiteTimestamp";
2822
3395
  data: Date;
@@ -2833,7 +3406,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2833
3406
  }, {}, {}>;
2834
3407
  updatedBy: drizzle_orm_sqlite_core.SQLiteColumn<{
2835
3408
  name: "updated_by";
2836
- tableName: "batch";
3409
+ tableName: "payment";
2837
3410
  dataType: "string";
2838
3411
  columnType: "SQLiteText";
2839
3412
  data: string;
@@ -2852,7 +3425,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2852
3425
  }>;
2853
3426
  deletedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
2854
3427
  name: "deleted_at";
2855
- tableName: "batch";
3428
+ tableName: "payment";
2856
3429
  dataType: "date";
2857
3430
  columnType: "SQLiteTimestamp";
2858
3431
  data: Date;
@@ -2869,7 +3442,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2869
3442
  }, {}, {}>;
2870
3443
  deletedBy: drizzle_orm_sqlite_core.SQLiteColumn<{
2871
3444
  name: "deleted_by";
2872
- tableName: "batch";
3445
+ tableName: "payment";
2873
3446
  dataType: "string";
2874
3447
  columnType: "SQLiteText";
2875
3448
  data: string;
@@ -2889,19 +3462,22 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2889
3462
  };
2890
3463
  dialect: "sqlite";
2891
3464
  }>;
3465
+ declare const paymentRelations: drizzle_orm.Relations<"payment", {
3466
+ batch: drizzle_orm.One<"batch", false>;
3467
+ }>;
2892
3468
 
2893
- declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2894
- name: "payment";
3469
+ declare const paymentRequest: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3470
+ name: "payment_request";
2895
3471
  schema: undefined;
2896
3472
  columns: {
2897
- correlationId: drizzle_orm_sqlite_core.SQLiteColumn<{
2898
- name: "correlation_id";
2899
- tableName: "payment";
3473
+ batchId: drizzle_orm_sqlite_core.SQLiteColumn<{
3474
+ name: "batch_id";
3475
+ tableName: "payment_request";
2900
3476
  dataType: "string";
2901
3477
  columnType: "SQLiteText";
2902
3478
  data: string;
2903
3479
  driverParam: string;
2904
- notNull: true;
3480
+ notNull: false;
2905
3481
  hasDefault: false;
2906
3482
  isPrimaryKey: false;
2907
3483
  isAutoincrement: false;
@@ -2913,14 +3489,14 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2913
3489
  }, {}, {
2914
3490
  length: number | undefined;
2915
3491
  }>;
2916
- refId: drizzle_orm_sqlite_core.SQLiteColumn<{
2917
- name: "ref_id";
2918
- tableName: "payment";
3492
+ accountId: drizzle_orm_sqlite_core.SQLiteColumn<{
3493
+ name: "account_id";
3494
+ tableName: "payment_request";
2919
3495
  dataType: "string";
2920
3496
  columnType: "SQLiteText";
2921
3497
  data: string;
2922
3498
  driverParam: string;
2923
- notNull: false;
3499
+ notNull: true;
2924
3500
  hasDefault: false;
2925
3501
  isPrimaryKey: false;
2926
3502
  isAutoincrement: false;
@@ -2932,9 +3508,9 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2932
3508
  }, {}, {
2933
3509
  length: number | undefined;
2934
3510
  }>;
2935
- bankRefId: drizzle_orm_sqlite_core.SQLiteColumn<{
2936
- name: "bank_ref_id";
2937
- tableName: "payment";
3511
+ correlationId: drizzle_orm_sqlite_core.SQLiteColumn<{
3512
+ name: "correlation_id";
3513
+ tableName: "payment_request";
2938
3514
  dataType: "string";
2939
3515
  columnType: "SQLiteText";
2940
3516
  data: string;
@@ -2951,14 +3527,33 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2951
3527
  }, {}, {
2952
3528
  length: number | undefined;
2953
3529
  }>;
2954
- accountId: drizzle_orm_sqlite_core.SQLiteColumn<{
2955
- name: "account_id";
2956
- tableName: "payment";
3530
+ refId: drizzle_orm_sqlite_core.SQLiteColumn<{
3531
+ name: "ref_id";
3532
+ tableName: "payment_request";
2957
3533
  dataType: "string";
2958
3534
  columnType: "SQLiteText";
2959
3535
  data: string;
2960
3536
  driverParam: string;
2961
- notNull: true;
3537
+ notNull: false;
3538
+ hasDefault: false;
3539
+ isPrimaryKey: false;
3540
+ isAutoincrement: false;
3541
+ hasRuntimeDefault: false;
3542
+ enumValues: [string, ...string[]];
3543
+ baseColumn: never;
3544
+ identity: undefined;
3545
+ generated: undefined;
3546
+ }, {}, {
3547
+ length: number | undefined;
3548
+ }>;
3549
+ bankRefId: drizzle_orm_sqlite_core.SQLiteColumn<{
3550
+ name: "bank_ref_id";
3551
+ tableName: "payment_request";
3552
+ dataType: "string";
3553
+ columnType: "SQLiteText";
3554
+ data: string;
3555
+ driverParam: string;
3556
+ notNull: false;
2962
3557
  hasDefault: false;
2963
3558
  isPrimaryKey: false;
2964
3559
  isAutoincrement: false;
@@ -2972,7 +3567,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2972
3567
  }>;
2973
3568
  connectorKey: drizzle_orm_sqlite_core.SQLiteColumn<{
2974
3569
  name: "connector_key";
2975
- tableName: "payment";
3570
+ tableName: "payment_request";
2976
3571
  dataType: "string";
2977
3572
  columnType: "SQLiteText";
2978
3573
  data: "ERSTE" | "FINBRICKS" | "MOCK" | "CREDITAS" | "MOCK_COBS" | "FIO" | "MONETA" | "DBU" | "CSAS" | "AIRBANK" | "KB" | "CSOB";
@@ -2992,7 +3587,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
2992
3587
  }>;
2993
3588
  amount: drizzle_orm_sqlite_core.SQLiteColumn<{
2994
3589
  name: "amount";
2995
- tableName: "payment";
3590
+ tableName: "payment_request";
2996
3591
  dataType: "number";
2997
3592
  columnType: "SQLiteReal";
2998
3593
  data: number;
@@ -3007,29 +3602,9 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3007
3602
  identity: undefined;
3008
3603
  generated: undefined;
3009
3604
  }, {}, {}>;
3010
- direction: drizzle_orm_sqlite_core.SQLiteColumn<{
3011
- name: "direction";
3012
- tableName: "payment";
3013
- dataType: "string";
3014
- columnType: "SQLiteText";
3015
- data: "INCOMING" | "OUTGOING";
3016
- driverParam: string;
3017
- notNull: true;
3018
- hasDefault: false;
3019
- isPrimaryKey: false;
3020
- isAutoincrement: false;
3021
- hasRuntimeDefault: false;
3022
- enumValues: [string, ...string[]];
3023
- baseColumn: never;
3024
- identity: undefined;
3025
- generated: undefined;
3026
- }, {}, {
3027
- length: number | undefined;
3028
- $type: "INCOMING" | "OUTGOING";
3029
- }>;
3030
3605
  paymentType: drizzle_orm_sqlite_core.SQLiteColumn<{
3031
3606
  name: "payment_type";
3032
- tableName: "payment";
3607
+ tableName: "payment_request";
3033
3608
  dataType: "string";
3034
3609
  columnType: "SQLiteText";
3035
3610
  data: "SEPA" | "SWIFT" | "DOMESTIC" | "UNKNOWN";
@@ -3039,7 +3614,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3039
3614
  isPrimaryKey: false;
3040
3615
  isAutoincrement: false;
3041
3616
  hasRuntimeDefault: false;
3042
- enumValues: [string, ...string[]];
3617
+ enumValues: ["SEPA", "SWIFT", "DOMESTIC", "UNKNOWN"];
3043
3618
  baseColumn: never;
3044
3619
  identity: undefined;
3045
3620
  generated: undefined;
@@ -3049,7 +3624,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3049
3624
  }>;
3050
3625
  currency: drizzle_orm_sqlite_core.SQLiteColumn<{
3051
3626
  name: "currency";
3052
- tableName: "payment";
3627
+ tableName: "payment_request";
3053
3628
  dataType: "string";
3054
3629
  columnType: "SQLiteText";
3055
3630
  data: "CZK" | "EUR" | "USD" | "PLN" | "RON" | "GBP" | "RUB" | "HUF" | "CHF" | "DKK" | "SEK" | "HRK" | "NOK" | "BGN" | "TRY" | "AUD" | "CAD" | "JPY" | "CNY" | "INR" | "BRL" | "MXN" | "ZAR" | "SGD" | "HKD" | "KRW" | "MYR" | "THB" | "IDR" | "PHP" | "AED" | "SAR" | "ILS" | "EGP" | "NGN" | "PKR" | "COP" | "CLP" | "PEN" | "VND" | "KZT" | "UAH" | "BTC" | "ETH" | "ADA" | "DOT" | "ATOM" | "XRP" | "LTC" | "SOL" | "DOGE" | "MATIC" | "AVAX";
@@ -3069,27 +3644,27 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3069
3644
  }>;
3070
3645
  status: drizzle_orm_sqlite_core.SQLiteColumn<{
3071
3646
  name: "status";
3072
- tableName: "payment";
3647
+ tableName: "payment_request";
3073
3648
  dataType: "string";
3074
3649
  columnType: "SQLiteText";
3075
- data: "PREPARED" | "FAILED" | "PENDING" | "COMPLETED" | "CREATED";
3650
+ data: "CREATED" | "PREPARED" | "SIGNED" | "PENDING" | "COMPLETED" | "FAILED";
3076
3651
  driverParam: string;
3077
3652
  notNull: true;
3078
3653
  hasDefault: false;
3079
3654
  isPrimaryKey: false;
3080
3655
  isAutoincrement: false;
3081
3656
  hasRuntimeDefault: false;
3082
- enumValues: [string, ...string[]];
3657
+ enumValues: ["CREATED", "PREPARED", "SIGNED", "PENDING", "COMPLETED", "FAILED"];
3083
3658
  baseColumn: never;
3084
3659
  identity: undefined;
3085
3660
  generated: undefined;
3086
3661
  }, {}, {
3087
3662
  length: number | undefined;
3088
- $type: "PREPARED" | "FAILED" | "PENDING" | "COMPLETED" | "CREATED";
3663
+ $type: "CREATED" | "PREPARED" | "SIGNED" | "PENDING" | "COMPLETED" | "FAILED";
3089
3664
  }>;
3090
3665
  statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
3091
3666
  name: "status_reason";
3092
- tableName: "payment";
3667
+ tableName: "payment_request";
3093
3668
  dataType: "string";
3094
3669
  columnType: "SQLiteText";
3095
3670
  data: string;
@@ -3106,9 +3681,9 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3106
3681
  }, {}, {
3107
3682
  length: number | undefined;
3108
3683
  }>;
3109
- batchId: drizzle_orm_sqlite_core.SQLiteColumn<{
3110
- name: "bank_execution_batch_id";
3111
- tableName: "payment";
3684
+ authorizationUrl: drizzle_orm_sqlite_core.SQLiteColumn<{
3685
+ name: "authorization_url";
3686
+ tableName: "payment_request";
3112
3687
  dataType: "string";
3113
3688
  columnType: "SQLiteText";
3114
3689
  data: string;
@@ -3127,7 +3702,24 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3127
3702
  }>;
3128
3703
  initiatedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
3129
3704
  name: "initiated_at";
3130
- tableName: "payment";
3705
+ tableName: "payment_request";
3706
+ dataType: "date";
3707
+ columnType: "SQLiteTimestamp";
3708
+ data: Date;
3709
+ driverParam: number;
3710
+ notNull: false;
3711
+ hasDefault: false;
3712
+ isPrimaryKey: false;
3713
+ isAutoincrement: false;
3714
+ hasRuntimeDefault: false;
3715
+ enumValues: undefined;
3716
+ baseColumn: never;
3717
+ identity: undefined;
3718
+ generated: undefined;
3719
+ }, {}, {}>;
3720
+ processedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
3721
+ name: "processed_at";
3722
+ tableName: "payment_request";
3131
3723
  dataType: "date";
3132
3724
  columnType: "SQLiteTimestamp";
3133
3725
  data: Date;
@@ -3144,7 +3736,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3144
3736
  }, {}, {}>;
3145
3737
  vs: drizzle_orm_sqlite_core.SQLiteColumn<{
3146
3738
  name: "vs";
3147
- tableName: "payment";
3739
+ tableName: "payment_request";
3148
3740
  dataType: "string";
3149
3741
  columnType: "SQLiteText";
3150
3742
  data: string;
@@ -3163,7 +3755,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3163
3755
  }>;
3164
3756
  ss: drizzle_orm_sqlite_core.SQLiteColumn<{
3165
3757
  name: "ss";
3166
- tableName: "payment";
3758
+ tableName: "payment_request";
3167
3759
  dataType: "string";
3168
3760
  columnType: "SQLiteText";
3169
3761
  data: string;
@@ -3182,7 +3774,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3182
3774
  }>;
3183
3775
  ks: drizzle_orm_sqlite_core.SQLiteColumn<{
3184
3776
  name: "ks";
3185
- tableName: "payment";
3777
+ tableName: "payment_request";
3186
3778
  dataType: "string";
3187
3779
  columnType: "SQLiteText";
3188
3780
  data: string;
@@ -3201,7 +3793,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3201
3793
  }>;
3202
3794
  message: drizzle_orm_sqlite_core.SQLiteColumn<{
3203
3795
  name: "message";
3204
- tableName: "payment";
3796
+ tableName: "payment_request";
3205
3797
  dataType: "string";
3206
3798
  columnType: "SQLiteText";
3207
3799
  data: string;
@@ -3220,7 +3812,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3220
3812
  }>;
3221
3813
  chargeBearer: drizzle_orm_sqlite_core.SQLiteColumn<{
3222
3814
  name: "charge_bearer";
3223
- tableName: "payment";
3815
+ tableName: "payment_request";
3224
3816
  dataType: "string";
3225
3817
  columnType: "SQLiteText";
3226
3818
  data: "SHA" | "OUR" | "BEN";
@@ -3240,7 +3832,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3240
3832
  }>;
3241
3833
  instructionPriority: drizzle_orm_sqlite_core.SQLiteColumn<{
3242
3834
  name: "instruction_priority";
3243
- tableName: "payment";
3835
+ tableName: "payment_request";
3244
3836
  dataType: "string";
3245
3837
  columnType: "SQLiteText";
3246
3838
  data: "NORM" | "HIGH" | "INST";
@@ -3258,26 +3850,9 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3258
3850
  length: number | undefined;
3259
3851
  $type: "NORM" | "HIGH" | "INST";
3260
3852
  }>;
3261
- processedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
3262
- name: "processed_at";
3263
- tableName: "payment";
3264
- dataType: "date";
3265
- columnType: "SQLiteTimestamp";
3266
- data: Date;
3267
- driverParam: number;
3268
- notNull: false;
3269
- hasDefault: false;
3270
- isPrimaryKey: false;
3271
- isAutoincrement: false;
3272
- hasRuntimeDefault: false;
3273
- enumValues: undefined;
3274
- baseColumn: never;
3275
- identity: undefined;
3276
- generated: undefined;
3277
- }, {}, {}>;
3278
3853
  creditor: drizzle_orm_sqlite_core.SQLiteColumn<{
3279
3854
  name: "creditor";
3280
- tableName: "payment";
3855
+ tableName: "payment_request";
3281
3856
  dataType: "json";
3282
3857
  columnType: "SQLiteTextJson";
3283
3858
  data: BankAccountMetadata;
@@ -3296,7 +3871,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3296
3871
  }>;
3297
3872
  creditorIban: drizzle_orm_sqlite_core.SQLiteColumn<{
3298
3873
  name: "creditor_iban";
3299
- tableName: "payment";
3874
+ tableName: "payment_request";
3300
3875
  dataType: "string";
3301
3876
  columnType: "SQLiteText";
3302
3877
  data: string;
@@ -3315,7 +3890,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3315
3890
  }>;
3316
3891
  debtor: drizzle_orm_sqlite_core.SQLiteColumn<{
3317
3892
  name: "debtor";
3318
- tableName: "payment";
3893
+ tableName: "payment_request";
3319
3894
  dataType: "json";
3320
3895
  columnType: "SQLiteTextJson";
3321
3896
  data: BankAccountMetadata;
@@ -3334,7 +3909,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3334
3909
  }>;
3335
3910
  debtorIban: drizzle_orm_sqlite_core.SQLiteColumn<{
3336
3911
  name: "debtor_iban";
3337
- tableName: "payment";
3912
+ tableName: "payment_request";
3338
3913
  dataType: "string";
3339
3914
  columnType: "SQLiteText";
3340
3915
  data: string;
@@ -3353,7 +3928,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3353
3928
  }>;
3354
3929
  id: drizzle_orm_sqlite_core.SQLiteColumn<{
3355
3930
  name: "id";
3356
- tableName: "payment";
3931
+ tableName: "payment_request";
3357
3932
  dataType: "string";
3358
3933
  columnType: "SQLiteText";
3359
3934
  data: string;
@@ -3372,7 +3947,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3372
3947
  }>;
3373
3948
  createdAt: drizzle_orm_sqlite_core.SQLiteColumn<{
3374
3949
  name: "created_at";
3375
- tableName: "payment";
3950
+ tableName: "payment_request";
3376
3951
  dataType: "date";
3377
3952
  columnType: "SQLiteTimestamp";
3378
3953
  data: Date;
@@ -3389,7 +3964,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3389
3964
  }, {}, {}>;
3390
3965
  createdBy: drizzle_orm_sqlite_core.SQLiteColumn<{
3391
3966
  name: "created_by";
3392
- tableName: "payment";
3967
+ tableName: "payment_request";
3393
3968
  dataType: "string";
3394
3969
  columnType: "SQLiteText";
3395
3970
  data: string;
@@ -3408,7 +3983,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3408
3983
  }>;
3409
3984
  updatedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
3410
3985
  name: "updated_at";
3411
- tableName: "payment";
3986
+ tableName: "payment_request";
3412
3987
  dataType: "date";
3413
3988
  columnType: "SQLiteTimestamp";
3414
3989
  data: Date;
@@ -3425,7 +4000,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3425
4000
  }, {}, {}>;
3426
4001
  updatedBy: drizzle_orm_sqlite_core.SQLiteColumn<{
3427
4002
  name: "updated_by";
3428
- tableName: "payment";
4003
+ tableName: "payment_request";
3429
4004
  dataType: "string";
3430
4005
  columnType: "SQLiteText";
3431
4006
  data: string;
@@ -3444,7 +4019,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3444
4019
  }>;
3445
4020
  deletedAt: drizzle_orm_sqlite_core.SQLiteColumn<{
3446
4021
  name: "deleted_at";
3447
- tableName: "payment";
4022
+ tableName: "payment_request";
3448
4023
  dataType: "date";
3449
4024
  columnType: "SQLiteTimestamp";
3450
4025
  data: Date;
@@ -3461,7 +4036,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3461
4036
  }, {}, {}>;
3462
4037
  deletedBy: drizzle_orm_sqlite_core.SQLiteColumn<{
3463
4038
  name: "deleted_by";
3464
- tableName: "payment";
4039
+ tableName: "payment_request";
3465
4040
  dataType: "string";
3466
4041
  columnType: "SQLiteText";
3467
4042
  data: string;
@@ -3481,8 +4056,9 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
3481
4056
  };
3482
4057
  dialect: "sqlite";
3483
4058
  }>;
3484
- declare const paymentRelations: drizzle_orm.Relations<"payment", {
4059
+ declare const paymentRequestRelations: drizzle_orm.Relations<"payment_request", {
3485
4060
  batch: drizzle_orm.One<"batch", false>;
4061
+ account: drizzle_orm.One<"account", true>;
3486
4062
  }>;
3487
4063
 
3488
4064
  declare const ott: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
@@ -4481,6 +5057,8 @@ declare const schema_batch: typeof batch;
4481
5057
  declare const schema_ott: typeof ott;
4482
5058
  declare const schema_payment: typeof payment;
4483
5059
  declare const schema_paymentRelations: typeof paymentRelations;
5060
+ declare const schema_paymentRequest: typeof paymentRequest;
5061
+ declare const schema_paymentRequestRelations: typeof paymentRequestRelations;
4484
5062
  declare namespace schema {
4485
5063
  export {
4486
5064
  schema_account as account,
@@ -4489,6 +5067,8 @@ declare namespace schema {
4489
5067
  schema_ott as ott,
4490
5068
  schema_payment as payment,
4491
5069
  schema_paymentRelations as paymentRelations,
5070
+ schema_paymentRequest as paymentRequest,
5071
+ schema_paymentRequestRelations as paymentRequestRelations,
4492
5072
  };
4493
5073
  }
4494
5074
 
@@ -4539,13 +5119,10 @@ type AccountAssignedPayment = Omit<PaymentInsertType, 'bankRefId' | 'status'> &
4539
5119
  /**
4540
5120
  * Stage 3: Batched Payment
4541
5121
  *
4542
- * Payment stored in a batch, ready for processing.
4543
- * Semantically same as AccountAssignedPayment but stored in batch.payments[]
5122
+ * Payment assigned to a batch, ready for processing.
5123
+ * Semantically same as AccountAssignedPayment but linked to a batch via payment_request table.
4544
5124
  * Missing: bankRefId (batch not yet processed)
4545
5125
  * Status: Still 'CREATED'
4546
- *
4547
- * Used in: Batch.payments array in database
4548
- * Note: This is the type stored in batch.payments JSON field
4549
5126
  */
4550
5127
  type BatchedPayment = Omit<PaymentInsertType, 'bankRefId' | 'status'> & {
4551
5128
  status: 'CREATED';
@@ -4594,7 +5171,7 @@ declare function isPaymentPrepared(payment: PaymentLifecycle): payment is Prepar
4594
5171
  /**
4595
5172
  * Type guard to check if payment is completed
4596
5173
  */
4597
- declare function isPaymentCompleted(payment: PaymentLifecycle): payment is CompletedPayment;
5174
+ declare function isPaymentCompleted(payment: PaymentLifecycle | PaymentInsertType): payment is CompletedPayment;
4598
5175
 
4599
5176
  interface PaymentSelectType extends InferSelectModel<typeof tables.payment> {
4600
5177
  }
@@ -4604,6 +5181,10 @@ interface BatchSelectType extends InferSelectModel<typeof tables.batch> {
4604
5181
  }
4605
5182
  interface BatchInsertType extends InferInsertModel<typeof tables.batch> {
4606
5183
  }
5184
+ interface PaymentRequestSelectType extends InferSelectModel<typeof tables.paymentRequest> {
5185
+ }
5186
+ interface PaymentRequestInsertType extends InferInsertModel<typeof tables.paymentRequest> {
5187
+ }
4607
5188
  type ParsedBankPayment = {
4608
5189
  raw: object;
4609
5190
  parsed: PaymentInsertType;
@@ -4761,5 +5342,5 @@ declare function isBatchFailed(batch: {
4761
5342
  status?: string | null;
4762
5343
  }): batch is CompletedBatch;
4763
5344
 
4764
- export { BATCH_STATUSES as G, IBankConnector as I, CHARGE_BEARERS as N, CONNECTOR_KEYS as O, COUNTRY_CODES as Q, CREDENTIALS_TYPES as R, INSTRUCTION_PRIORITIES as W, PAYMENT_DIRECTIONS as Y, PAYMENT_STATUSES as Z, PAYMENT_TYPES as _, TOKEN_TYPES as a8, accountCredentialsInsertSchema as aa, accountCredentialsSelectSchema as ab, accountCredentialsUpdateSchema as ac, accountInsertSchema as ad, accountSelectSchema as ae, accountUpdateSchema as af, hasPaymentAccountAssigned as ag, isBatchCompleted as ah, isBatchFailed as ai, isBatchInitiated as aj, isBatchOpen as ak, isBatchProcessing as al, isBatchReadyToSign as am, isBatchSigned as an, isPaymentCompleted as ao, isPaymentPrepared as ap, account as aq, accountCredentials as ar, batch as as, ott as at, payment as au, paymentRelations as av, tables as t, ACCOUNT_STATUSES as w };
4765
- export type { PaymentDirection as $, AccountSelectType as A, BatchSelectType as B, ConfigEnvironmentBank as C, AccountPatchType as D, AccountStatus as E, AccountUpdateType as F, BankAccountWithLastSync as H, BatchInsertType as J, BatchLifecycle as K, LastSyncMetadata as L, BatchPayment as M, PaymentSelectType as P, ChargeBearer as S, CompletedBatch as T, CreatedBatch as U, CredentialsType as V, InstructionPriority as X, ConnectorKey as a, PaymentFailedInsertType as a0, PaymentInsertType as a1, PaymentLifecycle as a2, PaymentPreparedInsertType as a3, ProcessingBatch as a4, ReadyToSignBatch as a5, ResolvedCredentials as a6, SignedBatch as a7, TokenType as a9, CurrencyCode as b, BankCode as c, CountryCode as d, ConnectedAccount as e, CredentialsResolver as f, AccountCredentialsInsertType as g, AccountInsertType as h, BatchedPayment as i, InitiatedBatch as j, IncomingPayment as k, InitiatedPayment as l, ParsedBankPayment as m, PaymentStatus as n, BatchStatus as o, PaymentType as p, BatchMetadata as q, Currency as r, AccountAssignedPayment as s, PreparedPayment as u, CompletedPayment as v, AccountCredentialsPatchType as x, AccountCredentialsSelectType as y, AccountCredentialsUpdateType as z };
5345
+ export { PAYMENT_STATUSES as $, BATCH_STATUSES as F, IBankConnector as I, CHARGE_BEARERS as N, CONNECTOR_KEYS as O, COUNTRY_CODES as Q, CREDENTIALS_TYPES as R, INSTRUCTION_PRIORITIES as Y, PAYMENT_DIRECTIONS as _, PAYMENT_TYPES as a0, TOKEN_TYPES as aa, accountCredentialsInsertSchema as ac, accountCredentialsSelectSchema as ad, accountCredentialsUpdateSchema as ae, accountInsertSchema as af, accountSelectSchema as ag, accountUpdateSchema as ah, hasPaymentAccountAssigned as ai, isBatchCompleted as aj, isBatchFailed as ak, isBatchInitiated as al, isBatchOpen as am, isBatchProcessing as an, isBatchReadyToSign as ao, isBatchSigned as ap, isPaymentCompleted as aq, isPaymentPrepared as ar, account as as, accountCredentials as at, batch as au, ott as av, payment as aw, paymentRelations as ax, paymentRequest as ay, paymentRequestRelations as az, tables as t, ACCOUNT_STATUSES as v };
5346
+ export type { AccountSelectType as A, BatchSelectType as B, ConfigEnvironmentBank as C, AccountStatus as D, AccountUpdateType as E, BankAccountWithLastSync as G, BankCode as H, BatchInsertType as J, BatchLifecycle as K, LastSyncMetadata as L, BatchPayment as M, PaymentSelectType as P, ChargeBearer as S, CompletedBatch as T, CountryCode as U, CreatedBatch as V, CredentialsType as W, CurrencyCode as X, InstructionPriority as Z, PaymentRequestSelectType as a, PaymentDirection as a1, PaymentFailedInsertType as a2, PaymentInsertType as a3, PaymentLifecycle as a4, PaymentPreparedInsertType as a5, ProcessingBatch as a6, ReadyToSignBatch as a7, ResolvedCredentials as a8, SignedBatch as a9, TokenType as ab, ConnectorKey as b, ConnectedAccount as c, CredentialsResolver as d, AccountCredentialsInsertType as e, AccountInsertType as f, BatchedPayment as g, InitiatedBatch as h, IncomingPayment as i, InitiatedPayment as j, ParsedBankPayment as k, PaymentStatus as l, BatchStatus as m, PaymentType as n, BatchMetadata as o, Currency as p, AccountAssignedPayment as q, PreparedPayment as r, CompletedPayment as s, PaymentRequestInsertType as u, AccountCredentialsPatchType as w, AccountCredentialsSelectType as x, AccountCredentialsUpdateType as y, AccountPatchType as z };