@develit-services/bank 0.0.8 → 0.0.10

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,6 +1,6 @@
1
1
  import { Environment } from '@develit-io/backend-sdk';
2
2
  import { BANK_CODES, CURRENCY_CODES, CODES } from '@develit-io/general-codes';
3
- import { a as PaymentInsertType, t as tables } from './bank.CBNQZ5Pd.cjs';
3
+ import { a as PaymentInsertType, t as tables } from './bank.dxpKOn1t.js';
4
4
  import { DrizzleD1Database } from 'drizzle-orm/d1';
5
5
 
6
6
  declare const PAYMENT_TYPES: readonly ["SEPA", "SWIFT", "IFSC", "DOMESTIC"];
@@ -29,6 +29,9 @@ interface SyncLog {
29
29
  lastSyncedAt: Date;
30
30
  }
31
31
 
32
+ interface BankAccountWithLastSync extends ConfigBankAccount {
33
+ lastSyncAt: SyncLog;
34
+ }
32
35
  type ConnectorKey = 'ERSTE' | 'FINBRICKS' | 'MOCK' | 'CREDITAS' | 'MOCK_COBS' | 'FIO';
33
36
  interface ConfigBankAccount {
34
37
  connectorKey: ConnectorKey;
@@ -43,8 +46,9 @@ interface ConfigBankAccount {
43
46
  currency: CurrencyCode;
44
47
  production: boolean;
45
48
  }
46
- interface BankAccountWithLastSync extends ConfigBankAccount {
47
- lastSyncAt: SyncLog;
49
+ interface ConfigEnvironmentBankAccount {
50
+ stagingAccounts: ConfigBankAccount[];
51
+ productionAccounts: ConfigBankAccount[];
48
52
  }
49
53
 
50
54
  type WithStatus<T extends {
@@ -94,5 +98,5 @@ interface IncomingPaymentMessage extends PaymentInsertType {
94
98
  interface OutgoingPaymentMessage extends PaymentInsertType {
95
99
  }
96
100
 
97
- export { IBankConnector as I, BATCH_STATUSES as k, PAYMENT_TYPES as m, PAYMENT_STATUSES as o, PAYMENT_DIRECTIONS as r, COUNTRY_CODES as t };
98
- export type { AuthInput as A, BankAccountWithLastSync as B, ConfigBankAccount as C, OutgoingPaymentMessage as O, PaymentPreparedInsertType as P, SyncLog as S, ConnectorKey as a, CurrencyCode as b, BankCode as c, CountryCode as d, IncomingPaymentMessage as e, InitiatedBatch as f, InitiatedPayment as g, BatchMetadata as h, Currency as i, PaymentFailedInsertType as j, BatchStatus as l, PaymentType as n, paymentInitializedInsertType as p, PaymentStatus as q, PaymentDirection as s };
101
+ export { IBankConnector as I, BATCH_STATUSES as l, PAYMENT_TYPES as n, PAYMENT_STATUSES as q, PAYMENT_DIRECTIONS as s, COUNTRY_CODES as u };
102
+ export type { AuthInput as A, BankAccountWithLastSync as B, ConfigEnvironmentBankAccount as C, OutgoingPaymentMessage as O, PaymentPreparedInsertType as P, SyncLog as S, ConfigBankAccount as a, ConnectorKey as b, CurrencyCode as c, BankCode as d, CountryCode as e, IncomingPaymentMessage as f, InitiatedBatch as g, InitiatedPayment as h, BatchMetadata as i, Currency as j, PaymentFailedInsertType as k, BatchStatus as m, PaymentType as o, paymentInitializedInsertType as p, PaymentStatus as r, PaymentDirection as t };
@@ -1,6 +1,6 @@
1
1
  import { Environment } from '@develit-io/backend-sdk';
2
2
  import { BANK_CODES, CURRENCY_CODES, CODES } from '@develit-io/general-codes';
3
- import { a as PaymentInsertType, t as tables } from './bank.CBNQZ5Pd.mjs';
3
+ import { a as PaymentInsertType, t as tables } from './bank.dxpKOn1t.cjs';
4
4
  import { DrizzleD1Database } from 'drizzle-orm/d1';
5
5
 
6
6
  declare const PAYMENT_TYPES: readonly ["SEPA", "SWIFT", "IFSC", "DOMESTIC"];
@@ -29,6 +29,9 @@ interface SyncLog {
29
29
  lastSyncedAt: Date;
30
30
  }
31
31
 
32
+ interface BankAccountWithLastSync extends ConfigBankAccount {
33
+ lastSyncAt: SyncLog;
34
+ }
32
35
  type ConnectorKey = 'ERSTE' | 'FINBRICKS' | 'MOCK' | 'CREDITAS' | 'MOCK_COBS' | 'FIO';
33
36
  interface ConfigBankAccount {
34
37
  connectorKey: ConnectorKey;
@@ -43,8 +46,9 @@ interface ConfigBankAccount {
43
46
  currency: CurrencyCode;
44
47
  production: boolean;
45
48
  }
46
- interface BankAccountWithLastSync extends ConfigBankAccount {
47
- lastSyncAt: SyncLog;
49
+ interface ConfigEnvironmentBankAccount {
50
+ stagingAccounts: ConfigBankAccount[];
51
+ productionAccounts: ConfigBankAccount[];
48
52
  }
49
53
 
50
54
  type WithStatus<T extends {
@@ -94,5 +98,5 @@ interface IncomingPaymentMessage extends PaymentInsertType {
94
98
  interface OutgoingPaymentMessage extends PaymentInsertType {
95
99
  }
96
100
 
97
- export { IBankConnector as I, BATCH_STATUSES as k, PAYMENT_TYPES as m, PAYMENT_STATUSES as o, PAYMENT_DIRECTIONS as r, COUNTRY_CODES as t };
98
- export type { AuthInput as A, BankAccountWithLastSync as B, ConfigBankAccount as C, OutgoingPaymentMessage as O, PaymentPreparedInsertType as P, SyncLog as S, ConnectorKey as a, CurrencyCode as b, BankCode as c, CountryCode as d, IncomingPaymentMessage as e, InitiatedBatch as f, InitiatedPayment as g, BatchMetadata as h, Currency as i, PaymentFailedInsertType as j, BatchStatus as l, PaymentType as n, paymentInitializedInsertType as p, PaymentStatus as q, PaymentDirection as s };
101
+ export { IBankConnector as I, BATCH_STATUSES as l, PAYMENT_TYPES as n, PAYMENT_STATUSES as q, PAYMENT_DIRECTIONS as s, COUNTRY_CODES as u };
102
+ export type { AuthInput as A, BankAccountWithLastSync as B, ConfigEnvironmentBankAccount as C, OutgoingPaymentMessage as O, PaymentPreparedInsertType as P, SyncLog as S, ConfigBankAccount as a, ConnectorKey as b, CurrencyCode as c, BankCode as d, CountryCode as e, IncomingPaymentMessage as f, InitiatedBatch as g, InitiatedPayment as h, BatchMetadata as i, Currency as j, PaymentFailedInsertType as k, BatchStatus as m, PaymentType as o, paymentInitializedInsertType as p, PaymentStatus as r, PaymentDirection as t };
@@ -82,10 +82,10 @@ declare const paymentInsertTypeZod: z.ZodObject<{
82
82
  }>;
83
83
  status: z.ZodEnum<{
84
84
  PREPARED: "PREPARED";
85
- COMPLETED: "COMPLETED";
86
- FAILED: "FAILED";
87
85
  INITIALIZED: "INITIALIZED";
86
+ FAILED: "FAILED";
88
87
  PENDING: "PENDING";
88
+ COMPLETED: "COMPLETED";
89
89
  CREATED: "CREATED";
90
90
  }>;
91
91
  batchId: z.ZodString;
@@ -163,7 +163,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
163
163
  tableName: "batch";
164
164
  dataType: "string";
165
165
  columnType: "SQLiteText";
166
- data: "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | "PREPARED" | "COMPLETED" | "FAILED";
166
+ data: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN";
167
167
  driverParam: string;
168
168
  notNull: false;
169
169
  hasDefault: false;
@@ -176,7 +176,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
176
176
  generated: undefined;
177
177
  }, {}, {
178
178
  length: number | undefined;
179
- $type: "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | "PREPARED" | "COMPLETED" | "FAILED";
179
+ $type: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN";
180
180
  }>;
181
181
  payments: drizzle_orm_sqlite_core.SQLiteColumn<{
182
182
  name: "payments";
@@ -414,7 +414,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
414
414
  tableName: "payment";
415
415
  dataType: "string";
416
416
  columnType: "SQLiteText";
417
- data: "PREPARED" | "COMPLETED" | "FAILED" | "INITIALIZED" | "PENDING" | "CREATED";
417
+ data: "PREPARED" | "INITIALIZED" | "FAILED" | "PENDING" | "COMPLETED" | "CREATED";
418
418
  driverParam: string;
419
419
  notNull: true;
420
420
  hasDefault: false;
@@ -427,7 +427,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
427
427
  generated: undefined;
428
428
  }, {}, {
429
429
  length: number | undefined;
430
- $type: "PREPARED" | "COMPLETED" | "FAILED" | "INITIALIZED" | "PENDING" | "CREATED";
430
+ $type: "PREPARED" | "INITIALIZED" | "FAILED" | "PENDING" | "COMPLETED" | "CREATED";
431
431
  }>;
432
432
  statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
433
433
  name: "status_reason";
@@ -82,10 +82,10 @@ declare const paymentInsertTypeZod: z.ZodObject<{
82
82
  }>;
83
83
  status: z.ZodEnum<{
84
84
  PREPARED: "PREPARED";
85
- COMPLETED: "COMPLETED";
86
- FAILED: "FAILED";
87
85
  INITIALIZED: "INITIALIZED";
86
+ FAILED: "FAILED";
88
87
  PENDING: "PENDING";
88
+ COMPLETED: "COMPLETED";
89
89
  CREATED: "CREATED";
90
90
  }>;
91
91
  batchId: z.ZodString;
@@ -163,7 +163,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
163
163
  tableName: "batch";
164
164
  dataType: "string";
165
165
  columnType: "SQLiteText";
166
- data: "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | "PREPARED" | "COMPLETED" | "FAILED";
166
+ data: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN";
167
167
  driverParam: string;
168
168
  notNull: false;
169
169
  hasDefault: false;
@@ -176,7 +176,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
176
176
  generated: undefined;
177
177
  }, {}, {
178
178
  length: number | undefined;
179
- $type: "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | "PREPARED" | "COMPLETED" | "FAILED";
179
+ $type: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN";
180
180
  }>;
181
181
  payments: drizzle_orm_sqlite_core.SQLiteColumn<{
182
182
  name: "payments";
@@ -414,7 +414,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
414
414
  tableName: "payment";
415
415
  dataType: "string";
416
416
  columnType: "SQLiteText";
417
- data: "PREPARED" | "COMPLETED" | "FAILED" | "INITIALIZED" | "PENDING" | "CREATED";
417
+ data: "PREPARED" | "INITIALIZED" | "FAILED" | "PENDING" | "COMPLETED" | "CREATED";
418
418
  driverParam: string;
419
419
  notNull: true;
420
420
  hasDefault: false;
@@ -427,7 +427,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
427
427
  generated: undefined;
428
428
  }, {}, {
429
429
  length: number | undefined;
430
- $type: "PREPARED" | "COMPLETED" | "FAILED" | "INITIALIZED" | "PENDING" | "CREATED";
430
+ $type: "PREPARED" | "INITIALIZED" | "FAILED" | "PENDING" | "COMPLETED" | "CREATED";
431
431
  }>;
432
432
  statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
433
433
  name: "status_reason";
@@ -82,10 +82,10 @@ declare const paymentInsertTypeZod: z.ZodObject<{
82
82
  }>;
83
83
  status: z.ZodEnum<{
84
84
  PREPARED: "PREPARED";
85
- COMPLETED: "COMPLETED";
86
- FAILED: "FAILED";
87
85
  INITIALIZED: "INITIALIZED";
86
+ FAILED: "FAILED";
88
87
  PENDING: "PENDING";
88
+ COMPLETED: "COMPLETED";
89
89
  CREATED: "CREATED";
90
90
  }>;
91
91
  batchId: z.ZodString;
@@ -163,7 +163,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
163
163
  tableName: "batch";
164
164
  dataType: "string";
165
165
  columnType: "SQLiteText";
166
- data: "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | "PREPARED" | "COMPLETED" | "FAILED";
166
+ data: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN";
167
167
  driverParam: string;
168
168
  notNull: false;
169
169
  hasDefault: false;
@@ -176,7 +176,7 @@ declare const batch: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
176
176
  generated: undefined;
177
177
  }, {}, {
178
178
  length: number | undefined;
179
- $type: "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN" | "PREPARED" | "COMPLETED" | "FAILED";
179
+ $type: "PREPARED" | "FAILED" | "COMPLETED" | "OPEN" | "WAITING_FOR_PROCESSING" | "PROCESSING" | "READY_TO_SIGN";
180
180
  }>;
181
181
  payments: drizzle_orm_sqlite_core.SQLiteColumn<{
182
182
  name: "payments";
@@ -414,7 +414,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
414
414
  tableName: "payment";
415
415
  dataType: "string";
416
416
  columnType: "SQLiteText";
417
- data: "PREPARED" | "COMPLETED" | "FAILED" | "INITIALIZED" | "PENDING" | "CREATED";
417
+ data: "PREPARED" | "INITIALIZED" | "FAILED" | "PENDING" | "COMPLETED" | "CREATED";
418
418
  driverParam: string;
419
419
  notNull: true;
420
420
  hasDefault: false;
@@ -427,7 +427,7 @@ declare const payment: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
427
427
  generated: undefined;
428
428
  }, {}, {
429
429
  length: number | undefined;
430
- $type: "PREPARED" | "COMPLETED" | "FAILED" | "INITIALIZED" | "PENDING" | "CREATED";
430
+ $type: "PREPARED" | "INITIALIZED" | "FAILED" | "PENDING" | "COMPLETED" | "CREATED";
431
431
  }>;
432
432
  statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
433
433
  name: "status_reason";
@@ -1,6 +1,6 @@
1
1
  import { Environment } from '@develit-io/backend-sdk';
2
2
  import { BANK_CODES, CURRENCY_CODES, CODES } from '@develit-io/general-codes';
3
- import { a as PaymentInsertType, t as tables } from './bank.CBNQZ5Pd.js';
3
+ import { a as PaymentInsertType, t as tables } from './bank.dxpKOn1t.mjs';
4
4
  import { DrizzleD1Database } from 'drizzle-orm/d1';
5
5
 
6
6
  declare const PAYMENT_TYPES: readonly ["SEPA", "SWIFT", "IFSC", "DOMESTIC"];
@@ -29,6 +29,9 @@ interface SyncLog {
29
29
  lastSyncedAt: Date;
30
30
  }
31
31
 
32
+ interface BankAccountWithLastSync extends ConfigBankAccount {
33
+ lastSyncAt: SyncLog;
34
+ }
32
35
  type ConnectorKey = 'ERSTE' | 'FINBRICKS' | 'MOCK' | 'CREDITAS' | 'MOCK_COBS' | 'FIO';
33
36
  interface ConfigBankAccount {
34
37
  connectorKey: ConnectorKey;
@@ -43,8 +46,9 @@ interface ConfigBankAccount {
43
46
  currency: CurrencyCode;
44
47
  production: boolean;
45
48
  }
46
- interface BankAccountWithLastSync extends ConfigBankAccount {
47
- lastSyncAt: SyncLog;
49
+ interface ConfigEnvironmentBankAccount {
50
+ stagingAccounts: ConfigBankAccount[];
51
+ productionAccounts: ConfigBankAccount[];
48
52
  }
49
53
 
50
54
  type WithStatus<T extends {
@@ -94,5 +98,5 @@ interface IncomingPaymentMessage extends PaymentInsertType {
94
98
  interface OutgoingPaymentMessage extends PaymentInsertType {
95
99
  }
96
100
 
97
- export { IBankConnector as I, BATCH_STATUSES as k, PAYMENT_TYPES as m, PAYMENT_STATUSES as o, PAYMENT_DIRECTIONS as r, COUNTRY_CODES as t };
98
- export type { AuthInput as A, BankAccountWithLastSync as B, ConfigBankAccount as C, OutgoingPaymentMessage as O, PaymentPreparedInsertType as P, SyncLog as S, ConnectorKey as a, CurrencyCode as b, BankCode as c, CountryCode as d, IncomingPaymentMessage as e, InitiatedBatch as f, InitiatedPayment as g, BatchMetadata as h, Currency as i, PaymentFailedInsertType as j, BatchStatus as l, PaymentType as n, paymentInitializedInsertType as p, PaymentStatus as q, PaymentDirection as s };
101
+ export { IBankConnector as I, BATCH_STATUSES as l, PAYMENT_TYPES as n, PAYMENT_STATUSES as q, PAYMENT_DIRECTIONS as s, COUNTRY_CODES as u };
102
+ export type { AuthInput as A, BankAccountWithLastSync as B, ConfigEnvironmentBankAccount as C, OutgoingPaymentMessage as O, PaymentPreparedInsertType as P, SyncLog as S, ConfigBankAccount as a, ConnectorKey as b, CurrencyCode as c, BankCode as d, CountryCode as e, IncomingPaymentMessage as f, InitiatedBatch as g, InitiatedPayment as h, BatchMetadata as i, Currency as j, PaymentFailedInsertType as k, BatchStatus as m, PaymentType as o, paymentInitializedInsertType as p, PaymentStatus as r, PaymentDirection as t };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@develit-services/bank",
3
- "version": "0.0.8",
3
+ "version": "0.0.10",
4
4
  "author": "Develit.io s.r.o.",
5
5
  "type": "module",
6
6
  "exports": {