@develit-services/blockchain 0.11.0 → 0.12.0

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 (30) hide show
  1. package/dist/database/schema.cjs +2 -2
  2. package/dist/database/schema.d.cts +1 -1
  3. package/dist/database/schema.d.mts +1 -1
  4. package/dist/database/schema.d.ts +1 -1
  5. package/dist/database/schema.mjs +2 -2
  6. package/dist/export/worker.cjs +28 -7
  7. package/dist/export/worker.d.cts +3 -2
  8. package/dist/export/worker.d.mts +3 -2
  9. package/dist/export/worker.d.ts +3 -2
  10. package/dist/export/worker.mjs +25 -4
  11. package/dist/export/workflows.cjs +3 -3
  12. package/dist/export/workflows.mjs +3 -3
  13. package/dist/shared/{blockchain.DNPZEckN.d.mts → blockchain.BL2AlFRD.d.ts} +27 -3
  14. package/dist/shared/{blockchain.CRWCUwHr.cjs → blockchain.BUnmkBag.cjs} +24 -1
  15. package/dist/shared/{blockchain.C5pjxssf.cjs → blockchain.BVya3Mud.cjs} +16 -11
  16. package/dist/shared/{blockchain.ByhE_RaE.mjs → blockchain.BbPuQECZ.mjs} +24 -1
  17. package/dist/shared/{blockchain.CyyZn6RX.d.cts → blockchain.BioJdfy8.d.cts} +2 -2
  18. package/dist/shared/{blockchain.CyyZn6RX.d.mts → blockchain.BioJdfy8.d.mts} +2 -2
  19. package/dist/shared/{blockchain.CyyZn6RX.d.ts → blockchain.BioJdfy8.d.ts} +2 -2
  20. package/dist/shared/{blockchain.c19XIse8.mjs → blockchain.BsFFrNF0.mjs} +15 -12
  21. package/dist/shared/{blockchain.Bh6x4dsx.d.ts → blockchain.C8acDQuh.d.mts} +27 -3
  22. package/dist/shared/{blockchain.8YeEVniE.mjs → blockchain.ChUyJIdK.mjs} +1 -1
  23. package/dist/shared/{blockchain.CXld_MYP.cjs → blockchain.DR86eH-9.cjs} +3 -3
  24. package/dist/shared/{blockchain.CeVkeCGH.d.cts → blockchain.Z_R-J9qs.d.cts} +27 -3
  25. package/dist/types.cjs +14 -12
  26. package/dist/types.d.cts +3 -3
  27. package/dist/types.d.mts +3 -3
  28. package/dist/types.d.ts +3 -3
  29. package/dist/types.mjs +1 -1
  30. package/package.json +1 -1
@@ -1,9 +1,9 @@
1
1
  'use strict';
2
2
 
3
- const database_schema = require('../shared/blockchain.CXld_MYP.cjs');
3
+ const database_schema = require('../shared/blockchain.DR86eH-9.cjs');
4
4
  require('@develit-io/backend-sdk');
5
5
  require('drizzle-orm/sqlite-core');
6
- require('../shared/blockchain.C5pjxssf.cjs');
6
+ require('../shared/blockchain.BVya3Mud.cjs');
7
7
  require('zod');
8
8
 
9
9
 
@@ -1,2 +1,2 @@
1
- export { c as address, d as addressCredentials, t as tokens, e as transaction } from '../shared/blockchain.CyyZn6RX.cjs';
1
+ export { c as address, d as addressCredentials, t as tokens, e as transaction } from '../shared/blockchain.BioJdfy8.cjs';
2
2
  import 'drizzle-orm/sqlite-core';
@@ -1,2 +1,2 @@
1
- export { c as address, d as addressCredentials, t as tokens, e as transaction } from '../shared/blockchain.CyyZn6RX.mjs';
1
+ export { c as address, d as addressCredentials, t as tokens, e as transaction } from '../shared/blockchain.BioJdfy8.mjs';
2
2
  import 'drizzle-orm/sqlite-core';
@@ -1,2 +1,2 @@
1
- export { c as address, d as addressCredentials, t as tokens, e as transaction } from '../shared/blockchain.CyyZn6RX.js';
1
+ export { c as address, d as addressCredentials, t as tokens, e as transaction } from '../shared/blockchain.BioJdfy8.js';
2
2
  import 'drizzle-orm/sqlite-core';
@@ -1,5 +1,5 @@
1
- export { a as address, b as addressCredentials, t as tokens, c as transaction } from '../shared/blockchain.8YeEVniE.mjs';
1
+ export { a as address, b as addressCredentials, t as tokens, c as transaction } from '../shared/blockchain.ChUyJIdK.mjs';
2
2
  import '@develit-io/backend-sdk';
3
3
  import 'drizzle-orm/sqlite-core';
4
- import '../shared/blockchain.c19XIse8.mjs';
4
+ import '../shared/blockchain.BsFFrNF0.mjs';
5
5
  import 'zod';
@@ -3,11 +3,11 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const backendSdk = require('@develit-io/backend-sdk');
6
- const blockchain = require('../shared/blockchain.CRWCUwHr.cjs');
7
- const syncAddress = require('../shared/blockchain.C5pjxssf.cjs');
6
+ const blockchain = require('../shared/blockchain.BUnmkBag.cjs');
7
+ const address = require('../shared/blockchain.BVya3Mud.cjs');
8
8
  const cloudflare_workers = require('cloudflare:workers');
9
9
  const d1 = require('drizzle-orm/d1');
10
- require('../shared/blockchain.CXld_MYP.cjs');
10
+ require('../shared/blockchain.DR86eH-9.cjs');
11
11
  require('drizzle-orm/sqlite-core');
12
12
  require('drizzle-orm');
13
13
  require('viem');
@@ -33,8 +33,8 @@ let BlockchainServiceBase = class extends backendSdk.develitWorker(
33
33
  }
