@develit-services/ledger 0.0.15 → 0.0.16
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/database/schema.cjs +2 -2
- package/dist/database/schema.d.cts +1 -1
- package/dist/database/schema.d.mts +1 -1
- package/dist/database/schema.d.ts +1 -1
- package/dist/database/schema.mjs +2 -2
- package/dist/export/worker.cjs +7 -5
- package/dist/export/worker.d.cts +2 -2
- package/dist/export/worker.d.mts +2 -2
- package/dist/export/worker.d.ts +2 -2
- package/dist/export/worker.mjs +7 -5
- package/dist/shared/{ledger.ts44O6FU.d.ts → ledger.BvbOZ0WG.d.cts} +75 -7
- package/dist/shared/{ledger.C-t6MiyI.mjs → ledger.CYkZYSMS.mjs} +12 -6
- package/dist/shared/{ledger.B_rvkGCN.cjs → ledger.CcYWtEGS.cjs} +1 -1
- package/dist/shared/{ledger.UBCm2g3M.d.cts → ledger.Cd1qa4GB.d.ts} +75 -7
- package/dist/shared/{ledger.CB2NrA0w.cjs → ledger.CwcPuqoq.cjs} +11 -5
- package/dist/shared/{ledger.BisWaucp.d.mts → ledger.DRm7L41a.d.mts} +75 -7
- package/dist/shared/{ledger.x5MljBDs.d.mts → ledger.N4btQFi1.d.cts} +6 -7
- package/dist/shared/{ledger.x5MljBDs.d.ts → ledger.N4btQFi1.d.mts} +6 -7
- package/dist/shared/{ledger.x5MljBDs.d.cts → ledger.N4btQFi1.d.ts} +6 -7
- package/dist/shared/{ledger.62Uvzk2B.mjs → ledger.al23fGGy.mjs} +1 -1
- package/dist/types.cjs +1 -1
- package/dist/types.d.cts +3 -3
- package/dist/types.d.mts +3 -3
- package/dist/types.d.ts +3 -3
- package/dist/types.mjs +1 -1
- package/package.json +2 -2
package/dist/database/schema.cjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const database_schema = require('../shared/ledger.
|
|
3
|
+
const database_schema = require('../shared/ledger.CcYWtEGS.cjs');
|
|
4
4
|
require('@develit-io/backend-sdk');
|
|
5
5
|
require('drizzle-orm');
|
|
6
6
|
require('drizzle-orm/sqlite-core');
|
|
7
|
-
require('../shared/ledger.
|
|
7
|
+
require('../shared/ledger.CwcPuqoq.cjs');
|
|
8
8
|
require('@develit-io/general-codes');
|
|
9
9
|
require('zod');
|
|
10
10
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { F as account, G as accountIdentifier, H as accountIdentifierMapping, L as accountIdentifierMappingRelations, K as accountIdentifierRelations, J as accountRelations, M as entry, N as transaction } from '../shared/ledger.
|
|
1
|
+
export { F as account, G as accountIdentifier, H as accountIdentifierMapping, L as accountIdentifierMappingRelations, K as accountIdentifierRelations, J as accountRelations, M as entry, N as transaction } from '../shared/ledger.N4btQFi1.cjs';
|
|
2
2
|
import 'drizzle-orm';
|
|
3
3
|
import 'drizzle-orm/sqlite-core';
|
|
4
4
|
import '@develit-io/backend-sdk';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { F as account, G as accountIdentifier, H as accountIdentifierMapping, L as accountIdentifierMappingRelations, K as accountIdentifierRelations, J as accountRelations, M as entry, N as transaction } from '../shared/ledger.
|
|
1
|
+
export { F as account, G as accountIdentifier, H as accountIdentifierMapping, L as accountIdentifierMappingRelations, K as accountIdentifierRelations, J as accountRelations, M as entry, N as transaction } from '../shared/ledger.N4btQFi1.mjs';
|
|
2
2
|
import 'drizzle-orm';
|
|
3
3
|
import 'drizzle-orm/sqlite-core';
|
|
4
4
|
import '@develit-io/backend-sdk';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { F as account, G as accountIdentifier, H as accountIdentifierMapping, L as accountIdentifierMappingRelations, K as accountIdentifierRelations, J as accountRelations, M as entry, N as transaction } from '../shared/ledger.
|
|
1
|
+
export { F as account, G as accountIdentifier, H as accountIdentifierMapping, L as accountIdentifierMappingRelations, K as accountIdentifierRelations, J as accountRelations, M as entry, N as transaction } from '../shared/ledger.N4btQFi1.js';
|
|
2
2
|
import 'drizzle-orm';
|
|
3
3
|
import 'drizzle-orm/sqlite-core';
|
|
4
4
|
import '@develit-io/backend-sdk';
|
package/dist/database/schema.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { a as account, b as accountIdentifier, c as accountIdentifierMapping, f as accountIdentifierMappingRelations, e as accountIdentifierRelations, d as accountRelations, g as entry, t as transaction } from '../shared/ledger.
|
|
1
|
+
export { a as account, b as accountIdentifier, c as accountIdentifierMapping, f as accountIdentifierMappingRelations, e as accountIdentifierRelations, d as accountRelations, g as entry, t as transaction } from '../shared/ledger.al23fGGy.mjs';
|
|
2
2
|
import '@develit-io/backend-sdk';
|
|
3
3
|
import 'drizzle-orm';
|
|
4
4
|
import 'drizzle-orm/sqlite-core';
|
|
5
|
-
import '../shared/ledger.
|
|
5
|
+
import '../shared/ledger.CYkZYSMS.mjs';
|
|
6
6
|
import '@develit-io/general-codes';
|
|
7
7
|
import 'zod';
|
package/dist/export/worker.cjs
CHANGED
|
@@ -5,9 +5,9 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
const backendSdk = require('@develit-io/backend-sdk');
|
|
6
6
|
const cloudflare_workers = require('cloudflare:workers');
|
|
7
7
|
const d1 = require('drizzle-orm/d1');
|
|
8
|
-
const database_schema = require('../shared/ledger.
|
|
8
|
+
const database_schema = require('../shared/ledger.CcYWtEGS.cjs');
|
|
9
9
|
const drizzleOrm = require('drizzle-orm');
|
|
10
|
-
const updateTransactionConfirmationSentAt = require('../shared/ledger.
|
|
10
|
+
const updateTransactionConfirmationSentAt = require('../shared/ledger.CwcPuqoq.cjs');
|
|
11
11
|
require('@develit-io/general-codes');
|
|
12
12
|
require('drizzle-orm/sqlite-core');
|
|
13
13
|
require('zod');
|
|
@@ -455,9 +455,11 @@ let LedgerServiceBase = class extends backendSdk.develitWorker(
|
|
|
455
455
|
code: "NOT_FOUND"
|
|
456
456
|
});
|
|
457
457
|
}
|
|
458
|
-
const { command } =
|
|
459
|
-
|
|
460
|
-
|
|
458
|
+
const { command } = updateTransactionStatusCommand(this.db, {
|
|
459
|
+
transactionId,
|
|
460
|
+
status: "FAILED",
|
|
461
|
+
completedAt
|
|
462
|
+
});
|
|
461
463
|
const [updatedTransaction] = await this.db.batch([command]);
|
|
462
464
|
if (!updatedTransaction) {
|
|
463
465
|
throw backendSdk.createInternalError(null, {
|
package/dist/export/worker.d.cts
CHANGED
|
@@ -2,9 +2,9 @@ import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
|
|
|
2
2
|
import { IRPCResponse } from '@develit-io/backend-sdk';
|
|
3
3
|
import { WorkerEntrypoint } from 'cloudflare:workers';
|
|
4
4
|
import { DrizzleD1Database } from 'drizzle-orm/d1';
|
|
5
|
-
import { t as tables, C as CreateTransactionInput, a as CreateTransactionOutput, M as MatchTransactionInput, b as MatchTransactionOutput, F as FailTransactionInput, c as FailTransactionOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, i as CreateAccountInput, j as CreateAccountOutput, U as UpdateAccountInput, k as UpdateAccountOutput, D as DeleteAccountInput, l as DeleteAccountOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, L as ListAccountsInput, q as ListAccountsOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput } from '../shared/ledger.
|
|
5
|
+
import { t as tables, C as CreateTransactionInput, a as CreateTransactionOutput, M as MatchTransactionInput, b as MatchTransactionOutput, F as FailTransactionInput, c as FailTransactionOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, i as CreateAccountInput, j as CreateAccountOutput, U as UpdateAccountInput, k as UpdateAccountOutput, D as DeleteAccountInput, l as DeleteAccountOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, L as ListAccountsInput, q as ListAccountsOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput } from '../shared/ledger.BvbOZ0WG.cjs';
|
|
6
6
|
import 'zod';
|
|
7
|
-
import '../shared/ledger.
|
|
7
|
+
import '../shared/ledger.N4btQFi1.cjs';
|
|
8
8
|
import 'drizzle-orm';
|
|
9
9
|
import 'drizzle-orm/sqlite-core';
|
|
10
10
|
import '@develit-io/general-codes';
|
package/dist/export/worker.d.mts
CHANGED
|
@@ -2,9 +2,9 @@ import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
|
|
|
2
2
|
import { IRPCResponse } from '@develit-io/backend-sdk';
|
|
3
3
|
import { WorkerEntrypoint } from 'cloudflare:workers';
|
|
4
4
|
import { DrizzleD1Database } from 'drizzle-orm/d1';
|
|
5
|
-
import { t as tables, C as CreateTransactionInput, a as CreateTransactionOutput, M as MatchTransactionInput, b as MatchTransactionOutput, F as FailTransactionInput, c as FailTransactionOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, i as CreateAccountInput, j as CreateAccountOutput, U as UpdateAccountInput, k as UpdateAccountOutput, D as DeleteAccountInput, l as DeleteAccountOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, L as ListAccountsInput, q as ListAccountsOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput } from '../shared/ledger.
|
|
5
|
+
import { t as tables, C as CreateTransactionInput, a as CreateTransactionOutput, M as MatchTransactionInput, b as MatchTransactionOutput, F as FailTransactionInput, c as FailTransactionOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, i as CreateAccountInput, j as CreateAccountOutput, U as UpdateAccountInput, k as UpdateAccountOutput, D as DeleteAccountInput, l as DeleteAccountOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, L as ListAccountsInput, q as ListAccountsOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput } from '../shared/ledger.DRm7L41a.mjs';
|
|
6
6
|
import 'zod';
|
|
7
|
-
import '../shared/ledger.
|
|
7
|
+
import '../shared/ledger.N4btQFi1.mjs';
|
|
8
8
|
import 'drizzle-orm';
|
|
9
9
|
import 'drizzle-orm/sqlite-core';
|
|
10
10
|
import '@develit-io/general-codes';
|
package/dist/export/worker.d.ts
CHANGED
|
@@ -2,9 +2,9 @@ import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
|
|
|
2
2
|
import { IRPCResponse } from '@develit-io/backend-sdk';
|
|
3
3
|
import { WorkerEntrypoint } from 'cloudflare:workers';
|
|
4
4
|
import { DrizzleD1Database } from 'drizzle-orm/d1';
|
|
5
|
-
import { t as tables, C as CreateTransactionInput, a as CreateTransactionOutput, M as MatchTransactionInput, b as MatchTransactionOutput, F as FailTransactionInput, c as FailTransactionOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, i as CreateAccountInput, j as CreateAccountOutput, U as UpdateAccountInput, k as UpdateAccountOutput, D as DeleteAccountInput, l as DeleteAccountOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, L as ListAccountsInput, q as ListAccountsOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput } from '../shared/ledger.
|
|
5
|
+
import { t as tables, C as CreateTransactionInput, a as CreateTransactionOutput, M as MatchTransactionInput, b as MatchTransactionOutput, F as FailTransactionInput, c as FailTransactionOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, i as CreateAccountInput, j as CreateAccountOutput, U as UpdateAccountInput, k as UpdateAccountOutput, D as DeleteAccountInput, l as DeleteAccountOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, L as ListAccountsInput, q as ListAccountsOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput } from '../shared/ledger.Cd1qa4GB.js';
|
|
6
6
|
import 'zod';
|
|
7
|
-
import '../shared/ledger.
|
|
7
|
+
import '../shared/ledger.N4btQFi1.js';
|
|
8
8
|
import 'drizzle-orm';
|
|
9
9
|
import 'drizzle-orm/sqlite-core';
|
|
10
10
|
import '@develit-io/general-codes';
|
package/dist/export/worker.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { first, develitWorker, uuidv4, useResult, createInternalError, action, service } from '@develit-io/backend-sdk';
|
|
2
2
|
import { WorkerEntrypoint } from 'cloudflare:workers';
|
|
3
3
|
import { drizzle } from 'drizzle-orm/d1';
|
|
4
|
-
import { s as schema } from '../shared/ledger.
|
|
4
|
+
import { s as schema } from '../shared/ledger.al23fGGy.mjs';
|
|
5
5
|
import { eq, and, inArray, or, count, gte, lte, sql, asc, desc } from 'drizzle-orm';
|
|
6
|
-
import {
|
|
6
|
+
import { f as createTransactionInputSchema, s as matchTransactionInputSchema, h as failTransactionInputSchema, n as getTransactionByIdInputSchema, p as getTransactionsByReferenceIdInputSchema, o as getTransactionsInputSchema, e as createAccountInputSchema, u as updateAccountInputSchema, g as deleteAccountInputSchema, j as getAccountInputSchema, m as getAccountsByOwnerInputSchema, r as listAccountsInputSchema, l as getAccountIdentifierInputSchema, q as listAccountIdentifiersInputSchema, i as findAccountByIdentifierInputSchema, k as getAccountBalanceInputSchema, t as updateTransactionConfirmationSentAtInputSchema } from '../shared/ledger.CYkZYSMS.mjs';
|
|
7
7
|
import '@develit-io/general-codes';
|
|
8
8
|
import 'drizzle-orm/sqlite-core';
|
|
9
9
|
import 'zod';
|
|
@@ -451,9 +451,11 @@ let LedgerServiceBase = class extends develitWorker(
|
|
|
451
451
|
code: "NOT_FOUND"
|
|
452
452
|
});
|
|
453
453
|
}
|
|
454
|
-
const { command } =
|
|
455
|
-
|
|
456
|
-
|
|
454
|
+
const { command } = updateTransactionStatusCommand(this.db, {
|
|
455
|
+
transactionId,
|
|
456
|
+
status: "FAILED",
|
|
457
|
+
completedAt
|
|
458
|
+
});
|
|
457
459
|
const [updatedTransaction] = await this.db.batch([command]);
|
|
458
460
|
if (!updatedTransaction) {
|
|
459
461
|
throw createInternalError(null, {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { D as schema } from './ledger.
|
|
2
|
+
import { D as schema } from './ledger.N4btQFi1.cjs';
|
|
3
3
|
import { InferSelectModel, ExtractTablesWithRelations, DBQueryConfig, BuildQueryResult, InferInsertModel } from 'drizzle-orm';
|
|
4
4
|
|
|
5
5
|
interface TSchema extends ExtractTablesWithRelations<typeof tables> {
|
|
@@ -428,6 +428,18 @@ declare const createTransactionInputSchema: z.ZodObject<{
|
|
|
428
428
|
ss: z.ZodOptional<z.ZodString>;
|
|
429
429
|
ks: z.ZodOptional<z.ZodString>;
|
|
430
430
|
message: z.ZodOptional<z.ZodString>;
|
|
431
|
+
type: z.ZodEnum<{
|
|
432
|
+
SWIFT: "SWIFT";
|
|
433
|
+
DOMESTIC: "DOMESTIC";
|
|
434
|
+
SEPA: "SEPA";
|
|
435
|
+
UNKNOWN: "UNKNOWN";
|
|
436
|
+
}>;
|
|
437
|
+
paymentChargeType: z.ZodOptional<z.ZodEnum<{
|
|
438
|
+
SHA: "SHA";
|
|
439
|
+
OUR: "OUR";
|
|
440
|
+
BEN: "BEN";
|
|
441
|
+
}>>;
|
|
442
|
+
expressPayment: z.ZodOptional<z.ZodBoolean>;
|
|
431
443
|
reference: z.ZodOptional<z.ZodString>;
|
|
432
444
|
creditor: z.ZodOptional<z.ZodObject<{
|
|
433
445
|
id: z.ZodOptional<z.ZodString>;
|
|
@@ -1144,20 +1156,76 @@ declare const createTransactionInputSchema: z.ZodObject<{
|
|
|
1144
1156
|
AVAX: "AVAX";
|
|
1145
1157
|
}>>;
|
|
1146
1158
|
amount: z.ZodOptional<z.ZodNumber>;
|
|
1147
|
-
|
|
1159
|
+
purpose: z.ZodOptional<z.ZodString>;
|
|
1148
1160
|
}, z.core.$strip>>;
|
|
1149
|
-
}, z.core.$
|
|
1161
|
+
}, z.core.$strip>>>;
|
|
1150
1162
|
status: z.ZodEnum<{
|
|
1163
|
+
FAILED: "FAILED";
|
|
1164
|
+
COMPLETED: "COMPLETED";
|
|
1151
1165
|
WAITING_FOR_PAYMENT: "WAITING_FOR_PAYMENT";
|
|
1152
1166
|
PAUSED: "PAUSED";
|
|
1153
1167
|
WAITING_FOR_MANUAL_PROCESSING: "WAITING_FOR_MANUAL_PROCESSING";
|
|
1154
1168
|
MATCHED: "MATCHED";
|
|
1155
1169
|
RETURNING: "RETURNING";
|
|
1156
1170
|
RETURNED: "RETURNED";
|
|
1157
|
-
FAILED: "FAILED";
|
|
1158
1171
|
CANCELLED: "CANCELLED";
|
|
1159
|
-
COMPLETED: "COMPLETED";
|
|
1160
1172
|
}>;
|
|
1173
|
+
currency: z.ZodOptional<z.ZodEnum<{
|
|
1174
|
+
CZK: "CZK";
|
|
1175
|
+
EUR: "EUR";
|
|
1176
|
+
USD: "USD";
|
|
1177
|
+
PLN: "PLN";
|
|
1178
|
+
RON: "RON";
|
|
1179
|
+
GBP: "GBP";
|
|
1180
|
+
RUB: "RUB";
|
|
1181
|
+
HUF: "HUF";
|
|
1182
|
+
CHF: "CHF";
|
|
1183
|
+
DKK: "DKK";
|
|
1184
|
+
SEK: "SEK";
|
|
1185
|
+
HRK: "HRK";
|
|
1186
|
+
NOK: "NOK";
|
|
1187
|
+
BGN: "BGN";
|
|
1188
|
+
TRY: "TRY";
|
|
1189
|
+
AUD: "AUD";
|
|
1190
|
+
CAD: "CAD";
|
|
1191
|
+
JPY: "JPY";
|
|
1192
|
+
CNY: "CNY";
|
|
1193
|
+
INR: "INR";
|
|
1194
|
+
BRL: "BRL";
|
|
1195
|
+
MXN: "MXN";
|
|
1196
|
+
ZAR: "ZAR";
|
|
1197
|
+
SGD: "SGD";
|
|
1198
|
+
HKD: "HKD";
|
|
1199
|
+
KRW: "KRW";
|
|
1200
|
+
MYR: "MYR";
|
|
1201
|
+
THB: "THB";
|
|
1202
|
+
IDR: "IDR";
|
|
1203
|
+
PHP: "PHP";
|
|
1204
|
+
AED: "AED";
|
|
1205
|
+
SAR: "SAR";
|
|
1206
|
+
ILS: "ILS";
|
|
1207
|
+
EGP: "EGP";
|
|
1208
|
+
NGN: "NGN";
|
|
1209
|
+
PKR: "PKR";
|
|
1210
|
+
COP: "COP";
|
|
1211
|
+
CLP: "CLP";
|
|
1212
|
+
PEN: "PEN";
|
|
1213
|
+
VND: "VND";
|
|
1214
|
+
KZT: "KZT";
|
|
1215
|
+
UAH: "UAH";
|
|
1216
|
+
BTC: "BTC";
|
|
1217
|
+
ETH: "ETH";
|
|
1218
|
+
ADA: "ADA";
|
|
1219
|
+
DOT: "DOT";
|
|
1220
|
+
ATOM: "ATOM";
|
|
1221
|
+
XRP: "XRP";
|
|
1222
|
+
LTC: "LTC";
|
|
1223
|
+
SOL: "SOL";
|
|
1224
|
+
DOGE: "DOGE";
|
|
1225
|
+
MATIC: "MATIC";
|
|
1226
|
+
AVAX: "AVAX";
|
|
1227
|
+
}>>;
|
|
1228
|
+
amount: z.ZodOptional<z.ZodNumber>;
|
|
1161
1229
|
}, z.core.$strip>;
|
|
1162
1230
|
interface CreateTransactionInput extends z.infer<typeof createTransactionInputSchema> {
|
|
1163
1231
|
}
|
|
@@ -1314,15 +1382,15 @@ declare const getTransactionsInputSchema: z.ZodObject<{
|
|
|
1314
1382
|
filterTransactionDateTo: z.ZodOptional<z.ZodDate>;
|
|
1315
1383
|
filterTransactionCompletedAt: z.ZodOptional<z.ZodDate>;
|
|
1316
1384
|
filterTransactionStatus: z.ZodOptional<z.ZodEnum<{
|
|
1385
|
+
FAILED: "FAILED";
|
|
1386
|
+
COMPLETED: "COMPLETED";
|
|
1317
1387
|
WAITING_FOR_PAYMENT: "WAITING_FOR_PAYMENT";
|
|
1318
1388
|
PAUSED: "PAUSED";
|
|
1319
1389
|
WAITING_FOR_MANUAL_PROCESSING: "WAITING_FOR_MANUAL_PROCESSING";
|
|
1320
1390
|
MATCHED: "MATCHED";
|
|
1321
1391
|
RETURNING: "RETURNING";
|
|
1322
1392
|
RETURNED: "RETURNED";
|
|
1323
|
-
FAILED: "FAILED";
|
|
1324
1393
|
CANCELLED: "CANCELLED";
|
|
1325
|
-
COMPLETED: "COMPLETED";
|
|
1326
1394
|
}>>;
|
|
1327
1395
|
search: z.ZodOptional<z.ZodString>;
|
|
1328
1396
|
}, z.core.$strip>;
|
|
@@ -83,6 +83,7 @@ const TRANSACTION_TYPES = [
|
|
|
83
83
|
];
|
|
84
84
|
const REFERENCE_TYPES = ["PAYMENT", "EXCHANGE", "ORDER"];
|
|
85
85
|
const PAYMENT_CHARGE_TYPES = ["SHA", "OUR", "BEN"];
|
|
86
|
+
const PAYMENT_TYPES = ["DOMESTIC", "SEPA", "SWIFT", "UNKNOWN"];
|
|
86
87
|
|
|
87
88
|
const ALLOWED_TRANSACTION_FILTERS = {
|
|
88
89
|
CORRELATION_ID: "filterTransactionCorrelationId",
|
|
@@ -96,7 +97,6 @@ const ALLOWED_TRANSACTION_FILTERS = {
|
|
|
96
97
|
STATUS: "filterTransactionStatus"
|
|
97
98
|
};
|
|
98
99
|
|
|
99
|
-
const PAYMENT_TYPES = ["SEPA", "SWIFT", "IFSC", "DOMESTIC"];
|
|
100
100
|
const PAYMENT_STATUSES = [
|
|
101
101
|
"PREPARED",
|
|
102
102
|
"INITIALIZED",
|
|
@@ -153,6 +153,10 @@ const transactionMetadataSchema = z.object({
|
|
|
153
153
|
// konstantní symbol
|
|
154
154
|
message: z.string().optional(),
|
|
155
155
|
// zpráva pro příjemce
|
|
156
|
+
type: z.enum(PAYMENT_TYPES),
|
|
157
|
+
// typ platby
|
|
158
|
+
paymentChargeType: z.enum(PAYMENT_CHARGE_TYPES).optional(),
|
|
159
|
+
expressPayment: z.boolean().optional(),
|
|
156
160
|
reference: z.string().optional(),
|
|
157
161
|
// další reference
|
|
158
162
|
creditor: bankAccountMetadataSchema.optional(),
|
|
@@ -163,10 +167,10 @@ const transactionMetadataSchema = z.object({
|
|
|
163
167
|
// ISO 8601
|
|
164
168
|
currency: z.enum(CURRENCY_CODES).optional(),
|
|
165
169
|
amount: z.number().optional(),
|
|
166
|
-
|
|
167
|
-
//
|
|
170
|
+
purpose: z.string().optional()
|
|
171
|
+
// účel platby
|
|
168
172
|
}).optional()
|
|
169
|
-
})
|
|
173
|
+
});
|
|
170
174
|
const createTransactionInputSchema = z.object({
|
|
171
175
|
correlationId: z.string().min(1),
|
|
172
176
|
referenceType: z.enum(REFERENCE_TYPES),
|
|
@@ -175,7 +179,9 @@ const createTransactionInputSchema = z.object({
|
|
|
175
179
|
description: z.string().optional(),
|
|
176
180
|
paymentId: z.string().optional(),
|
|
177
181
|
metadata: transactionMetadataSchema.optional().default({}),
|
|
178
|
-
status: z.enum(TRANSACTION_STATUSES)
|
|
182
|
+
status: z.enum(TRANSACTION_STATUSES),
|
|
183
|
+
currency: z.enum(CURRENCY_CODES).optional(),
|
|
184
|
+
amount: z.number().optional()
|
|
179
185
|
// entries: z.array(entryInputSchema).min(1),
|
|
180
186
|
});
|
|
181
187
|
|
|
@@ -287,4 +293,4 @@ const updateTransactionConfirmationSentAtInputSchema = z.object({
|
|
|
287
293
|
transactionId: z.uuid()
|
|
288
294
|
});
|
|
289
295
|
|
|
290
|
-
export { ACCOUNT_TYPES as A, BALANCE_STRATEGIES as B, COUNTRY_CODES as C, ENTRY_STATUSES as E, IDENTIFIER_KINDS as I, PAYMENT_CHARGE_TYPES as P, REFERENCE_TYPES as R, TRANSACTION_STATUSES as T, ASSET_TYPES as a, TRANSACTION_TYPES as b,
|
|
296
|
+
export { ACCOUNT_TYPES as A, BALANCE_STRATEGIES as B, COUNTRY_CODES as C, ENTRY_STATUSES as E, IDENTIFIER_KINDS as I, PAYMENT_CHARGE_TYPES as P, REFERENCE_TYPES as R, TRANSACTION_STATUSES as T, ASSET_TYPES as a, TRANSACTION_TYPES as b, PAYMENT_TYPES as c, ALLOWED_TRANSACTION_FILTERS as d, createAccountInputSchema as e, createTransactionInputSchema as f, deleteAccountInputSchema as g, failTransactionInputSchema as h, findAccountByIdentifierInputSchema as i, getAccountInputSchema as j, getAccountBalanceInputSchema as k, getAccountIdentifierInputSchema as l, getAccountsByOwnerInputSchema as m, getTransactionByIdInputSchema as n, getTransactionsInputSchema as o, getTransactionsByReferenceIdInputSchema as p, listAccountIdentifiersInputSchema as q, listAccountsInputSchema as r, matchTransactionInputSchema as s, updateTransactionConfirmationSentAtInputSchema as t, updateAccountInputSchema as u, PAYMENT_STATUSES as v, PAYMENT_DIRECTIONS as w, BATCH_STATUSES as x };
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
const backendSdk = require('@develit-io/backend-sdk');
|
|
4
4
|
const drizzleOrm = require('drizzle-orm');
|
|
5
5
|
const sqliteCore = require('drizzle-orm/sqlite-core');
|
|
6
|
-
const updateTransactionConfirmationSentAt = require('./ledger.
|
|
6
|
+
const updateTransactionConfirmationSentAt = require('./ledger.CwcPuqoq.cjs');
|
|
7
7
|
require('@develit-io/general-codes');
|
|
8
8
|
|
|
9
9
|
const account = sqliteCore.sqliteTable("account", {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { D as schema } from './ledger.
|
|
2
|
+
import { D as schema } from './ledger.N4btQFi1.js';
|
|
3
3
|
import { InferSelectModel, ExtractTablesWithRelations, DBQueryConfig, BuildQueryResult, InferInsertModel } from 'drizzle-orm';
|
|
4
4
|
|
|
5
5
|
interface TSchema extends ExtractTablesWithRelations<typeof tables> {
|
|
@@ -428,6 +428,18 @@ declare const createTransactionInputSchema: z.ZodObject<{
|
|
|
428
428
|
ss: z.ZodOptional<z.ZodString>;
|
|
429
429
|
ks: z.ZodOptional<z.ZodString>;
|
|
430
430
|
message: z.ZodOptional<z.ZodString>;
|
|
431
|
+
type: z.ZodEnum<{
|
|
432
|
+
SWIFT: "SWIFT";
|
|
433
|
+
DOMESTIC: "DOMESTIC";
|
|
434
|
+
SEPA: "SEPA";
|
|
435
|
+
UNKNOWN: "UNKNOWN";
|
|
436
|
+
}>;
|
|
437
|
+
paymentChargeType: z.ZodOptional<z.ZodEnum<{
|
|
438
|
+
SHA: "SHA";
|
|
439
|
+
OUR: "OUR";
|
|
440
|
+
BEN: "BEN";
|
|
441
|
+
}>>;
|
|
442
|
+
expressPayment: z.ZodOptional<z.ZodBoolean>;
|
|
431
443
|
reference: z.ZodOptional<z.ZodString>;
|
|
432
444
|
creditor: z.ZodOptional<z.ZodObject<{
|
|
433
445
|
id: z.ZodOptional<z.ZodString>;
|
|
@@ -1144,20 +1156,76 @@ declare const createTransactionInputSchema: z.ZodObject<{
|
|
|
1144
1156
|
AVAX: "AVAX";
|
|
1145
1157
|
}>>;
|
|
1146
1158
|
amount: z.ZodOptional<z.ZodNumber>;
|
|
1147
|
-
|
|
1159
|
+
purpose: z.ZodOptional<z.ZodString>;
|
|
1148
1160
|
}, z.core.$strip>>;
|
|
1149
|
-
}, z.core.$
|
|
1161
|
+
}, z.core.$strip>>>;
|
|
1150
1162
|
status: z.ZodEnum<{
|
|
1163
|
+
FAILED: "FAILED";
|
|
1164
|
+
COMPLETED: "COMPLETED";
|
|
1151
1165
|
WAITING_FOR_PAYMENT: "WAITING_FOR_PAYMENT";
|
|
1152
1166
|
PAUSED: "PAUSED";
|
|
1153
1167
|
WAITING_FOR_MANUAL_PROCESSING: "WAITING_FOR_MANUAL_PROCESSING";
|
|
1154
1168
|
MATCHED: "MATCHED";
|
|
1155
1169
|
RETURNING: "RETURNING";
|
|
1156
1170
|
RETURNED: "RETURNED";
|
|
1157
|
-
FAILED: "FAILED";
|
|
1158
1171
|
CANCELLED: "CANCELLED";
|
|
1159
|
-
COMPLETED: "COMPLETED";
|
|
1160
1172
|
}>;
|
|
1173
|
+
currency: z.ZodOptional<z.ZodEnum<{
|
|
1174
|
+
CZK: "CZK";
|
|
1175
|
+
EUR: "EUR";
|
|
1176
|
+
USD: "USD";
|
|
1177
|
+
PLN: "PLN";
|
|
1178
|
+
RON: "RON";
|
|
1179
|
+
GBP: "GBP";
|
|
1180
|
+
RUB: "RUB";
|
|
1181
|
+
HUF: "HUF";
|
|
1182
|
+
CHF: "CHF";
|
|
1183
|
+
DKK: "DKK";
|
|
1184
|
+
SEK: "SEK";
|
|
1185
|
+
HRK: "HRK";
|
|
1186
|
+
NOK: "NOK";
|
|
1187
|
+
BGN: "BGN";
|
|
1188
|
+
TRY: "TRY";
|
|
1189
|
+
AUD: "AUD";
|
|
1190
|
+
CAD: "CAD";
|
|
1191
|
+
JPY: "JPY";
|
|
1192
|
+
CNY: "CNY";
|
|
1193
|
+
INR: "INR";
|
|
1194
|
+
BRL: "BRL";
|
|
1195
|
+
MXN: "MXN";
|
|
1196
|
+
ZAR: "ZAR";
|
|
1197
|
+
SGD: "SGD";
|
|
1198
|
+
HKD: "HKD";
|
|
1199
|
+
KRW: "KRW";
|
|
1200
|
+
MYR: "MYR";
|
|
1201
|
+
THB: "THB";
|
|
1202
|
+
IDR: "IDR";
|
|
1203
|
+
PHP: "PHP";
|
|
1204
|
+
AED: "AED";
|
|
1205
|
+
SAR: "SAR";
|
|
1206
|
+
ILS: "ILS";
|
|
1207
|
+
EGP: "EGP";
|
|
1208
|
+
NGN: "NGN";
|
|
1209
|
+
PKR: "PKR";
|
|
1210
|
+
COP: "COP";
|
|
1211
|
+
CLP: "CLP";
|
|
1212
|
+
PEN: "PEN";
|
|
1213
|
+
VND: "VND";
|
|
1214
|
+
KZT: "KZT";
|
|
1215
|
+
UAH: "UAH";
|
|
1216
|
+
BTC: "BTC";
|
|
1217
|
+
ETH: "ETH";
|
|
1218
|
+
ADA: "ADA";
|
|
1219
|
+
DOT: "DOT";
|
|
1220
|
+
ATOM: "ATOM";
|
|
1221
|
+
XRP: "XRP";
|
|
1222
|
+
LTC: "LTC";
|
|
1223
|
+
SOL: "SOL";
|
|
1224
|
+
DOGE: "DOGE";
|
|
1225
|
+
MATIC: "MATIC";
|
|
1226
|
+
AVAX: "AVAX";
|
|
1227
|
+
}>>;
|
|
1228
|
+
amount: z.ZodOptional<z.ZodNumber>;
|
|
1161
1229
|
}, z.core.$strip>;
|
|
1162
1230
|
interface CreateTransactionInput extends z.infer<typeof createTransactionInputSchema> {
|
|
1163
1231
|
}
|
|
@@ -1314,15 +1382,15 @@ declare const getTransactionsInputSchema: z.ZodObject<{
|
|
|
1314
1382
|
filterTransactionDateTo: z.ZodOptional<z.ZodDate>;
|
|
1315
1383
|
filterTransactionCompletedAt: z.ZodOptional<z.ZodDate>;
|
|
1316
1384
|
filterTransactionStatus: z.ZodOptional<z.ZodEnum<{
|
|
1385
|
+
FAILED: "FAILED";
|
|
1386
|
+
COMPLETED: "COMPLETED";
|
|
1317
1387
|
WAITING_FOR_PAYMENT: "WAITING_FOR_PAYMENT";
|
|
1318
1388
|
PAUSED: "PAUSED";
|
|
1319
1389
|
WAITING_FOR_MANUAL_PROCESSING: "WAITING_FOR_MANUAL_PROCESSING";
|
|
1320
1390
|
MATCHED: "MATCHED";
|
|
1321
1391
|
RETURNING: "RETURNING";
|
|
1322
1392
|
RETURNED: "RETURNED";
|
|
1323
|
-
FAILED: "FAILED";
|
|
1324
1393
|
CANCELLED: "CANCELLED";
|
|
1325
|
-
COMPLETED: "COMPLETED";
|
|
1326
1394
|
}>>;
|
|
1327
1395
|
search: z.ZodOptional<z.ZodString>;
|
|
1328
1396
|
}, z.core.$strip>;
|
|
@@ -85,6 +85,7 @@ const TRANSACTION_TYPES = [
|
|
|
85
85
|
];
|
|
86
86
|
const REFERENCE_TYPES = ["PAYMENT", "EXCHANGE", "ORDER"];
|
|
87
87
|
const PAYMENT_CHARGE_TYPES = ["SHA", "OUR", "BEN"];
|
|
88
|
+
const PAYMENT_TYPES = ["DOMESTIC", "SEPA", "SWIFT", "UNKNOWN"];
|
|
88
89
|
|
|
89
90
|
const ALLOWED_TRANSACTION_FILTERS = {
|
|
90
91
|
CORRELATION_ID: "filterTransactionCorrelationId",
|
|
@@ -98,7 +99,6 @@ const ALLOWED_TRANSACTION_FILTERS = {
|
|
|
98
99
|
STATUS: "filterTransactionStatus"
|
|
99
100
|
};
|
|
100
101
|
|
|
101
|
-
const PAYMENT_TYPES = ["SEPA", "SWIFT", "IFSC", "DOMESTIC"];
|
|
102
102
|
const PAYMENT_STATUSES = [
|
|
103
103
|
"PREPARED",
|
|
104
104
|
"INITIALIZED",
|
|
@@ -155,6 +155,10 @@ const transactionMetadataSchema = zod.z.object({
|
|
|
155
155
|
// konstantní symbol
|
|
156
156
|
message: zod.z.string().optional(),
|
|
157
157
|
// zpráva pro příjemce
|
|
158
|
+
type: zod.z.enum(PAYMENT_TYPES),
|
|
159
|
+
// typ platby
|
|
160
|
+
paymentChargeType: zod.z.enum(PAYMENT_CHARGE_TYPES).optional(),
|
|
161
|
+
expressPayment: zod.z.boolean().optional(),
|
|
158
162
|
reference: zod.z.string().optional(),
|
|
159
163
|
// další reference
|
|
160
164
|
creditor: backendSdk.bankAccountMetadataSchema.optional(),
|
|
@@ -165,10 +169,10 @@ const transactionMetadataSchema = zod.z.object({
|
|
|
165
169
|
// ISO 8601
|
|
166
170
|
currency: zod.z.enum(generalCodes.CURRENCY_CODES).optional(),
|
|
167
171
|
amount: zod.z.number().optional(),
|
|
168
|
-
|
|
169
|
-
//
|
|
172
|
+
purpose: zod.z.string().optional()
|
|
173
|
+
// účel platby
|
|
170
174
|
}).optional()
|
|
171
|
-
})
|
|
175
|
+
});
|
|
172
176
|
const createTransactionInputSchema = zod.z.object({
|
|
173
177
|
correlationId: zod.z.string().min(1),
|
|
174
178
|
referenceType: zod.z.enum(REFERENCE_TYPES),
|
|
@@ -177,7 +181,9 @@ const createTransactionInputSchema = zod.z.object({
|
|
|
177
181
|
description: zod.z.string().optional(),
|
|
178
182
|
paymentId: zod.z.string().optional(),
|
|
179
183
|
metadata: transactionMetadataSchema.optional().default({}),
|
|
180
|
-
status: zod.z.enum(TRANSACTION_STATUSES)
|
|
184
|
+
status: zod.z.enum(TRANSACTION_STATUSES),
|
|
185
|
+
currency: zod.z.enum(generalCodes.CURRENCY_CODES).optional(),
|
|
186
|
+
amount: zod.z.number().optional()
|
|
181
187
|
// entries: z.array(entryInputSchema).min(1),
|
|
182
188
|
});
|
|
183
189
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { D as schema } from './ledger.
|
|
2
|
+
import { D as schema } from './ledger.N4btQFi1.mjs';
|
|
3
3
|
import { InferSelectModel, ExtractTablesWithRelations, DBQueryConfig, BuildQueryResult, InferInsertModel } from 'drizzle-orm';
|
|
4
4
|
|
|
5
5
|
interface TSchema extends ExtractTablesWithRelations<typeof tables> {
|
|
@@ -428,6 +428,18 @@ declare const createTransactionInputSchema: z.ZodObject<{
|
|
|
428
428
|
ss: z.ZodOptional<z.ZodString>;
|
|
429
429
|
ks: z.ZodOptional<z.ZodString>;
|
|
430
430
|
message: z.ZodOptional<z.ZodString>;
|
|
431
|
+
type: z.ZodEnum<{
|
|
432
|
+
SWIFT: "SWIFT";
|
|
433
|
+
DOMESTIC: "DOMESTIC";
|
|
434
|
+
SEPA: "SEPA";
|
|
435
|
+
UNKNOWN: "UNKNOWN";
|
|
436
|
+
}>;
|
|
437
|
+
paymentChargeType: z.ZodOptional<z.ZodEnum<{
|
|
438
|
+
SHA: "SHA";
|
|
439
|
+
OUR: "OUR";
|
|
440
|
+
BEN: "BEN";
|
|
441
|
+
}>>;
|
|
442
|
+
expressPayment: z.ZodOptional<z.ZodBoolean>;
|
|
431
443
|
reference: z.ZodOptional<z.ZodString>;
|
|
432
444
|
creditor: z.ZodOptional<z.ZodObject<{
|
|
433
445
|
id: z.ZodOptional<z.ZodString>;
|
|
@@ -1144,20 +1156,76 @@ declare const createTransactionInputSchema: z.ZodObject<{
|
|
|
1144
1156
|
AVAX: "AVAX";
|
|
1145
1157
|
}>>;
|
|
1146
1158
|
amount: z.ZodOptional<z.ZodNumber>;
|
|
1147
|
-
|
|
1159
|
+
purpose: z.ZodOptional<z.ZodString>;
|
|
1148
1160
|
}, z.core.$strip>>;
|
|
1149
|
-
}, z.core.$
|
|
1161
|
+
}, z.core.$strip>>>;
|
|
1150
1162
|
status: z.ZodEnum<{
|
|
1163
|
+
FAILED: "FAILED";
|
|
1164
|
+
COMPLETED: "COMPLETED";
|
|
1151
1165
|
WAITING_FOR_PAYMENT: "WAITING_FOR_PAYMENT";
|
|
1152
1166
|
PAUSED: "PAUSED";
|
|
1153
1167
|
WAITING_FOR_MANUAL_PROCESSING: "WAITING_FOR_MANUAL_PROCESSING";
|
|
1154
1168
|
MATCHED: "MATCHED";
|
|
1155
1169
|
RETURNING: "RETURNING";
|
|
1156
1170
|
RETURNED: "RETURNED";
|
|
1157
|
-
FAILED: "FAILED";
|
|
1158
1171
|
CANCELLED: "CANCELLED";
|
|
1159
|
-
COMPLETED: "COMPLETED";
|
|
1160
1172
|
}>;
|
|
1173
|
+
currency: z.ZodOptional<z.ZodEnum<{
|
|
1174
|
+
CZK: "CZK";
|
|
1175
|
+
EUR: "EUR";
|
|
1176
|
+
USD: "USD";
|
|
1177
|
+
PLN: "PLN";
|
|
1178
|
+
RON: "RON";
|
|
1179
|
+
GBP: "GBP";
|
|
1180
|
+
RUB: "RUB";
|
|
1181
|
+
HUF: "HUF";
|
|
1182
|
+
CHF: "CHF";
|
|
1183
|
+
DKK: "DKK";
|
|
1184
|
+
SEK: "SEK";
|
|
1185
|
+
HRK: "HRK";
|
|
1186
|
+
NOK: "NOK";
|
|
1187
|
+
BGN: "BGN";
|
|
1188
|
+
TRY: "TRY";
|
|
1189
|
+
AUD: "AUD";
|
|
1190
|
+
CAD: "CAD";
|
|
1191
|
+
JPY: "JPY";
|
|
1192
|
+
CNY: "CNY";
|
|
1193
|
+
INR: "INR";
|
|
1194
|
+
BRL: "BRL";
|
|
1195
|
+
MXN: "MXN";
|
|
1196
|
+
ZAR: "ZAR";
|
|
1197
|
+
SGD: "SGD";
|
|
1198
|
+
HKD: "HKD";
|
|
1199
|
+
KRW: "KRW";
|
|
1200
|
+
MYR: "MYR";
|
|
1201
|
+
THB: "THB";
|
|
1202
|
+
IDR: "IDR";
|
|
1203
|
+
PHP: "PHP";
|
|
1204
|
+
AED: "AED";
|
|
1205
|
+
SAR: "SAR";
|
|
1206
|
+
ILS: "ILS";
|
|
1207
|
+
EGP: "EGP";
|
|
1208
|
+
NGN: "NGN";
|
|
1209
|
+
PKR: "PKR";
|
|
1210
|
+
COP: "COP";
|
|
1211
|
+
CLP: "CLP";
|
|
1212
|
+
PEN: "PEN";
|
|
1213
|
+
VND: "VND";
|
|
1214
|
+
KZT: "KZT";
|
|
1215
|
+
UAH: "UAH";
|
|
1216
|
+
BTC: "BTC";
|
|
1217
|
+
ETH: "ETH";
|
|
1218
|
+
ADA: "ADA";
|
|
1219
|
+
DOT: "DOT";
|
|
1220
|
+
ATOM: "ATOM";
|
|
1221
|
+
XRP: "XRP";
|
|
1222
|
+
LTC: "LTC";
|
|
1223
|
+
SOL: "SOL";
|
|
1224
|
+
DOGE: "DOGE";
|
|
1225
|
+
MATIC: "MATIC";
|
|
1226
|
+
AVAX: "AVAX";
|
|
1227
|
+
}>>;
|
|
1228
|
+
amount: z.ZodOptional<z.ZodNumber>;
|
|
1161
1229
|
}, z.core.$strip>;
|
|
1162
1230
|
interface CreateTransactionInput extends z.infer<typeof createTransactionInputSchema> {
|
|
1163
1231
|
}
|
|
@@ -1314,15 +1382,15 @@ declare const getTransactionsInputSchema: z.ZodObject<{
|
|
|
1314
1382
|
filterTransactionDateTo: z.ZodOptional<z.ZodDate>;
|
|
1315
1383
|
filterTransactionCompletedAt: z.ZodOptional<z.ZodDate>;
|
|
1316
1384
|
filterTransactionStatus: z.ZodOptional<z.ZodEnum<{
|
|
1385
|
+
FAILED: "FAILED";
|
|
1386
|
+
COMPLETED: "COMPLETED";
|
|
1317
1387
|
WAITING_FOR_PAYMENT: "WAITING_FOR_PAYMENT";
|
|
1318
1388
|
PAUSED: "PAUSED";
|
|
1319
1389
|
WAITING_FOR_MANUAL_PROCESSING: "WAITING_FOR_MANUAL_PROCESSING";
|
|
1320
1390
|
MATCHED: "MATCHED";
|
|
1321
1391
|
RETURNING: "RETURNING";
|
|
1322
1392
|
RETURNED: "RETURNED";
|
|
1323
|
-
FAILED: "FAILED";
|
|
1324
1393
|
CANCELLED: "CANCELLED";
|
|
1325
|
-
COMPLETED: "COMPLETED";
|
|
1326
1394
|
}>>;
|
|
1327
1395
|
search: z.ZodOptional<z.ZodString>;
|
|
1328
1396
|
}, z.core.$strip>;
|
|
@@ -598,8 +598,7 @@ declare const REFERENCE_TYPES: readonly ["PAYMENT", "EXCHANGE", "ORDER"];
|
|
|
598
598
|
type ReferenceType = (typeof REFERENCE_TYPES)[number];
|
|
599
599
|
declare const PAYMENT_CHARGE_TYPES: readonly ["SHA", "OUR", "BEN"];
|
|
600
600
|
type PaymentChargeType = (typeof PAYMENT_CHARGE_TYPES)[number];
|
|
601
|
-
|
|
602
|
-
declare const PAYMENT_TYPES: readonly ["SEPA", "SWIFT", "IFSC", "DOMESTIC"];
|
|
601
|
+
declare const PAYMENT_TYPES: readonly ["DOMESTIC", "SEPA", "SWIFT", "UNKNOWN"];
|
|
603
602
|
type PaymentType = (typeof PAYMENT_TYPES)[number];
|
|
604
603
|
|
|
605
604
|
type CryptoNetworkCode = (typeof CRYPTO_NETWORK_CODES)[number];
|
|
@@ -632,7 +631,7 @@ interface TransactionMetadata {
|
|
|
632
631
|
ss?: string;
|
|
633
632
|
ks?: string;
|
|
634
633
|
message?: string;
|
|
635
|
-
type:
|
|
634
|
+
type: PaymentType;
|
|
636
635
|
paymentChargeType?: PaymentChargeType;
|
|
637
636
|
expressPayment?: boolean;
|
|
638
637
|
reference?: string;
|
|
@@ -1114,7 +1113,7 @@ declare const transaction: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
|
|
|
1114
1113
|
tableName: "transaction";
|
|
1115
1114
|
dataType: "string";
|
|
1116
1115
|
columnType: "SQLiteText";
|
|
1117
|
-
data: "
|
|
1116
|
+
data: "FAILED" | "COMPLETED" | "WAITING_FOR_PAYMENT" | "PAUSED" | "WAITING_FOR_MANUAL_PROCESSING" | "MATCHED" | "RETURNING" | "RETURNED" | "CANCELLED";
|
|
1118
1117
|
driverParam: string;
|
|
1119
1118
|
notNull: true;
|
|
1120
1119
|
hasDefault: false;
|
|
@@ -1127,7 +1126,7 @@ declare const transaction: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
|
|
|
1127
1126
|
generated: undefined;
|
|
1128
1127
|
}, {}, {
|
|
1129
1128
|
length: number | undefined;
|
|
1130
|
-
$type: "
|
|
1129
|
+
$type: "FAILED" | "COMPLETED" | "WAITING_FOR_PAYMENT" | "PAUSED" | "WAITING_FOR_MANUAL_PROCESSING" | "MATCHED" | "RETURNING" | "RETURNED" | "CANCELLED";
|
|
1131
1130
|
}>;
|
|
1132
1131
|
statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
|
|
1133
1132
|
name: "status_reason";
|
|
@@ -1318,5 +1317,5 @@ declare namespace schema {
|
|
|
1318
1317
|
};
|
|
1319
1318
|
}
|
|
1320
1319
|
|
|
1321
|
-
export { ACCOUNT_TYPES as A, BALANCE_STRATEGIES as B, schema as D, ENTRY_STATUSES as E, account as F, accountIdentifier as G, accountIdentifierMapping as H, IDENTIFIER_KINDS as I, accountRelations as J, accountIdentifierRelations as K, accountIdentifierMappingRelations as L, entry as M, transaction as N, PAYMENT_CHARGE_TYPES as P, REFERENCE_TYPES as R, TRANSACTION_STATUSES as T, ASSET_TYPES as b, TRANSACTION_TYPES as h, PAYMENT_TYPES as
|
|
1322
|
-
export type { CryptoNetworkCode as C, AccountType as a, AssetType as c, BalanceStrategy as d, IdentifierKind as e, EntryStatus as f, TransactionStatus as g, TransactionType as i, ReferenceType as j, PaymentChargeType as k,
|
|
1320
|
+
export { ACCOUNT_TYPES as A, BALANCE_STRATEGIES as B, schema as D, ENTRY_STATUSES as E, account as F, accountIdentifier as G, accountIdentifierMapping as H, IDENTIFIER_KINDS as I, accountRelations as J, accountIdentifierRelations as K, accountIdentifierMappingRelations as L, entry as M, transaction as N, PAYMENT_CHARGE_TYPES as P, REFERENCE_TYPES as R, TRANSACTION_STATUSES as T, ASSET_TYPES as b, TRANSACTION_TYPES as h, PAYMENT_TYPES as l, PAYMENT_STATUSES as p, PAYMENT_DIRECTIONS as r, BATCH_STATUSES as u, COUNTRY_CODES as y };
|
|
1321
|
+
export type { CryptoNetworkCode as C, AccountType as a, AssetType as c, BalanceStrategy as d, IdentifierKind as e, EntryStatus as f, TransactionStatus as g, TransactionType as i, ReferenceType as j, PaymentChargeType as k, PaymentType as m, TransactionMetadata as n, EntryMetadata as o, PaymentStatus as q, PaymentDirection as s, CurrencyCode as t, BatchStatus as v, Currency as w, BankCode as x, CountryCode as z };
|
|
@@ -598,8 +598,7 @@ declare const REFERENCE_TYPES: readonly ["PAYMENT", "EXCHANGE", "ORDER"];
|
|
|
598
598
|
type ReferenceType = (typeof REFERENCE_TYPES)[number];
|
|
599
599
|
declare const PAYMENT_CHARGE_TYPES: readonly ["SHA", "OUR", "BEN"];
|
|
600
600
|
type PaymentChargeType = (typeof PAYMENT_CHARGE_TYPES)[number];
|
|
601
|
-
|
|
602
|
-
declare const PAYMENT_TYPES: readonly ["SEPA", "SWIFT", "IFSC", "DOMESTIC"];
|
|
601
|
+
declare const PAYMENT_TYPES: readonly ["DOMESTIC", "SEPA", "SWIFT", "UNKNOWN"];
|
|
603
602
|
type PaymentType = (typeof PAYMENT_TYPES)[number];
|
|
604
603
|
|
|
605
604
|
type CryptoNetworkCode = (typeof CRYPTO_NETWORK_CODES)[number];
|
|
@@ -632,7 +631,7 @@ interface TransactionMetadata {
|
|
|
632
631
|
ss?: string;
|
|
633
632
|
ks?: string;
|
|
634
633
|
message?: string;
|
|
635
|
-
type:
|
|
634
|
+
type: PaymentType;
|
|
636
635
|
paymentChargeType?: PaymentChargeType;
|
|
637
636
|
expressPayment?: boolean;
|
|
638
637
|
reference?: string;
|
|
@@ -1114,7 +1113,7 @@ declare const transaction: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
|
|
|
1114
1113
|
tableName: "transaction";
|
|
1115
1114
|
dataType: "string";
|
|
1116
1115
|
columnType: "SQLiteText";
|
|
1117
|
-
data: "
|
|
1116
|
+
data: "FAILED" | "COMPLETED" | "WAITING_FOR_PAYMENT" | "PAUSED" | "WAITING_FOR_MANUAL_PROCESSING" | "MATCHED" | "RETURNING" | "RETURNED" | "CANCELLED";
|
|
1118
1117
|
driverParam: string;
|
|
1119
1118
|
notNull: true;
|
|
1120
1119
|
hasDefault: false;
|
|
@@ -1127,7 +1126,7 @@ declare const transaction: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
|
|
|
1127
1126
|
generated: undefined;
|
|
1128
1127
|
}, {}, {
|
|
1129
1128
|
length: number | undefined;
|
|
1130
|
-
$type: "
|
|
1129
|
+
$type: "FAILED" | "COMPLETED" | "WAITING_FOR_PAYMENT" | "PAUSED" | "WAITING_FOR_MANUAL_PROCESSING" | "MATCHED" | "RETURNING" | "RETURNED" | "CANCELLED";
|
|
1131
1130
|
}>;
|
|
1132
1131
|
statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
|
|
1133
1132
|
name: "status_reason";
|
|
@@ -1318,5 +1317,5 @@ declare namespace schema {
|
|
|
1318
1317
|
};
|
|
1319
1318
|
}
|
|
1320
1319
|
|
|
1321
|
-
export { ACCOUNT_TYPES as A, BALANCE_STRATEGIES as B, schema as D, ENTRY_STATUSES as E, account as F, accountIdentifier as G, accountIdentifierMapping as H, IDENTIFIER_KINDS as I, accountRelations as J, accountIdentifierRelations as K, accountIdentifierMappingRelations as L, entry as M, transaction as N, PAYMENT_CHARGE_TYPES as P, REFERENCE_TYPES as R, TRANSACTION_STATUSES as T, ASSET_TYPES as b, TRANSACTION_TYPES as h, PAYMENT_TYPES as
|
|
1322
|
-
export type { CryptoNetworkCode as C, AccountType as a, AssetType as c, BalanceStrategy as d, IdentifierKind as e, EntryStatus as f, TransactionStatus as g, TransactionType as i, ReferenceType as j, PaymentChargeType as k,
|
|
1320
|
+
export { ACCOUNT_TYPES as A, BALANCE_STRATEGIES as B, schema as D, ENTRY_STATUSES as E, account as F, accountIdentifier as G, accountIdentifierMapping as H, IDENTIFIER_KINDS as I, accountRelations as J, accountIdentifierRelations as K, accountIdentifierMappingRelations as L, entry as M, transaction as N, PAYMENT_CHARGE_TYPES as P, REFERENCE_TYPES as R, TRANSACTION_STATUSES as T, ASSET_TYPES as b, TRANSACTION_TYPES as h, PAYMENT_TYPES as l, PAYMENT_STATUSES as p, PAYMENT_DIRECTIONS as r, BATCH_STATUSES as u, COUNTRY_CODES as y };
|
|
1321
|
+
export type { CryptoNetworkCode as C, AccountType as a, AssetType as c, BalanceStrategy as d, IdentifierKind as e, EntryStatus as f, TransactionStatus as g, TransactionType as i, ReferenceType as j, PaymentChargeType as k, PaymentType as m, TransactionMetadata as n, EntryMetadata as o, PaymentStatus as q, PaymentDirection as s, CurrencyCode as t, BatchStatus as v, Currency as w, BankCode as x, CountryCode as z };
|
|
@@ -598,8 +598,7 @@ declare const REFERENCE_TYPES: readonly ["PAYMENT", "EXCHANGE", "ORDER"];
|
|
|
598
598
|
type ReferenceType = (typeof REFERENCE_TYPES)[number];
|
|
599
599
|
declare const PAYMENT_CHARGE_TYPES: readonly ["SHA", "OUR", "BEN"];
|
|
600
600
|
type PaymentChargeType = (typeof PAYMENT_CHARGE_TYPES)[number];
|
|
601
|
-
|
|
602
|
-
declare const PAYMENT_TYPES: readonly ["SEPA", "SWIFT", "IFSC", "DOMESTIC"];
|
|
601
|
+
declare const PAYMENT_TYPES: readonly ["DOMESTIC", "SEPA", "SWIFT", "UNKNOWN"];
|
|
603
602
|
type PaymentType = (typeof PAYMENT_TYPES)[number];
|
|
604
603
|
|
|
605
604
|
type CryptoNetworkCode = (typeof CRYPTO_NETWORK_CODES)[number];
|
|
@@ -632,7 +631,7 @@ interface TransactionMetadata {
|
|
|
632
631
|
ss?: string;
|
|
633
632
|
ks?: string;
|
|
634
633
|
message?: string;
|
|
635
|
-
type:
|
|
634
|
+
type: PaymentType;
|
|
636
635
|
paymentChargeType?: PaymentChargeType;
|
|
637
636
|
expressPayment?: boolean;
|
|
638
637
|
reference?: string;
|
|
@@ -1114,7 +1113,7 @@ declare const transaction: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
|
|
|
1114
1113
|
tableName: "transaction";
|
|
1115
1114
|
dataType: "string";
|
|
1116
1115
|
columnType: "SQLiteText";
|
|
1117
|
-
data: "
|
|
1116
|
+
data: "FAILED" | "COMPLETED" | "WAITING_FOR_PAYMENT" | "PAUSED" | "WAITING_FOR_MANUAL_PROCESSING" | "MATCHED" | "RETURNING" | "RETURNED" | "CANCELLED";
|
|
1118
1117
|
driverParam: string;
|
|
1119
1118
|
notNull: true;
|
|
1120
1119
|
hasDefault: false;
|
|
@@ -1127,7 +1126,7 @@ declare const transaction: drizzle_orm_sqlite_core.SQLiteTableWithColumns<{
|
|
|
1127
1126
|
generated: undefined;
|
|
1128
1127
|
}, {}, {
|
|
1129
1128
|
length: number | undefined;
|
|
1130
|
-
$type: "
|
|
1129
|
+
$type: "FAILED" | "COMPLETED" | "WAITING_FOR_PAYMENT" | "PAUSED" | "WAITING_FOR_MANUAL_PROCESSING" | "MATCHED" | "RETURNING" | "RETURNED" | "CANCELLED";
|
|
1131
1130
|
}>;
|
|
1132
1131
|
statusReason: drizzle_orm_sqlite_core.SQLiteColumn<{
|
|
1133
1132
|
name: "status_reason";
|
|
@@ -1318,5 +1317,5 @@ declare namespace schema {
|
|
|
1318
1317
|
};
|
|
1319
1318
|
}
|
|
1320
1319
|
|
|
1321
|
-
export { ACCOUNT_TYPES as A, BALANCE_STRATEGIES as B, schema as D, ENTRY_STATUSES as E, account as F, accountIdentifier as G, accountIdentifierMapping as H, IDENTIFIER_KINDS as I, accountRelations as J, accountIdentifierRelations as K, accountIdentifierMappingRelations as L, entry as M, transaction as N, PAYMENT_CHARGE_TYPES as P, REFERENCE_TYPES as R, TRANSACTION_STATUSES as T, ASSET_TYPES as b, TRANSACTION_TYPES as h, PAYMENT_TYPES as
|
|
1322
|
-
export type { CryptoNetworkCode as C, AccountType as a, AssetType as c, BalanceStrategy as d, IdentifierKind as e, EntryStatus as f, TransactionStatus as g, TransactionType as i, ReferenceType as j, PaymentChargeType as k,
|
|
1320
|
+
export { ACCOUNT_TYPES as A, BALANCE_STRATEGIES as B, schema as D, ENTRY_STATUSES as E, account as F, accountIdentifier as G, accountIdentifierMapping as H, IDENTIFIER_KINDS as I, accountRelations as J, accountIdentifierRelations as K, accountIdentifierMappingRelations as L, entry as M, transaction as N, PAYMENT_CHARGE_TYPES as P, REFERENCE_TYPES as R, TRANSACTION_STATUSES as T, ASSET_TYPES as b, TRANSACTION_TYPES as h, PAYMENT_TYPES as l, PAYMENT_STATUSES as p, PAYMENT_DIRECTIONS as r, BATCH_STATUSES as u, COUNTRY_CODES as y };
|
|
1321
|
+
export type { CryptoNetworkCode as C, AccountType as a, AssetType as c, BalanceStrategy as d, IdentifierKind as e, EntryStatus as f, TransactionStatus as g, TransactionType as i, ReferenceType as j, PaymentChargeType as k, PaymentType as m, TransactionMetadata as n, EntryMetadata as o, PaymentStatus as q, PaymentDirection as s, CurrencyCode as t, BatchStatus as v, Currency as w, BankCode as x, CountryCode as z };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { base } from '@develit-io/backend-sdk';
|
|
2
2
|
import { relations } from 'drizzle-orm';
|
|
3
3
|
import { sqliteTable, integer, text, real } from 'drizzle-orm/sqlite-core';
|
|
4
|
-
import { T as TRANSACTION_STATUSES, b as TRANSACTION_TYPES, R as REFERENCE_TYPES } from './ledger.
|
|
4
|
+
import { T as TRANSACTION_STATUSES, b as TRANSACTION_TYPES, R as REFERENCE_TYPES } from './ledger.CYkZYSMS.mjs';
|
|
5
5
|
import '@develit-io/general-codes';
|
|
6
6
|
|
|
7
7
|
const account = sqliteTable("account", {
|
package/dist/types.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const updateTransactionConfirmationSentAt = require('./shared/ledger.
|
|
3
|
+
const updateTransactionConfirmationSentAt = require('./shared/ledger.CwcPuqoq.cjs');
|
|
4
4
|
const generalCodes = require('@develit-io/general-codes');
|
|
5
5
|
require('zod');
|
|
6
6
|
require('@develit-io/backend-sdk');
|
package/dist/types.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { A as ACCOUNT_TYPES, b as ASSET_TYPES, a as AccountType, c as AssetType, B as BALANCE_STRATEGIES, u as BATCH_STATUSES, d as BalanceStrategy, x as BankCode, v as BatchStatus, y as COUNTRY_CODES, z as CountryCode, C as CryptoNetworkCode, w as Currency, t as CurrencyCode, E as ENTRY_STATUSES,
|
|
2
|
-
import { T as TransactionSelectType } from './shared/ledger.
|
|
3
|
-
export { N as AccountIdentifierInsertType, P as AccountIdentifierMappingInsertType, O as AccountIdentifierMappingSelectType, K as AccountIdentifierSelectType, J as AccountInsertType, H as AccountSelectType, R as AccountWithIdentifiersSelectType, i as CreateAccountInput, j as CreateAccountOutput, C as CreateTransactionInput, a as CreateTransactionOutput, D as DeleteAccountInput, l as DeleteAccountOutput, F as FailTransactionInput, c as FailTransactionOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, I as IncludeRelation, E as InferResultType, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, L as ListAccountsInput, q as ListAccountsOutput, M as MatchTransactionInput, b as MatchTransactionOutput, Q as TransactionInsertType, U as UpdateAccountInput, k as UpdateAccountOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput, S as createAccountInputSchema, V as createTransactionInputSchema, W as deleteAccountInputSchema, X as failTransactionInputSchema, Y as findAccountByIdentifierInputSchema, _ as getAccountBalanceInputSchema, $ as getAccountIdentifierInputSchema, Z as getAccountInputSchema, a0 as getAccountsByOwnerInputSchema, a1 as getTransactionByIdInputSchema, a3 as getTransactionsByReferenceIdInputSchema, a2 as getTransactionsInputSchema, a4 as listAccountIdentifiersInputSchema, a5 as listAccountsInputSchema, a6 as matchTransactionInputSchema, a7 as updateAccountInputSchema, a8 as updateTransactionConfirmationSentAtInputSchema } from './shared/ledger.
|
|
1
|
+
export { A as ACCOUNT_TYPES, b as ASSET_TYPES, a as AccountType, c as AssetType, B as BALANCE_STRATEGIES, u as BATCH_STATUSES, d as BalanceStrategy, x as BankCode, v as BatchStatus, y as COUNTRY_CODES, z as CountryCode, C as CryptoNetworkCode, w as Currency, t as CurrencyCode, E as ENTRY_STATUSES, o as EntryMetadata, f as EntryStatus, I as IDENTIFIER_KINDS, e as IdentifierKind, P as PAYMENT_CHARGE_TYPES, r as PAYMENT_DIRECTIONS, p as PAYMENT_STATUSES, l as PAYMENT_TYPES, k as PaymentChargeType, s as PaymentDirection, q as PaymentStatus, m as PaymentType, R as REFERENCE_TYPES, j as ReferenceType, T as TRANSACTION_STATUSES, h as TRANSACTION_TYPES, n as TransactionMetadata, g as TransactionStatus, i as TransactionType } from './shared/ledger.N4btQFi1.cjs';
|
|
2
|
+
import { T as TransactionSelectType } from './shared/ledger.BvbOZ0WG.cjs';
|
|
3
|
+
export { N as AccountIdentifierInsertType, P as AccountIdentifierMappingInsertType, O as AccountIdentifierMappingSelectType, K as AccountIdentifierSelectType, J as AccountInsertType, H as AccountSelectType, R as AccountWithIdentifiersSelectType, i as CreateAccountInput, j as CreateAccountOutput, C as CreateTransactionInput, a as CreateTransactionOutput, D as DeleteAccountInput, l as DeleteAccountOutput, F as FailTransactionInput, c as FailTransactionOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, I as IncludeRelation, E as InferResultType, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, L as ListAccountsInput, q as ListAccountsOutput, M as MatchTransactionInput, b as MatchTransactionOutput, Q as TransactionInsertType, U as UpdateAccountInput, k as UpdateAccountOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput, S as createAccountInputSchema, V as createTransactionInputSchema, W as deleteAccountInputSchema, X as failTransactionInputSchema, Y as findAccountByIdentifierInputSchema, _ as getAccountBalanceInputSchema, $ as getAccountIdentifierInputSchema, Z as getAccountInputSchema, a0 as getAccountsByOwnerInputSchema, a1 as getTransactionByIdInputSchema, a3 as getTransactionsByReferenceIdInputSchema, a2 as getTransactionsInputSchema, a4 as listAccountIdentifiersInputSchema, a5 as listAccountsInputSchema, a6 as matchTransactionInputSchema, a7 as updateAccountInputSchema, a8 as updateTransactionConfirmationSentAtInputSchema } from './shared/ledger.BvbOZ0WG.cjs';
|
|
4
4
|
export { b as LedgerServiceEnv, a as LedgerServiceEnvironmentConfig, L as LedgerServiceWranglerConfig } from './shared/ledger.Ce2yPDUS.cjs';
|
|
5
5
|
import { BaseEvent } from '@develit-io/backend-sdk';
|
|
6
6
|
export { BANK_CODES, CRYPTO_NETWORK_CODES, CURRENCY_CODES } from '@develit-io/general-codes';
|
package/dist/types.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { A as ACCOUNT_TYPES, b as ASSET_TYPES, a as AccountType, c as AssetType, B as BALANCE_STRATEGIES, u as BATCH_STATUSES, d as BalanceStrategy, x as BankCode, v as BatchStatus, y as COUNTRY_CODES, z as CountryCode, C as CryptoNetworkCode, w as Currency, t as CurrencyCode, E as ENTRY_STATUSES,
|
|
2
|
-
import { T as TransactionSelectType } from './shared/ledger.
|
|
3
|
-
export { N as AccountIdentifierInsertType, P as AccountIdentifierMappingInsertType, O as AccountIdentifierMappingSelectType, K as AccountIdentifierSelectType, J as AccountInsertType, H as AccountSelectType, R as AccountWithIdentifiersSelectType, i as CreateAccountInput, j as CreateAccountOutput, C as CreateTransactionInput, a as CreateTransactionOutput, D as DeleteAccountInput, l as DeleteAccountOutput, F as FailTransactionInput, c as FailTransactionOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, I as IncludeRelation, E as InferResultType, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, L as ListAccountsInput, q as ListAccountsOutput, M as MatchTransactionInput, b as MatchTransactionOutput, Q as TransactionInsertType, U as UpdateAccountInput, k as UpdateAccountOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput, S as createAccountInputSchema, V as createTransactionInputSchema, W as deleteAccountInputSchema, X as failTransactionInputSchema, Y as findAccountByIdentifierInputSchema, _ as getAccountBalanceInputSchema, $ as getAccountIdentifierInputSchema, Z as getAccountInputSchema, a0 as getAccountsByOwnerInputSchema, a1 as getTransactionByIdInputSchema, a3 as getTransactionsByReferenceIdInputSchema, a2 as getTransactionsInputSchema, a4 as listAccountIdentifiersInputSchema, a5 as listAccountsInputSchema, a6 as matchTransactionInputSchema, a7 as updateAccountInputSchema, a8 as updateTransactionConfirmationSentAtInputSchema } from './shared/ledger.
|
|
1
|
+
export { A as ACCOUNT_TYPES, b as ASSET_TYPES, a as AccountType, c as AssetType, B as BALANCE_STRATEGIES, u as BATCH_STATUSES, d as BalanceStrategy, x as BankCode, v as BatchStatus, y as COUNTRY_CODES, z as CountryCode, C as CryptoNetworkCode, w as Currency, t as CurrencyCode, E as ENTRY_STATUSES, o as EntryMetadata, f as EntryStatus, I as IDENTIFIER_KINDS, e as IdentifierKind, P as PAYMENT_CHARGE_TYPES, r as PAYMENT_DIRECTIONS, p as PAYMENT_STATUSES, l as PAYMENT_TYPES, k as PaymentChargeType, s as PaymentDirection, q as PaymentStatus, m as PaymentType, R as REFERENCE_TYPES, j as ReferenceType, T as TRANSACTION_STATUSES, h as TRANSACTION_TYPES, n as TransactionMetadata, g as TransactionStatus, i as TransactionType } from './shared/ledger.N4btQFi1.mjs';
|
|
2
|
+
import { T as TransactionSelectType } from './shared/ledger.DRm7L41a.mjs';
|
|
3
|
+
export { N as AccountIdentifierInsertType, P as AccountIdentifierMappingInsertType, O as AccountIdentifierMappingSelectType, K as AccountIdentifierSelectType, J as AccountInsertType, H as AccountSelectType, R as AccountWithIdentifiersSelectType, i as CreateAccountInput, j as CreateAccountOutput, C as CreateTransactionInput, a as CreateTransactionOutput, D as DeleteAccountInput, l as DeleteAccountOutput, F as FailTransactionInput, c as FailTransactionOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, I as IncludeRelation, E as InferResultType, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, L as ListAccountsInput, q as ListAccountsOutput, M as MatchTransactionInput, b as MatchTransactionOutput, Q as TransactionInsertType, U as UpdateAccountInput, k as UpdateAccountOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput, S as createAccountInputSchema, V as createTransactionInputSchema, W as deleteAccountInputSchema, X as failTransactionInputSchema, Y as findAccountByIdentifierInputSchema, _ as getAccountBalanceInputSchema, $ as getAccountIdentifierInputSchema, Z as getAccountInputSchema, a0 as getAccountsByOwnerInputSchema, a1 as getTransactionByIdInputSchema, a3 as getTransactionsByReferenceIdInputSchema, a2 as getTransactionsInputSchema, a4 as listAccountIdentifiersInputSchema, a5 as listAccountsInputSchema, a6 as matchTransactionInputSchema, a7 as updateAccountInputSchema, a8 as updateTransactionConfirmationSentAtInputSchema } from './shared/ledger.DRm7L41a.mjs';
|
|
4
4
|
export { b as LedgerServiceEnv, a as LedgerServiceEnvironmentConfig, L as LedgerServiceWranglerConfig } from './shared/ledger.Ce2yPDUS.mjs';
|
|
5
5
|
import { BaseEvent } from '@develit-io/backend-sdk';
|
|
6
6
|
export { BANK_CODES, CRYPTO_NETWORK_CODES, CURRENCY_CODES } from '@develit-io/general-codes';
|
package/dist/types.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { A as ACCOUNT_TYPES, b as ASSET_TYPES, a as AccountType, c as AssetType, B as BALANCE_STRATEGIES, u as BATCH_STATUSES, d as BalanceStrategy, x as BankCode, v as BatchStatus, y as COUNTRY_CODES, z as CountryCode, C as CryptoNetworkCode, w as Currency, t as CurrencyCode, E as ENTRY_STATUSES,
|
|
2
|
-
import { T as TransactionSelectType } from './shared/ledger.
|
|
3
|
-
export { N as AccountIdentifierInsertType, P as AccountIdentifierMappingInsertType, O as AccountIdentifierMappingSelectType, K as AccountIdentifierSelectType, J as AccountInsertType, H as AccountSelectType, R as AccountWithIdentifiersSelectType, i as CreateAccountInput, j as CreateAccountOutput, C as CreateTransactionInput, a as CreateTransactionOutput, D as DeleteAccountInput, l as DeleteAccountOutput, F as FailTransactionInput, c as FailTransactionOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, I as IncludeRelation, E as InferResultType, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, L as ListAccountsInput, q as ListAccountsOutput, M as MatchTransactionInput, b as MatchTransactionOutput, Q as TransactionInsertType, U as UpdateAccountInput, k as UpdateAccountOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput, S as createAccountInputSchema, V as createTransactionInputSchema, W as deleteAccountInputSchema, X as failTransactionInputSchema, Y as findAccountByIdentifierInputSchema, _ as getAccountBalanceInputSchema, $ as getAccountIdentifierInputSchema, Z as getAccountInputSchema, a0 as getAccountsByOwnerInputSchema, a1 as getTransactionByIdInputSchema, a3 as getTransactionsByReferenceIdInputSchema, a2 as getTransactionsInputSchema, a4 as listAccountIdentifiersInputSchema, a5 as listAccountsInputSchema, a6 as matchTransactionInputSchema, a7 as updateAccountInputSchema, a8 as updateTransactionConfirmationSentAtInputSchema } from './shared/ledger.
|
|
1
|
+
export { A as ACCOUNT_TYPES, b as ASSET_TYPES, a as AccountType, c as AssetType, B as BALANCE_STRATEGIES, u as BATCH_STATUSES, d as BalanceStrategy, x as BankCode, v as BatchStatus, y as COUNTRY_CODES, z as CountryCode, C as CryptoNetworkCode, w as Currency, t as CurrencyCode, E as ENTRY_STATUSES, o as EntryMetadata, f as EntryStatus, I as IDENTIFIER_KINDS, e as IdentifierKind, P as PAYMENT_CHARGE_TYPES, r as PAYMENT_DIRECTIONS, p as PAYMENT_STATUSES, l as PAYMENT_TYPES, k as PaymentChargeType, s as PaymentDirection, q as PaymentStatus, m as PaymentType, R as REFERENCE_TYPES, j as ReferenceType, T as TRANSACTION_STATUSES, h as TRANSACTION_TYPES, n as TransactionMetadata, g as TransactionStatus, i as TransactionType } from './shared/ledger.N4btQFi1.js';
|
|
2
|
+
import { T as TransactionSelectType } from './shared/ledger.Cd1qa4GB.js';
|
|
3
|
+
export { N as AccountIdentifierInsertType, P as AccountIdentifierMappingInsertType, O as AccountIdentifierMappingSelectType, K as AccountIdentifierSelectType, J as AccountInsertType, H as AccountSelectType, R as AccountWithIdentifiersSelectType, i as CreateAccountInput, j as CreateAccountOutput, C as CreateTransactionInput, a as CreateTransactionOutput, D as DeleteAccountInput, l as DeleteAccountOutput, F as FailTransactionInput, c as FailTransactionOutput, w as FindAccountByIdentifierInput, x as FindAccountByIdentifierOutput, y as GetAccountBalanceInput, z as GetAccountBalanceOutput, r as GetAccountIdentifierInput, s as GetAccountIdentifierOutput, m as GetAccountInput, n as GetAccountOutput, o as GetAccountsByOwnerInput, p as GetAccountsByOwnerOutput, G as GetTransactionByIdInput, d as GetTransactionByIdOutput, e as GetTransactionsByIdReferenceInput, f as GetTransactionsByReferenceIdOutput, g as GetTransactionsInput, h as GetTransactionsOutput, I as IncludeRelation, E as InferResultType, u as ListAccountIdentifiersInput, v as ListAccountIdentifiersOutput, L as ListAccountsInput, q as ListAccountsOutput, M as MatchTransactionInput, b as MatchTransactionOutput, Q as TransactionInsertType, U as UpdateAccountInput, k as UpdateAccountOutput, A as UpdateTransactionConfirmationSentAtInput, B as UpdateTransactionConfirmationSentAtOutput, S as createAccountInputSchema, V as createTransactionInputSchema, W as deleteAccountInputSchema, X as failTransactionInputSchema, Y as findAccountByIdentifierInputSchema, _ as getAccountBalanceInputSchema, $ as getAccountIdentifierInputSchema, Z as getAccountInputSchema, a0 as getAccountsByOwnerInputSchema, a1 as getTransactionByIdInputSchema, a3 as getTransactionsByReferenceIdInputSchema, a2 as getTransactionsInputSchema, a4 as listAccountIdentifiersInputSchema, a5 as listAccountsInputSchema, a6 as matchTransactionInputSchema, a7 as updateAccountInputSchema, a8 as updateTransactionConfirmationSentAtInputSchema } from './shared/ledger.Cd1qa4GB.js';
|
|
4
4
|
export { b as LedgerServiceEnv, a as LedgerServiceEnvironmentConfig, L as LedgerServiceWranglerConfig } from './shared/ledger.Ce2yPDUS.js';
|
|
5
5
|
import { BaseEvent } from '@develit-io/backend-sdk';
|
|
6
6
|
export { BANK_CODES, CRYPTO_NETWORK_CODES, CURRENCY_CODES } from '@develit-io/general-codes';
|
package/dist/types.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as ACCOUNT_TYPES,
|
|
1
|
+
export { A as ACCOUNT_TYPES, d as ALLOWED_TRANSACTION_FILTERS, a as ASSET_TYPES, B as BALANCE_STRATEGIES, x as BATCH_STATUSES, C as COUNTRY_CODES, E as ENTRY_STATUSES, I as IDENTIFIER_KINDS, P as PAYMENT_CHARGE_TYPES, w as PAYMENT_DIRECTIONS, v as PAYMENT_STATUSES, c as PAYMENT_TYPES, R as REFERENCE_TYPES, T as TRANSACTION_STATUSES, b as TRANSACTION_TYPES, e as createAccountInputSchema, f as createTransactionInputSchema, g as deleteAccountInputSchema, h as failTransactionInputSchema, i as findAccountByIdentifierInputSchema, k as getAccountBalanceInputSchema, l as getAccountIdentifierInputSchema, j as getAccountInputSchema, m as getAccountsByOwnerInputSchema, n as getTransactionByIdInputSchema, p as getTransactionsByReferenceIdInputSchema, o as getTransactionsInputSchema, q as listAccountIdentifiersInputSchema, r as listAccountsInputSchema, s as matchTransactionInputSchema, u as updateAccountInputSchema, t as updateTransactionConfirmationSentAtInputSchema } from './shared/ledger.CYkZYSMS.mjs';
|
|
2
2
|
export { BANK_CODES, CURRENCY_CODES } from '@develit-io/general-codes';
|
|
3
3
|
import 'zod';
|
|
4
4
|
import '@develit-io/backend-sdk';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@develit-services/ledger",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.16",
|
|
4
4
|
"author": "Develit.io s.r.o.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
],
|
|
32
32
|
"scripts": {
|
|
33
33
|
"dev": "wrangler dev --port 9234 --persist-to ../../.wrangler/state",
|
|
34
|
-
"wrangler:generate": "develit wrangler:generate",
|
|
34
|
+
"wrangler:generate": "bunx develit wrangler:generate --types",
|
|
35
35
|
"db:init": "wrangler d1 execute develit-ledger --local --persist-to ../../.wrangler/state --command=\"SELECT 'Creating database...' AS status;\"",
|
|
36
36
|
"db:generate": "drizzle-kit generate",
|
|
37
37
|
"db:migrate": "drizzle-kit migrate",
|