34
34
  async syncAddress(input) {
35
35
  return this.handleAction(
36
- { data: input, schema: syncAddress.syncAddressInputSchema },
37
- { successMessage: "Address sync workflow started" },
36
+ { data: input, schema: address.syncAddressInputSchema },
37
+ { successMessage: "Address sync workflow started." },
38
38
  async ({ addressId }) => {
39
39
  const instance = await this.env.SYNC_ADDRESS_TRANSACTIONS_WORKFLOW.create({
40
40
  id: addressId,
@@ -51,7 +51,7 @@ let BlockchainServiceBase = class extends backendSdk.develitWorker(
51
51
  }
52
52
  async getTransaction(input) {
53
53
  return this.handleAction(
54
- { data: input, schema: syncAddress.getTransactionInputSchema },
54
+ { data: input, schema: address.getTransactionInputSchema },
55
55
  { successMessage: "Transaction retrieved successfully." },
56
56
  async ({ chain, txHash }) => {
57
57
  const connector = await blockchain.initiateConnector({
@@ -64,9 +64,27 @@ let BlockchainServiceBase = class extends backendSdk.develitWorker(
64
64
  }
65
65
  );
66
66
  }
67
+ async getDecimals(input) {
68
+ return this.handleAction(
69
+ { data: input, schema: address.getDecimalsInputSchema },
70
+ { successMessage: "Decimals retrieved successfully." },
71
+ async ({ chain, contractAddress }) => {
72
+ const connector = await blockchain.initiateConnector({
73
+ chain,
74
+ env: this.env,
75
+ tokens: [],
76
+ connectedAddresses: []
77
+ });
78
+ const decimals = await connector.getDecimals(
79
+ contractAddress
80
+ );
81
+ return { decimals };
82
+ }
83
+ );
84
+ }
67
85
  async getBlock(input) {
68
86
  return this.handleAction(
69
- { data: input, schema: syncAddress.getBlockInputSchema },
87
+ { data: input, schema: address.getBlockInputSchema },
70
88
  { successMessage: "Block retrieved successfully." },
71
89
  async ({ chain, blockHash, blockNumber, blockTag }) => {
72
90
  const connector = await blockchain.initiateConnector({
@@ -90,6 +108,9 @@ __decorateClass([
90
108
  __decorateClass([
91
109
  backendSdk.action("get-transaction")
92
110
  ], BlockchainServiceBase.prototype, "getTransaction", 1);
111
+ __decorateClass([
112
+ backendSdk.action("get-decimals")
113
+ ], BlockchainServiceBase.prototype, "getDecimals", 1);
93
114
  __decorateClass([
94
115
  backendSdk.action("get-block")
95
116
  ], BlockchainServiceBase.prototype, "getBlock", 1);
@@ -1,10 +1,10 @@
1
1
  import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
2
2
  import { IRPCResponse } from '@develit-io/backend-sdk';
3
- import { t as tables, S as SyncAddressInput, a as SyncAddressOutput, G as GetTransactionInput, b as GetTransactionOutput, c as GetBlockInput, d as GetBlockOutput } from '../shared/blockchain.CeVkeCGH.cjs';
3
+ import { t as tables, S as SyncAddressInput, a as SyncAddressOutput, G as GetTransactionInput, b as GetTransactionOutput, c as GetDecimalsInput, d as GetDecimalsOutput, e as GetBlockInput, f as GetBlockOutput } from '../shared/blockchain.Z_R-J9qs.cjs';
4
4
  import { WorkerEntrypoint } from 'cloudflare:workers';
5
5
  import { DrizzleD1Database } from 'drizzle-orm/d1';
6
6
  import 'zod';
7
- import '../shared/blockchain.CyyZn6RX.cjs';
7
+ import '../shared/blockchain.BioJdfy8.cjs';
8
8
  import 'drizzle-orm/sqlite-core';
9
9
 
10
10
  declare const BlockchainServiceBase_base: (abstract new (ctx: ExecutionContext, env: BlockchainEnv) => WorkerEntrypoint<BlockchainEnv, {}>) & (abstract new (...args: any[]) => _develit_io_backend_sdk.DevelitWorkerMethods);
@@ -13,6 +13,7 @@ declare class BlockchainServiceBase extends BlockchainServiceBase_base {
13
13
  constructor(ctx: ExecutionContext, env: BlockchainEnv);
14
14
  syncAddress(input: SyncAddressInput): Promise<IRPCResponse<SyncAddressOutput>>;
15
15
  getTransaction(input: GetTransactionInput): Promise<IRPCResponse<GetTransactionOutput>>;
16
+ getDecimals(input: GetDecimalsInput): Promise<IRPCResponse<GetDecimalsOutput>>;
16
17
  getBlock(input: GetBlockInput): Promise<IRPCResponse<GetBlockOutput>>;
17
18
  }
18
19
  declare function defineBlockchainService(): new (ctx: ExecutionContext, env: BlockchainEnv) => BlockchainServiceBase;
@@ -1,10 +1,10 @@
1
1
  import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
2
2
  import { IRPCResponse } from '@develit-io/backend-sdk';
3
- import { t as tables, S as SyncAddressInput, a as SyncAddressOutput, G as GetTransactionInput, b as GetTransactionOutput, c as GetBlockInput, d as GetBlockOutput } from '../shared/blockchain.DNPZEckN.mjs';
3
+ import { t as tables, S as SyncAddressInput, a as SyncAddressOutput, G as GetTransactionInput, b as GetTransactionOutput, c as GetDecimalsInput, d as GetDecimalsOutput, e as GetBlockInput, f as GetBlockOutput } from '../shared/blockchain.C8acDQuh.mjs';
4
4
  import { WorkerEntrypoint } from 'cloudflare:workers';
5
5
  import { DrizzleD1Database } from 'drizzle-orm/d1';
6
6
  import 'zod';
7
- import '../shared/blockchain.CyyZn6RX.mjs';
7
+ import '../shared/blockchain.BioJdfy8.mjs';
8
8
  import 'drizzle-orm/sqlite-core';
9
9
 
10
10
  declare const BlockchainServiceBase_base: (abstract new (ctx: ExecutionContext, env: BlockchainEnv) => WorkerEntrypoint<BlockchainEnv, {}>) & (abstract new (...args: any[]) => _develit_io_backend_sdk.DevelitWorkerMethods);
@@ -13,6 +13,7 @@ declare class BlockchainServiceBase extends BlockchainServiceBase_base {
13
13
  constructor(ctx: ExecutionContext, env: BlockchainEnv);
14
14
  syncAddress(input: SyncAddressInput): Promise<IRPCResponse<SyncAddressOutput>>;
15
15
  getTransaction(input: GetTransactionInput): Promise<IRPCResponse<GetTransactionOutput>>;
16
+ getDecimals(input: GetDecimalsInput): Promise<IRPCResponse<GetDecimalsOutput>>;
16
17
  getBlock(input: GetBlockInput): Promise<IRPCResponse<GetBlockOutput>>;
17
18
  }
18
19
  declare function defineBlockchainService(): new (ctx: ExecutionContext, env: BlockchainEnv) => BlockchainServiceBase;
@@ -1,10 +1,10 @@
1
1
  import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
2
2
  import { IRPCResponse } from '@develit-io/backend-sdk';
3
- import { t as tables, S as SyncAddressInput, a as SyncAddressOutput, G as GetTransactionInput, b as GetTransactionOutput, c as GetBlockInput, d as GetBlockOutput } from '../shared/blockchain.Bh6x4dsx.js';
3
+ import { t as tables, S as SyncAddressInput, a as SyncAddressOutput, G as GetTransactionInput, b as GetTransactionOutput, c as GetDecimalsInput, d as GetDecimalsOutput, e as GetBlockInput, f as GetBlockOutput } from '../shared/blockchain.BL2AlFRD.js';
4
4
  import { WorkerEntrypoint } from 'cloudflare:workers';
5
5
  import { DrizzleD1Database } from 'drizzle-orm/d1';
6
6
  import 'zod';
7
- import '../shared/blockchain.CyyZn6RX.js';
7
+ import '../shared/blockchain.BioJdfy8.js';
8
8
  import 'drizzle-orm/sqlite-core';
9
9
 
10
10
  declare const BlockchainServiceBase_base: (abstract new (ctx: ExecutionContext, env: BlockchainEnv) => WorkerEntrypoint<BlockchainEnv, {}>) & (abstract new (...args: any[]) => _develit_io_backend_sdk.DevelitWorkerMethods);
@@ -13,6 +13,7 @@ declare class BlockchainServiceBase extends BlockchainServiceBase_base {
13
13
  constructor(ctx: ExecutionContext, env: BlockchainEnv);
14
14
  syncAddress(input: SyncAddressInput): Promise<IRPCResponse<SyncAddressOutput>>;
15
15
  getTransaction(input: GetTransactionInput): Promise<IRPCResponse<GetTransactionOutput>>;
16
+ getDecimals(input: GetDecimalsInput): Promise<IRPCResponse<GetDecimalsOutput>>;
16
17
  getBlock(input: GetBlockInput): Promise<IRPCResponse<GetBlockOutput>>;
17
18
  }
18
19
  declare function defineBlockchainService(): new (ctx: ExecutionContext, env: BlockchainEnv) => BlockchainServiceBase;
@@ -1,9 +1,9 @@
1
1
  import { develitWorker, action, service } from '@develit-io/backend-sdk';
2
- import { t as tables, i as initiateConnector } from '../shared/blockchain.ByhE_RaE.mjs';
3
- import { s as syncAddressInputSchema, d as getTransactionInputSchema, g as getBlockInputSchema } from '../shared/blockchain.c19XIse8.mjs';
2
+ import { t as tables, i as initiateConnector } from '../shared/blockchain.BbPuQECZ.mjs';
3
+ import { s as syncAddressInputSchema, f as getTransactionInputSchema, d as getDecimalsInputSchema, g as getBlockInputSchema } from '../shared/blockchain.BsFFrNF0.mjs';
4
4
  import { WorkerEntrypoint } from 'cloudflare:workers';
5
5
  import { drizzle } from 'drizzle-orm/d1';
6
- import '../shared/blockchain.8YeEVniE.mjs';
6
+ import '../shared/blockchain.ChUyJIdK.mjs';
7
7
  import 'drizzle-orm/sqlite-core';
8
8
  import 'drizzle-orm';
9
9
  import 'viem';
@@ -30,7 +30,7 @@ let BlockchainServiceBase = class extends develitWorker(
30
30
  async syncAddress(input) {
31
31
  return this.handleAction(
32
32
  { data: input, schema: syncAddressInputSchema },
33
- { successMessage: "Address sync workflow started" },
33
+ { successMessage: "Address sync workflow started." },
34
34
  async ({ addressId }) => {
35
35
  const instance = await this.env.SYNC_ADDRESS_TRANSACTIONS_WORKFLOW.create({
36
36
  id: addressId,
@@ -60,6 +60,24 @@ let BlockchainServiceBase = class extends develitWorker(
60
60
  }
61
61
  );
62
62
  }
63
+ async getDecimals(input) {
64
+ return this.handleAction(
65
+ { data: input, schema: getDecimalsInputSchema },
66
+ { successMessage: "Decimals retrieved successfully." },
67
+ async ({ chain, contractAddress }) => {
68
+ const connector = await initiateConnector({
69
+ chain,
70
+ env: this.env,
71
+ tokens: [],
72
+ connectedAddresses: []
73
+ });
74
+ const decimals = await connector.getDecimals(
75
+ contractAddress
76
+ );
77
+ return { decimals };
78
+ }
79
+ );
80
+ }
63
81
  async getBlock(input) {
64
82
  return this.handleAction(
65
83
  { data: input, schema: getBlockInputSchema },
@@ -86,6 +104,9 @@ __decorateClass([
86
104
  __decorateClass([
87
105
  action("get-transaction")
88
106
  ], BlockchainServiceBase.prototype, "getTransaction", 1);
107
+ __decorateClass([
108
+ action("get-decimals")
109
+ ], BlockchainServiceBase.prototype, "getDecimals", 1);
89
110
  __decorateClass([
90
111
  action("get-block")
91
112
  ], BlockchainServiceBase.prototype, "getBlock", 1);
@@ -1,14 +1,14 @@
1
1
  'use strict';
2
2
 
3
3
  const backendSdk = require('@develit-io/backend-sdk');
4
- const blockchain = require('../shared/blockchain.CRWCUwHr.cjs');
4
+ const blockchain = require('../shared/blockchain.BUnmkBag.cjs');
5
5
  const drizzleOrm = require('drizzle-orm');
6
6
  const cloudflare_workers = require('cloudflare:workers');
7
7
  const cloudflare_workflows = require('cloudflare:workflows');
8
8
  const d1 = require('drizzle-orm/d1');
9
- require('../shared/blockchain.CXld_MYP.cjs');
9
+ require('../shared/blockchain.DR86eH-9.cjs');
10
10
  require('drizzle-orm/sqlite-core');
11
- require('../shared/blockchain.C5pjxssf.cjs');
11
+ require('../shared/blockchain.BVya3Mud.cjs');
12
12
  require('zod');
13
13
  require('viem');
14
14
  require('viem/accounts');
@@ -1,12 +1,12 @@
1
1
  import { uuidv4, asNonEmpty } from '@develit-io/backend-sdk';
2
- import { t as tables, i as initiateConnector } from '../shared/blockchain.ByhE_RaE.mjs';
2
+ import { t as tables, i as initiateConnector } from '../shared/blockchain.BbPuQECZ.mjs';
3
3
  import { eq } from 'drizzle-orm';
4
4
  import { WorkflowEntrypoint } from 'cloudflare:workers';
5
5
  import { NonRetryableError } from 'cloudflare:workflows';
6
6
  import { drizzle } from 'drizzle-orm/d1';
7
- import '../shared/blockchain.8YeEVniE.mjs';
7
+ import '../shared/blockchain.ChUyJIdK.mjs';
8
8
  import 'drizzle-orm/sqlite-core';
9
- import '../shared/blockchain.c19XIse8.mjs';
9
+ import '../shared/blockchain.BsFFrNF0.mjs';
10
10
  import 'zod';
11
11
  import 'viem';
12
12
  import 'viem/accounts';
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- import { s as schema } from './blockchain.CyyZn6RX.mjs';
2
+ import { s as schema } from './blockchain.BioJdfy8.js';
3
3
 
4
4
  declare const getBlockInputSchema: z.ZodObject<{
5
5
  chain: z.ZodEnum<{
@@ -64,6 +64,30 @@ interface GetBlockInput extends z.infer<typeof getBlockInputSchema> {
64
64
  }
65
65
  type GetBlockOutput = z.infer<typeof getBlockOutputSchema>;
66
66
 
67
+ declare const getDecimalsInputSchema: z.ZodObject<{
68
+ chain: z.ZodEnum<{
69
+ ARBITRUM: "ARBITRUM";
70
+ AVALANCHE: "AVALANCHE";
71
+ BASE: "BASE";
72
+ ETHEREUM: "ETHEREUM";
73
+ GNOSIS: "GNOSIS";
74
+ OPTIMISM: "OPTIMISM";
75
+ ARBITRUM_SEPOLIA: "ARBITRUM_SEPOLIA";
76
+ BASE_SEPOLIA: "BASE_SEPOLIA";
77
+ CHIADO: "CHIADO";
78
+ FUJI: "FUJI";
79
+ OPTIMISM_SEPOLIA: "OPTIMISM_SEPOLIA";
80
+ SEPOLIA: "SEPOLIA";
81
+ }>;
82
+ contractAddress: z.ZodString;
83
+ }, z.core.$strip>;
84
+ declare const getDecimalsOutputSchema: z.ZodObject<{
85
+ decimals: z.ZodNumber;
86
+ }, z.core.$strip>;
87
+ interface GetDecimalsInput extends z.infer<typeof getDecimalsInputSchema> {
88
+ }
89
+ type GetDecimalsOutput = z.infer<typeof getDecimalsOutputSchema>;
90
+
67
91
  declare const MAINNET_CHAIN_TYPE: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM"];
68
92
  declare const TESTNET_CHAIN_TYPE: readonly ["ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
69
93
  declare const chainSchema: z.ZodEnum<{
@@ -151,5 +175,5 @@ type SyncAddressOutput = z.infer<typeof syncAddressOutputSchema>;
151
175
 
152
176
  declare const tables: typeof schema;
153
177
 
154
- export { MAINNET_CHAIN_TYPE as M, TESTNET_CHAIN_TYPE as T, chainSchema as e, getBlockOutputSchema as f, getBlockInputSchema as g, getTransactionInputSchema as h, getTransactionOutputSchema as i, syncAddressOutputSchema as j, syncAddressInputSchema as s, tables as t };
155
- export type { Chain as C, GetTransactionInput as G, SyncAddressInput as S, SyncAddressOutput as a, GetTransactionOutput as b, GetBlockInput as c, GetBlockOutput as d };
178
+ export { MAINNET_CHAIN_TYPE as M, TESTNET_CHAIN_TYPE as T, chainSchema as g, getBlockInputSchema as h, getBlockOutputSchema as i, getDecimalsInputSchema as j, getDecimalsOutputSchema as k, getTransactionInputSchema as l, getTransactionOutputSchema as m, syncAddressOutputSchema as n, syncAddressInputSchema as s, tables as t };
179
+ export type { Chain as C, GetTransactionInput as G, SyncAddressInput as S, SyncAddressOutput as a, GetTransactionOutput as b, GetDecimalsInput as c, GetDecimalsOutput as d, GetBlockInput as e, GetBlockOutput as f };
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- const database_schema = require('./blockchain.CXld_MYP.cjs');
3
+ const database_schema = require('./blockchain.DR86eH-9.cjs');
4
4
  require('drizzle-orm');
5
5
  const backendSdk = require('@develit-io/backend-sdk');
6
6
  const viem = require('viem');
@@ -22,6 +22,15 @@ const TRANSFER_EVENT_ABI = [
22
22
  ]
23
23
  }
24
24
  ];
25
+ const ERC20_DECIMALS_ABI = [
26
+ {
27
+ type: "function",
28
+ name: "decimals",
29
+ inputs: [],
30
+ outputs: [{ name: "", type: "uint8" }],
31
+ stateMutability: "view"
32
+ }
33
+ ];
25
34
  const ERC20_TRANSFER_ABI = [
26
35
  {
27
36
  type: "function",
@@ -119,6 +128,20 @@ class EvmConnector extends IBlockchainConnector {
119
128
  }
120
129
  return block;
121
130
  }
131
+ async getDecimals(contractAddress) {
132
+ const client = this.createClient();
133
+ const [decimals, error] = await backendSdk.useResult(
134
+ client.readContract({
135
+ abi: ERC20_DECIMALS_ABI,
136
+ address: contractAddress,
137
+ functionName: "decimals"
138
+ })
139
+ );
140
+ if (error || !decimals) {
141
+ throw error;
142
+ }
143
+ return decimals;
144
+ }
122
145
  async getAllAddressTransactions({
123
146
  address,
124
147
  filter
@@ -3,17 +3,6 @@
3
3
  const zod = require('zod');
4
4
  const backendSdk = require('@develit-io/backend-sdk');
5
5
 
6
- const CHAIN_KEYS = [
7
- "ARBITRUM",
8
- "AVALANCHE",
9
- "BASE",
10
- "ETHEREUM",
11
- "GNOSIS",
12
- "OPTIMISM",
13
- "SCROLL"
14
- ];
15
- const CREDENTIALS_TYPES = ["PRIVATE_KEY"];
16
-
17
6
  const MAINNET_CHAIN_TYPE = [
18
7
  "ARBITRUM",
19
8
  "AVALANCHE",
@@ -100,6 +89,14 @@ const getBlockOutputSchema = zod.z.object({
100
89
  withdrawalsRoot: Hex.optional()
101
90
  });
102
91
 
92
+ const getDecimalsInputSchema = zod.z.object({
93
+ chain: chainSchema,
94
+ contractAddress: zod.z.string()
95
+ });
96
+ const getDecimalsOutputSchema = zod.z.object({
97
+ decimals: zod.z.number()
98
+ });
99
+
103
100
  const syncAddressInputSchema = zod.z.object({
104
101
  addressId: zod.z.string()
105
102
  });
@@ -108,6 +105,12 @@ const syncAddressOutputSchema = zod.z.object({
108
105
  details: backendSdk.workflowInstanceStatusSchema
109
106
  });
110
107
 
108
+ const CHAIN_KEYS = [
109
+ ...MAINNET_CHAIN_TYPE,
110
+ ...TESTNET_CHAIN_TYPE
111
+ ];
112
+ const CREDENTIALS_TYPES = ["PRIVATE_KEY"];
113
+
111
114
  exports.CHAIN_KEYS = CHAIN_KEYS;
112
115
  exports.CREDENTIALS_TYPES = CREDENTIALS_TYPES;
113
116
  exports.MAINNET_CHAIN_TYPE = MAINNET_CHAIN_TYPE;
@@ -115,6 +118,8 @@ exports.TESTNET_CHAIN_TYPE = TESTNET_CHAIN_TYPE;
115
118
  exports.chainSchema = chainSchema;
116
119
  exports.getBlockInputSchema = getBlockInputSchema;
117
120
  exports.getBlockOutputSchema = getBlockOutputSchema;
121
+ exports.getDecimalsInputSchema = getDecimalsInputSchema;
122
+ exports.getDecimalsOutputSchema = getDecimalsOutputSchema;
118
123
  exports.getTransactionInputSchema = getTransactionInputSchema;
119
124
  exports.getTransactionOutputSchema = getTransactionOutputSchema;
120
125
  exports.syncAddressInputSchema = syncAddressInputSchema;
@@ -1,4 +1,4 @@
1
- import { s as schema } from './blockchain.8YeEVniE.mjs';
1
+ import { s as schema } from './blockchain.ChUyJIdK.mjs';
2
2
  import 'drizzle-orm';
3
3
  import { useResult, createInternalError } from '@develit-io/backend-sdk';
4
4
  import { createPublicClient, http, createWalletClient, encodeFunctionData, parseUnits } from 'viem';
@@ -20,6 +20,15 @@ const TRANSFER_EVENT_ABI = [
20
20
  ]
21
21
  }
22
22
  ];
23
+ const ERC20_DECIMALS_ABI = [
24
+ {
25
+ type: "function",
26
+ name: "decimals",
27
+ inputs: [],
28
+ outputs: [{ name: "", type: "uint8" }],
29
+ stateMutability: "view"
30
+ }
31
+ ];
23
32
  const ERC20_TRANSFER_ABI = [
24
33
  {
25
34
  type: "function",
@@ -117,6 +126,20 @@ class EvmConnector extends IBlockchainConnector {
117
126
  }
118
127
  return block;
119
128
  }
129
+ async getDecimals(contractAddress) {
130
+ const client = this.createClient();
131
+ const [decimals, error] = await useResult(
132
+ client.readContract({
133
+ abi: ERC20_DECIMALS_ABI,
134
+ address: contractAddress,
135
+ functionName: "decimals"
136
+ })
137
+ );
138
+ if (error || !decimals) {
139
+ throw error;
140
+ }
141
+ return decimals;
142
+ }
120
143
  async getAllAddressTransactions({
121
144
  address,
122
145
  filter
@@ -3,7 +3,7 @@ import * as drizzle_orm_sqlite_core from 'drizzle-orm/sqlite-core';
3
3
  interface LastSyncMetadata {
4
4
  eventsEmitted: number;
5
5
  }
6
- declare const CHAIN_KEYS: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "SCROLL"];
6
+ declare const CHAIN_KEYS: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
7
7
  declare const CREDENTIALS_TYPES: readonly ["PRIVATE_KEY"];
8
8
  type CredentialsType = (typeof CREDENTIALS_TYPES)[number];
9
9
 
@@ -286,7 +286,7 @@ declare const addressCredentials: drizzle_orm_sqlite_core.SQLiteTableWithColumns
286
286
  isPrimaryKey: false;
287
287
  isAutoincrement: false;
288
288
  hasRuntimeDefault: false;
289
- enumValues: ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "SCROLL"];
289
+ enumValues: ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
290
290
  baseColumn: never;
291
291
  identity: undefined;
292
292
  generated: undefined;
@@ -3,7 +3,7 @@ import * as drizzle_orm_sqlite_core from 'drizzle-orm/sqlite-core';
3
3
  interface LastSyncMetadata {
4
4
  eventsEmitted: number;
5
5
  }
6
- declare const CHAIN_KEYS: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "SCROLL"];
6
+ declare const CHAIN_KEYS: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
7
7
  declare const CREDENTIALS_TYPES: readonly ["PRIVATE_KEY"];
8
8
  type CredentialsType = (typeof CREDENTIALS_TYPES)[number];
9
9
 
@@ -286,7 +286,7 @@ declare const addressCredentials: drizzle_orm_sqlite_core.SQLiteTableWithColumns
286
286
  isPrimaryKey: false;
287
287
  isAutoincrement: false;
288
288
  hasRuntimeDefault: false;
289
- enumValues: ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "SCROLL"];
289
+ enumValues: ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
290
290
  baseColumn: never;
291
291
  identity: undefined;
292
292
  generated: undefined;
@@ -3,7 +3,7 @@ import * as drizzle_orm_sqlite_core from 'drizzle-orm/sqlite-core';
3
3
  interface LastSyncMetadata {
4
4
  eventsEmitted: number;
5
5
  }
6
- declare const CHAIN_KEYS: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "SCROLL"];
6
+ declare const CHAIN_KEYS: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
7
7
  declare const CREDENTIALS_TYPES: readonly ["PRIVATE_KEY"];
8
8
  type CredentialsType = (typeof CREDENTIALS_TYPES)[number];
9
9
 
@@ -286,7 +286,7 @@ declare const addressCredentials: drizzle_orm_sqlite_core.SQLiteTableWithColumns
286
286
  isPrimaryKey: false;
287
287
  isAutoincrement: false;
288
288
  hasRuntimeDefault: false;
289
- enumValues: ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "SCROLL"];
289
+ enumValues: ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM", "ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
290
290
  baseColumn: never;
291
291
  identity: undefined;
292
292
  generated: undefined;
@@ -1,17 +1,6 @@
1
1
  import { z } from 'zod';
2
2
  import { workflowInstanceStatusSchema } from '@develit-io/backend-sdk';
3
3
 
4
- const CHAIN_KEYS = [
5
- "ARBITRUM",
6
- "AVALANCHE",
7
- "BASE",
8
- "ETHEREUM",
9
- "GNOSIS",
10
- "OPTIMISM",
11
- "SCROLL"
12
- ];
13
- const CREDENTIALS_TYPES = ["PRIVATE_KEY"];
14
-
15
4
  const MAINNET_CHAIN_TYPE = [
16
5
  "ARBITRUM",
17
6
  "AVALANCHE",
@@ -98,6 +87,14 @@ const getBlockOutputSchema = z.object({
98
87
  withdrawalsRoot: Hex.optional()
99
88
  });
100
89
 
90
+ const getDecimalsInputSchema = z.object({
91
+ chain: chainSchema,
92
+ contractAddress: z.string()
93
+ });
94
+ const getDecimalsOutputSchema = z.object({
95
+ decimals: z.number()
96
+ });
97
+
101
98
  const syncAddressInputSchema = z.object({
102
99
  addressId: z.string()
103
100
  });
@@ -106,4 +103,10 @@ const syncAddressOutputSchema = z.object({
106
103
  details: workflowInstanceStatusSchema
107
104
  });
108
105
 
109
- export { CHAIN_KEYS as C, MAINNET_CHAIN_TYPE as M, TESTNET_CHAIN_TYPE as T, CREDENTIALS_TYPES as a, getBlockOutputSchema as b, chainSchema as c, getTransactionInputSchema as d, getTransactionOutputSchema as e, syncAddressOutputSchema as f, getBlockInputSchema as g, syncAddressInputSchema as s };
106
+ const CHAIN_KEYS = [
107
+ ...MAINNET_CHAIN_TYPE,
108
+ ...TESTNET_CHAIN_TYPE
109
+ ];
110
+ const CREDENTIALS_TYPES = ["PRIVATE_KEY"];
111
+
112
+ export { CHAIN_KEYS as C, MAINNET_CHAIN_TYPE as M, TESTNET_CHAIN_TYPE as T, CREDENTIALS_TYPES as a, getBlockOutputSchema as b, chainSchema as c, getDecimalsInputSchema as d, getDecimalsOutputSchema as e, getTransactionInputSchema as f, getBlockInputSchema as g, getTransactionOutputSchema as h, syncAddressOutputSchema as i, syncAddressInputSchema as s };
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- import { s as schema } from './blockchain.CyyZn6RX.js';
2
+ import { s as schema } from './blockchain.BioJdfy8.mjs';
3
3
 
4
4
  declare const getBlockInputSchema: z.ZodObject<{
5
5
  chain: z.ZodEnum<{
@@ -64,6 +64,30 @@ interface GetBlockInput extends z.infer<typeof getBlockInputSchema> {
64
64
  }
65
65
  type GetBlockOutput = z.infer<typeof getBlockOutputSchema>;
66
66
 
67
+ declare const getDecimalsInputSchema: z.ZodObject<{
68
+ chain: z.ZodEnum<{
69
+ ARBITRUM: "ARBITRUM";
70
+ AVALANCHE: "AVALANCHE";
71
+ BASE: "BASE";
72
+ ETHEREUM: "ETHEREUM";
73
+ GNOSIS: "GNOSIS";
74
+ OPTIMISM: "OPTIMISM";
75
+ ARBITRUM_SEPOLIA: "ARBITRUM_SEPOLIA";
76
+ BASE_SEPOLIA: "BASE_SEPOLIA";
77
+ CHIADO: "CHIADO";
78
+ FUJI: "FUJI";
79
+ OPTIMISM_SEPOLIA: "OPTIMISM_SEPOLIA";
80
+ SEPOLIA: "SEPOLIA";
81
+ }>;
82
+ contractAddress: z.ZodString;
83
+ }, z.core.$strip>;
84
+ declare const getDecimalsOutputSchema: z.ZodObject<{
85
+ decimals: z.ZodNumber;
86
+ }, z.core.$strip>;
87
+ interface GetDecimalsInput extends z.infer<typeof getDecimalsInputSchema> {
88
+ }
89
+ type GetDecimalsOutput = z.infer<typeof getDecimalsOutputSchema>;
90
+
67
91
  declare const MAINNET_CHAIN_TYPE: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM"];
68
92
  declare const TESTNET_CHAIN_TYPE: readonly ["ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
69
93
  declare const chainSchema: z.ZodEnum<{
@@ -151,5 +175,5 @@ type SyncAddressOutput = z.infer<typeof syncAddressOutputSchema>;
151
175
 
152
176
  declare const tables: typeof schema;
153
177
 
154
- export { MAINNET_CHAIN_TYPE as M, TESTNET_CHAIN_TYPE as T, chainSchema as e, getBlockOutputSchema as f, getBlockInputSchema as g, getTransactionInputSchema as h, getTransactionOutputSchema as i, syncAddressOutputSchema as j, syncAddressInputSchema as s, tables as t };
155
- export type { Chain as C, GetTransactionInput as G, SyncAddressInput as S, SyncAddressOutput as a, GetTransactionOutput as b, GetBlockInput as c, GetBlockOutput as d };
178
+ export { MAINNET_CHAIN_TYPE as M, TESTNET_CHAIN_TYPE as T, chainSchema as g, getBlockInputSchema as h, getBlockOutputSchema as i, getDecimalsInputSchema as j, getDecimalsOutputSchema as k, getTransactionInputSchema as l, getTransactionOutputSchema as m, syncAddressOutputSchema as n, syncAddressInputSchema as s, tables as t };
179
+ export type { Chain as C, GetTransactionInput as G, SyncAddressInput as S, SyncAddressOutput as a, GetTransactionOutput as b, GetDecimalsInput as c, GetDecimalsOutput as d, GetBlockInput as e, GetBlockOutput as f };
@@ -1,6 +1,6 @@
1
1
  import { base } from '@develit-io/backend-sdk';
2
2
  import { sqliteTable, text, integer, blob, uniqueIndex } from 'drizzle-orm/sqlite-core';
3
- import { a as CREDENTIALS_TYPES, C as CHAIN_KEYS } from './blockchain.c19XIse8.mjs';
3
+ import { a as CREDENTIALS_TYPES, C as CHAIN_KEYS } from './blockchain.BsFFrNF0.mjs';
4
4
 
5
5
  const address = sqliteTable("address", {
6
6
  ...base,
@@ -2,7 +2,7 @@
2
2
 
3
3
  const backendSdk = require('@develit-io/backend-sdk');
4
4
  const sqliteCore = require('drizzle-orm/sqlite-core');
5
- const syncAddress = require('./blockchain.C5pjxssf.cjs');
5
+ const address$1 = require('./blockchain.BVya3Mud.cjs');
6
6
 
7
7
  const address = sqliteCore.sqliteTable("address", {
8
8
  ...backendSdk.base,
@@ -20,10 +20,10 @@ const addressCredentials = sqliteCore.sqliteTable("address_credentials", {
20
20
  ...backendSdk.base,
21
21
  addressId: sqliteCore.text("address_id").references(() => address.id, { onDelete: "restrict", onUpdate: "cascade" }).notNull(),
22
22
  connector: sqliteCore.text("connector", {
23
- enum: syncAddress.CHAIN_KEYS
23
+ enum: address$1.CHAIN_KEYS
24
24
  }).$type().notNull(),
25
25
  type: sqliteCore.text("type", {
26
- enum: syncAddress.CREDENTIALS_TYPES
26
+ enum: address$1.CREDENTIALS_TYPES
27
27
  }).$type().notNull(),
28
28
  value: sqliteCore.text("value").notNull(),
29
29
  expiresAt: sqliteCore.integer("expires_at", { mode: "timestamp_ms" })
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- import { s as schema } from './blockchain.CyyZn6RX.cjs';
2
+ import { s as schema } from './blockchain.BioJdfy8.cjs';
3
3
 
4
4
  declare const getBlockInputSchema: z.ZodObject<{
5
5
  chain: z.ZodEnum<{
@@ -64,6 +64,30 @@ interface GetBlockInput extends z.infer<typeof getBlockInputSchema> {
64
64
  }
65
65
  type GetBlockOutput = z.infer<typeof getBlockOutputSchema>;
66
66
 
67
+ declare const getDecimalsInputSchema: z.ZodObject<{
68
+ chain: z.ZodEnum<{
69
+ ARBITRUM: "ARBITRUM";
70
+ AVALANCHE: "AVALANCHE";
71
+ BASE: "BASE";
72
+ ETHEREUM: "ETHEREUM";
73
+ GNOSIS: "GNOSIS";
74
+ OPTIMISM: "OPTIMISM";
75
+ ARBITRUM_SEPOLIA: "ARBITRUM_SEPOLIA";
76
+ BASE_SEPOLIA: "BASE_SEPOLIA";
77
+ CHIADO: "CHIADO";
78
+ FUJI: "FUJI";
79
+ OPTIMISM_SEPOLIA: "OPTIMISM_SEPOLIA";
80
+ SEPOLIA: "SEPOLIA";
81
+ }>;
82
+ contractAddress: z.ZodString;
83
+ }, z.core.$strip>;
84
+ declare const getDecimalsOutputSchema: z.ZodObject<{
85
+ decimals: z.ZodNumber;
86
+ }, z.core.$strip>;
87
+ interface GetDecimalsInput extends z.infer<typeof getDecimalsInputSchema> {
88
+ }
89
+ type GetDecimalsOutput = z.infer<typeof getDecimalsOutputSchema>;
90
+
67
91
  declare const MAINNET_CHAIN_TYPE: readonly ["ARBITRUM", "AVALANCHE", "BASE", "ETHEREUM", "GNOSIS", "OPTIMISM"];
68
92
  declare const TESTNET_CHAIN_TYPE: readonly ["ARBITRUM_SEPOLIA", "BASE_SEPOLIA", "CHIADO", "FUJI", "OPTIMISM_SEPOLIA", "SEPOLIA"];
69
93
  declare const chainSchema: z.ZodEnum<{
@@ -151,5 +175,5 @@ type SyncAddressOutput = z.infer<typeof syncAddressOutputSchema>;
151
175
 
152
176
  declare const tables: typeof schema;
153
177
 
154
- export { MAINNET_CHAIN_TYPE as M, TESTNET_CHAIN_TYPE as T, chainSchema as e, getBlockOutputSchema as f, getBlockInputSchema as g, getTransactionInputSchema as h, getTransactionOutputSchema as i, syncAddressOutputSchema as j, syncAddressInputSchema as s, tables as t };
155
- export type { Chain as C, GetTransactionInput as G, SyncAddressInput as S, SyncAddressOutput as a, GetTransactionOutput as b, GetBlockInput as c, GetBlockOutput as d };
178
+ export { MAINNET_CHAIN_TYPE as M, TESTNET_CHAIN_TYPE as T, chainSchema as g, getBlockInputSchema as h, getBlockOutputSchema as i, getDecimalsInputSchema as j, getDecimalsOutputSchema as k, getTransactionInputSchema as l, getTransactionOutputSchema as m, syncAddressOutputSchema as n, syncAddressInputSchema as s, tables as t };
179
+ export type { Chain as C, GetTransactionInput as G, SyncAddressInput as S, SyncAddressOutput as a, GetTransactionOutput as b, GetDecimalsInput as c, GetDecimalsOutput as d, GetBlockInput as e, GetBlockOutput as f };
package/dist/types.cjs CHANGED
@@ -1,19 +1,21 @@
1
1
  'use strict';
2
2
 
3
- const syncAddress = require('./shared/blockchain.C5pjxssf.cjs');
3
+ const address = require('./shared/blockchain.BVya3Mud.cjs');
4
4
  require('zod');
5
5
  require('@develit-io/backend-sdk');
6
6
 
7
7
 
8
8
 
9
- exports.CHAIN_KEYS = syncAddress.CHAIN_KEYS;
10
- exports.CREDENTIALS_TYPES = syncAddress.CREDENTIALS_TYPES;
11
- exports.MAINNET_CHAIN_TYPE = syncAddress.MAINNET_CHAIN_TYPE;
12
- exports.TESTNET_CHAIN_TYPE = syncAddress.TESTNET_CHAIN_TYPE;
13
- exports.chainSchema = syncAddress.chainSchema;
14
- exports.getBlockInputSchema = syncAddress.getBlockInputSchema;
15
- exports.getBlockOutputSchema = syncAddress.getBlockOutputSchema;
16
- exports.getTransactionInputSchema = syncAddress.getTransactionInputSchema;
17
- exports.getTransactionOutputSchema = syncAddress.getTransactionOutputSchema;
18
- exports.syncAddressInputSchema = syncAddress.syncAddressInputSchema;
19
- exports.syncAddressOutputSchema = syncAddress.syncAddressOutputSchema;
9
+ exports.CHAIN_KEYS = address.CHAIN_KEYS;
10
+ exports.CREDENTIALS_TYPES = address.CREDENTIALS_TYPES;
11
+ exports.MAINNET_CHAIN_TYPE = address.MAINNET_CHAIN_TYPE;
12
+ exports.TESTNET_CHAIN_TYPE = address.TESTNET_CHAIN_TYPE;
13
+ exports.chainSchema = address.chainSchema;
14
+ exports.getBlockInputSchema = address.getBlockInputSchema;
15
+ exports.getBlockOutputSchema = address.getBlockOutputSchema;
16
+ exports.getDecimalsInputSchema = address.getDecimalsInputSchema;
17
+ exports.getDecimalsOutputSchema = address.getDecimalsOutputSchema;
18
+ exports.getTransactionInputSchema = address.getTransactionInputSchema;
19
+ exports.getTransactionOutputSchema = address.getTransactionOutputSchema;
20
+ exports.syncAddressInputSchema = address.syncAddressInputSchema;
21
+ exports.syncAddressOutputSchema = address.syncAddressOutputSchema;
package/dist/types.d.cts CHANGED
@@ -1,7 +1,7 @@
1
- export { C as CHAIN_KEYS, a as CREDENTIALS_TYPES, b as CredentialsType, L as LastSyncMetadata } from './shared/blockchain.CyyZn6RX.cjs';
1
+ export { C as CHAIN_KEYS, a as CREDENTIALS_TYPES, b as CredentialsType, L as LastSyncMetadata } from './shared/blockchain.BioJdfy8.cjs';
2
2
  import { BaseEvent } from '@develit-io/backend-sdk';
3
- import { t as tables } from './shared/blockchain.CeVkeCGH.cjs';
4
- export { C as Chain, c as GetBlockInput, d as GetBlockOutput, G as GetTransactionInput, b as GetTransactionOutput, M as MAINNET_CHAIN_TYPE, S as SyncAddressInput, a as SyncAddressOutput, T as TESTNET_CHAIN_TYPE, e as chainSchema, g as getBlockInputSchema, f as getBlockOutputSchema, h as getTransactionInputSchema, i as getTransactionOutputSchema, s as syncAddressInputSchema, j as syncAddressOutputSchema } from './shared/blockchain.CeVkeCGH.cjs';
3
+ import { t as tables } from './shared/blockchain.Z_R-J9qs.cjs';
4
+ export { C as Chain, e as GetBlockInput, f as GetBlockOutput, c as GetDecimalsInput, d as GetDecimalsOutput, G as GetTransactionInput, b as GetTransactionOutput, M as MAINNET_CHAIN_TYPE, S as SyncAddressInput, a as SyncAddressOutput, T as TESTNET_CHAIN_TYPE, g as chainSchema, h as getBlockInputSchema, i as getBlockOutputSchema, j as getDecimalsInputSchema, k as getDecimalsOutputSchema, l as getTransactionInputSchema, m as getTransactionOutputSchema, s as syncAddressInputSchema, n as syncAddressOutputSchema } from './shared/blockchain.Z_R-J9qs.cjs';
5
5
  import { InferInsertModel, InferSelectModel } from 'drizzle-orm';
6
6
  export { a as BlockchainServiceEnv, b as BlockchainServiceEnvironmentConfig, B as BlockchainServiceWranglerConfig } from './shared/blockchain.CVKUvfyj.cjs';
7
7
  import 'drizzle-orm/sqlite-core';
package/dist/types.d.mts CHANGED
@@ -1,7 +1,7 @@
1
- export { C as CHAIN_KEYS, a as CREDENTIALS_TYPES, b as CredentialsType, L as LastSyncMetadata } from './shared/blockchain.CyyZn6RX.mjs';
1
+ export { C as CHAIN_KEYS, a as CREDENTIALS_TYPES, b as CredentialsType, L as LastSyncMetadata } from './shared/blockchain.BioJdfy8.mjs';
2
2
  import { BaseEvent } from '@develit-io/backend-sdk';
3
- import { t as tables } from './shared/blockchain.DNPZEckN.mjs';
4
- export { C as Chain, c as GetBlockInput, d as GetBlockOutput, G as GetTransactionInput, b as GetTransactionOutput, M as MAINNET_CHAIN_TYPE, S as SyncAddressInput, a as SyncAddressOutput, T as TESTNET_CHAIN_TYPE, e as chainSchema, g as getBlockInputSchema, f as getBlockOutputSchema, h as getTransactionInputSchema, i as getTransactionOutputSchema, s as syncAddressInputSchema, j as syncAddressOutputSchema } from './shared/blockchain.DNPZEckN.mjs';
3
+ import { t as tables } from './shared/blockchain.C8acDQuh.mjs';
4
+ export { C as Chain, e as GetBlockInput, f as GetBlockOutput, c as GetDecimalsInput, d as GetDecimalsOutput, G as GetTransactionInput, b as GetTransactionOutput, M as MAINNET_CHAIN_TYPE, S as SyncAddressInput, a as SyncAddressOutput, T as TESTNET_CHAIN_TYPE, g as chainSchema, h as getBlockInputSchema, i as getBlockOutputSchema, j as getDecimalsInputSchema, k as getDecimalsOutputSchema, l as getTransactionInputSchema, m as getTransactionOutputSchema, s as syncAddressInputSchema, n as syncAddressOutputSchema } from './shared/blockchain.C8acDQuh.mjs';
5
5
  import { InferInsertModel, InferSelectModel } from 'drizzle-orm';
6
6
  export { a as BlockchainServiceEnv, b as BlockchainServiceEnvironmentConfig, B as BlockchainServiceWranglerConfig } from './shared/blockchain.CVKUvfyj.mjs';
7
7
  import 'drizzle-orm/sqlite-core';
package/dist/types.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- export { C as CHAIN_KEYS, a as CREDENTIALS_TYPES, b as CredentialsType, L as LastSyncMetadata } from './shared/blockchain.CyyZn6RX.js';
1
+ export { C as CHAIN_KEYS, a as CREDENTIALS_TYPES, b as CredentialsType, L as LastSyncMetadata } from './shared/blockchain.BioJdfy8.js';
2
2
  import { BaseEvent } from '@develit-io/backend-sdk';
3
- import { t as tables } from './shared/blockchain.Bh6x4dsx.js';
4
- export { C as Chain, c as GetBlockInput, d as GetBlockOutput, G as GetTransactionInput, b as GetTransactionOutput, M as MAINNET_CHAIN_TYPE, S as SyncAddressInput, a as SyncAddressOutput, T as TESTNET_CHAIN_TYPE, e as chainSchema, g as getBlockInputSchema, f as getBlockOutputSchema, h as getTransactionInputSchema, i as getTransactionOutputSchema, s as syncAddressInputSchema, j as syncAddressOutputSchema } from './shared/blockchain.Bh6x4dsx.js';
3
+ import { t as tables } from './shared/blockchain.BL2AlFRD.js';
4
+ export { C as Chain, e as GetBlockInput, f as GetBlockOutput, c as GetDecimalsInput, d as GetDecimalsOutput, G as GetTransactionInput, b as GetTransactionOutput, M as MAINNET_CHAIN_TYPE, S as SyncAddressInput, a as SyncAddressOutput, T as TESTNET_CHAIN_TYPE, g as chainSchema, h as getBlockInputSchema, i as getBlockOutputSchema, j as getDecimalsInputSchema, k as getDecimalsOutputSchema, l as getTransactionInputSchema, m as getTransactionOutputSchema, s as syncAddressInputSchema, n as syncAddressOutputSchema } from './shared/blockchain.BL2AlFRD.js';
5
5
  import { InferInsertModel, InferSelectModel } from 'drizzle-orm';
6
6
  export { a as BlockchainServiceEnv, b as BlockchainServiceEnvironmentConfig, B as BlockchainServiceWranglerConfig } from './shared/blockchain.CVKUvfyj.js';
7
7
  import 'drizzle-orm/sqlite-core';
package/dist/types.mjs CHANGED
@@ -1,3 +1,3 @@
1
- export { C as CHAIN_KEYS, a as CREDENTIALS_TYPES, M as MAINNET_CHAIN_TYPE, T as TESTNET_CHAIN_TYPE, c as chainSchema, g as getBlockInputSchema, b as getBlockOutputSchema, d as getTransactionInputSchema, e as getTransactionOutputSchema, s as syncAddressInputSchema, f as syncAddressOutputSchema } from './shared/blockchain.c19XIse8.mjs';
1
+ export { C as CHAIN_KEYS, a as CREDENTIALS_TYPES, M as MAINNET_CHAIN_TYPE, T as TESTNET_CHAIN_TYPE, c as chainSchema, g as getBlockInputSchema, b as getBlockOutputSchema, d as getDecimalsInputSchema, e as getDecimalsOutputSchema, f as getTransactionInputSchema, h as getTransactionOutputSchema, s as syncAddressInputSchema, i as syncAddressOutputSchema } from './shared/blockchain.BsFFrNF0.mjs';
2
2
  import 'zod';
3
3
  import '@develit-io/backend-sdk';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@develit-services/blockchain",
3
- "version": "0.11.0",
3
+ "version": "0.12.0",
4
4
  "author": "Develit.io s.r.o.",
5
5
  "type": "module",
6
6
  "exports": {