@odatano/core 2.0.0-rc.44 → 2.0.0-rc.46

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 (168) hide show
  1. package/@cds-models/CardanoAgentService/index.d.ts +0 -46
  2. package/@cds-models/CardanoBackendService/index.d.ts +0 -10
  3. package/@cds-models/CardanoIndexerService/index.d.ts +5 -20
  4. package/@cds-models/CardanoODataService/index.d.ts +18 -47
  5. package/@cds-models/CardanoSignService/index.d.ts +3 -18
  6. package/@cds-models/CardanoTransactionService/index.d.ts +9 -31
  7. package/@cds-models/CardanoWorkerService/index.d.ts +3 -19
  8. package/@cds-models/index.d.ts +17 -0
  9. package/@cds-models/index.js +2 -0
  10. package/@cds-models/odatano/cardano/index.d.ts +0 -34
  11. package/README.md +20 -20
  12. package/db/schema.cds +25 -44
  13. package/db/types.cds +22 -5
  14. package/package.json +3 -1
  15. package/scripts/migrate-slot-leader.mjs +3 -11
  16. package/scripts/migrate-txseq.mjs +3 -12
  17. package/src/index.d.ts +0 -4
  18. package/src/index.js +3 -5
  19. package/src/plugin.js +4 -8
  20. package/srv/blockchain/asset-decimals.d.ts +0 -9
  21. package/srv/blockchain/asset-decimals.js +21 -16
  22. package/srv/blockchain/backends/blockfrost-backend.d.ts +2 -10
  23. package/srv/blockchain/backends/blockfrost-backend.js +15 -21
  24. package/srv/blockchain/backends/cardano-backend.d.ts +12 -71
  25. package/srv/blockchain/backends/koios-backend.d.ts +14 -147
  26. package/srv/blockchain/backends/koios-backend.js +43 -166
  27. package/srv/blockchain/backends/odatano-backend.d.ts +1 -11
  28. package/srv/blockchain/backends/odatano-backend.js +11 -12
  29. package/srv/blockchain/backends/ogmios-backend.d.ts +19 -160
  30. package/srv/blockchain/backends/ogmios-backend.js +96 -175
  31. package/srv/blockchain/backends/ogmios-frame-guard.d.ts +2 -18
  32. package/srv/blockchain/backends/ogmios-frame-guard.js +8 -20
  33. package/srv/blockchain/cardano-client.d.ts +12 -80
  34. package/srv/blockchain/cardano-client.js +36 -88
  35. package/srv/blockchain/cardano-indexer.d.ts +14 -192
  36. package/srv/blockchain/cardano-indexer.js +136 -222
  37. package/srv/blockchain/cardano-tx-builder.d.ts +1 -28
  38. package/srv/blockchain/cardano-tx-builder.js +17 -34
  39. package/srv/blockchain/circuit-breaker.d.ts +1 -13
  40. package/srv/blockchain/circuit-breaker.js +5 -15
  41. package/srv/blockchain/crawler/asset-decimals-backfill.d.ts +0 -5
  42. package/srv/blockchain/crawler/asset-decimals-backfill.js +2 -5
  43. package/srv/blockchain/crawler/certificate-backfill.d.ts +0 -17
  44. package/srv/blockchain/crawler/certificate-backfill.js +8 -22
  45. package/srv/blockchain/crawler/crawler.d.ts +16 -93
  46. package/srv/blockchain/crawler/crawler.js +85 -160
  47. package/srv/blockchain/crawler/credential-backfill.d.ts +0 -10
  48. package/srv/blockchain/crawler/credential-backfill.js +2 -4
  49. package/srv/blockchain/crawler/hooks.d.ts +1 -5
  50. package/srv/blockchain/crawler/index.d.ts +0 -12
  51. package/srv/blockchain/crawler/index.js +6 -20
  52. package/srv/blockchain/crawler/sync-state.d.ts +6 -44
  53. package/srv/blockchain/crawler/sync-state.js +18 -53
  54. package/srv/blockchain/crawler/transaction-backfill.d.ts +0 -11
  55. package/srv/blockchain/crawler/transaction-backfill.js +11 -30
  56. package/srv/blockchain/crawler/utxo-set-import.d.ts +1 -30
  57. package/srv/blockchain/crawler/utxo-set-import.js +27 -53
  58. package/srv/blockchain/ledger-state.d.ts +10 -54
  59. package/srv/blockchain/ledger-state.js +11 -27
  60. package/srv/blockchain/pending-spends.d.ts +0 -12
  61. package/srv/blockchain/pending-spends.js +4 -12
  62. package/srv/blockchain/request-coalescer.d.ts +2 -16
  63. package/srv/blockchain/request-coalescer.js +2 -16
  64. package/srv/blockchain/signing/cose-verifier.d.ts +0 -9
  65. package/srv/blockchain/signing/cose-verifier.js +4 -10
  66. package/srv/blockchain/signing/external-signer.d.ts +1 -4
  67. package/srv/blockchain/signing/external-signer.js +2 -8
  68. package/srv/blockchain/signing/hsm-signer.d.ts +6 -18
  69. package/srv/blockchain/signing/hsm-signer.js +16 -28
  70. package/srv/blockchain/signing/signature-verifier.d.ts +1 -8
  71. package/srv/blockchain/signing/signature-verifier.js +9 -19
  72. package/srv/blockchain/signing/submission-finalizer.d.ts +10 -16
  73. package/srv/blockchain/signing/submission-finalizer.js +53 -19
  74. package/srv/blockchain/stored-chain.d.ts +1 -14
  75. package/srv/blockchain/stored-chain.js +3 -8
  76. package/srv/blockchain/transaction-building/buildooor-fee-patch.d.ts +0 -4
  77. package/srv/blockchain/transaction-building/buildooor-fee-patch.js +4 -9
  78. package/srv/blockchain/transaction-building/buildooor-tx.d.ts +7 -150
  79. package/srv/blockchain/transaction-building/buildooor-tx.js +91 -196
  80. package/srv/blockchain/transaction-building/caller-datums.d.ts +0 -14
  81. package/srv/blockchain/transaction-building/caller-datums.js +3 -9
  82. package/srv/blockchain/transaction-building/cardano-tx.d.ts +1 -4
  83. package/srv/blockchain/wallet-worker/build-request.d.ts +0 -5
  84. package/srv/blockchain/wallet-worker/build-request.js +6 -9
  85. package/srv/blockchain/wallet-worker/confirmation-tracker.d.ts +5 -23
  86. package/srv/blockchain/wallet-worker/confirmation-tracker.js +16 -20
  87. package/srv/blockchain/wallet-worker/index.d.ts +1 -1
  88. package/srv/blockchain/wallet-worker/index.js +3 -5
  89. package/srv/blockchain/wallet-worker/job-store.d.ts +15 -65
  90. package/srv/blockchain/wallet-worker/job-store.js +0 -0
  91. package/srv/blockchain/wallet-worker/lease-heartbeat.d.ts +2 -10
  92. package/srv/blockchain/wallet-worker/lease-heartbeat.js +6 -12
  93. package/srv/blockchain/wallet-worker/signers.d.ts +3 -11
  94. package/srv/blockchain/wallet-worker/signers.js +3 -6
  95. package/srv/blockchain/wallet-worker/wallet-worker.d.ts +3 -21
  96. package/srv/blockchain/wallet-worker/wallet-worker.js +47 -54
  97. package/srv/cardano-agent-service.cds +123 -146
  98. package/srv/cardano-agent-service.js +2 -5
  99. package/srv/cardano-backend-service.cds +10 -17
  100. package/srv/cardano-backend-service.js +7 -12
  101. package/srv/cardano-indexer-service.cds +16 -37
  102. package/srv/cardano-indexer-service.d.ts +5 -1
  103. package/srv/cardano-indexer-service.js +44 -35
  104. package/srv/cardano-service.cds +56 -40
  105. package/srv/cardano-service.js +42 -69
  106. package/srv/cardano-sign-service.cds +14 -23
  107. package/srv/cardano-sign-service.js +18 -24
  108. package/srv/cardano-tx-service.cds +27 -29
  109. package/srv/cardano-tx-service.js +60 -122
  110. package/srv/cardano-worker-service.cds +109 -125
  111. package/srv/cardano-worker-service.js +21 -31
  112. package/srv/cbor/cip68.d.ts +0 -4
  113. package/srv/cbor/cip68.js +2 -4
  114. package/srv/cbor/parse.d.ts +3 -18
  115. package/srv/cbor/parse.js +2 -7
  116. package/srv/cbor/plutus-data-json.d.ts +0 -4
  117. package/srv/server.d.ts +5 -36
  118. package/srv/server.js +30 -51
  119. package/srv/utils/agent-grants-config.d.ts +0 -18
  120. package/srv/utils/agent-grants-config.js +6 -13
  121. package/srv/utils/agent-grants.d.ts +14 -68
  122. package/srv/utils/agent-grants.js +42 -60
  123. package/srv/utils/agent-token-auth.d.ts +0 -5
  124. package/srv/utils/agent-token-auth.js +2 -5
  125. package/srv/utils/backend-request-handler.d.ts +1 -1
  126. package/srv/utils/collections.d.ts +1 -4
  127. package/srv/utils/collections.js +1 -4
  128. package/srv/utils/const.d.ts +0 -18
  129. package/srv/utils/const.js +7 -18
  130. package/srv/utils/crypto.js +3 -5
  131. package/srv/utils/db-indexes.d.ts +2 -0
  132. package/srv/utils/db-indexes.js +22 -9
  133. package/srv/utils/db-sanitize.d.ts +1 -8
  134. package/srv/utils/db-sanitize.js +3 -8
  135. package/srv/utils/epoch-slots.d.ts +1 -8
  136. package/srv/utils/epoch-slots.js +3 -8
  137. package/srv/utils/error-codes.d.ts +0 -4
  138. package/srv/utils/error-codes.js +2 -4
  139. package/srv/utils/errors.d.ts +2 -22
  140. package/srv/utils/errors.js +13 -27
  141. package/srv/utils/liveness.d.ts +0 -4
  142. package/srv/utils/liveness.js +2 -4
  143. package/srv/utils/mappers.d.ts +0 -37
  144. package/srv/utils/mappers.js +19 -39
  145. package/srv/utils/network-context.js +2 -4
  146. package/srv/utils/paging.d.ts +31 -0
  147. package/srv/utils/paging.js +43 -0
  148. package/srv/utils/pg-inline-json.js +3 -7
  149. package/srv/utils/pg-order-nulls.js +2 -5
  150. package/srv/utils/plutus-placeholders.d.ts +0 -13
  151. package/srv/utils/plutus-placeholders.js +6 -13
  152. package/srv/utils/rate-limiter.d.ts +0 -8
  153. package/srv/utils/rate-limiter.js +2 -4
  154. package/srv/utils/reference-script.d.ts +0 -18
  155. package/srv/utils/reference-script.js +8 -19
  156. package/srv/utils/service-events.d.ts +0 -4
  157. package/srv/utils/service-events.js +2 -4
  158. package/srv/utils/signing-helper.d.ts +1 -8
  159. package/srv/utils/signing-helper.js +3 -8
  160. package/srv/utils/tx-build-helper.d.ts +2 -32
  161. package/srv/utils/tx-build-helper.js +26 -40
  162. package/srv/utils/tx-request-parsers.d.ts +1 -25
  163. package/srv/utils/tx-request-parsers.js +10 -25
  164. package/srv/utils/tx-utils.d.ts +0 -8
  165. package/srv/utils/tx-utils.js +10 -13
  166. package/srv/utils/types.d.ts +2 -37
  167. package/srv/utils/validators.d.ts +0 -4
  168. package/srv/utils/validators.js +2 -4
@@ -28,10 +28,7 @@ export declare function ogmiosScriptHash(script: unknown): string | null;
28
28
  export declare function ogmiosPlutusScriptCbor(script: unknown): string | null;
29
29
  /** Bech32 pool id of a block issuer: blake2b-224 of its cold verification key. */
30
30
  export declare function issuerKeyToPoolId(verificationKeyHex: string): string;
31
- /**
32
- * Ogmios v6 `queryLedgerState/delegateRepresentatives` summary (local wire type; the schema
33
- * package is only a transitive dependency). Only the `registered` variant carries an id.
34
- */
31
+ /** Ogmios `queryLedgerState/delegateRepresentatives` entry. Only the `registered` variant has an id. */
35
32
  interface OgmiosDrepSummary {
36
33
  type: 'registered' | 'noConfidence' | 'abstain';
37
34
  id?: string;
@@ -51,7 +48,7 @@ interface OgmiosDrepSummary {
51
48
  };
52
49
  delegators?: unknown[];
53
50
  }
54
- /** Ogmios `stakePoolsPerformances`: only nOpt is used — its stake figures are live, not active. */
51
+ /** Ogmios `stakePoolsPerformances`. Only nOpt is used, because its stake figures are live, not active. */
55
52
  interface OgmiosStakePoolsPerformances {
56
53
  desiredNumberOfStakePools?: number;
57
54
  }
@@ -74,17 +71,7 @@ export interface OgmiosEpochStateRaw {
74
71
  };
75
72
  } | null;
76
73
  }
77
- /**
78
- * Ogmios ledger answers -> EpochLedgerState. Saturation follows the ledger: live stake over
79
- * (max supply - reserves) / nOpt. Figures the ledger view does not carry stay 0 / null: active
80
- * stake (the indexer derives it from the previous snapshot), block counts, delegator counts,
81
- * DRep last activity.
82
- */
83
74
  export declare function mapOgmiosEpochState(raw: OgmiosEpochStateRaw): EpochLedgerState;
84
- /**
85
- * Decode a CIP-129 DRep ID (`drep1…`, 29 bytes) into credential hash and type. Header byte:
86
- * high nibble 0x2 = DRep, low nibble 0x2 = key hash / 0x3 = script hash.
87
- */
88
75
  export declare function decodeDrepId(drepId: string): {
89
76
  hashHex: string;
90
77
  isScript: boolean;
@@ -102,10 +89,7 @@ export declare function resolveOgmiosHeight(height: 'origin' | number): number;
102
89
  /** CardanoBackend implementation over an Ogmios WebSocket (local node). */
103
90
  export declare class OgmiosBackend implements EvaluatingBackend, ChainSyncBackend, LedgerStateBackend, EpochStateBackend {
104
91
  readonly name = "ogmios";
105
- /**
106
- * Capability declaration — the orchestrator skips Ogmios for these without counting
107
- * circuit failures. Historic queries are out of protocol scope.
108
- */
92
+ /** Ogmios cannot answer historic queries. The orchestrator skips it for these. */
109
93
  readonly unsupportedMethods: ReadonlySet<string>;
110
94
  private stateQueryClient;
111
95
  private txSubmissionClient;
@@ -120,157 +104,55 @@ export declare class OgmiosBackend implements EvaluatingBackend, ChainSyncBacken
120
104
  private timeoutMs;
121
105
  private ogmiosUrl;
122
106
  constructor(network: Network, timeoutMs: number, ogmiosUrl: string);
123
- /**
124
- * Force non-keep-alive HTTP for the Ogmios `/health` probe: node-fetch v2 uses `http.globalAgent`,
125
- * whose pooled sockets (kept alive since Node 19) fail with "Premature close" once Ogmios' Warp server
126
- * half-closes them. No agent hook exists, so keep-alive is disabled process-wide for `http://` only.
127
- */
128
107
  private static keepAliveDisabled;
129
108
  private static disableHttpKeepAlive;
130
109
  /** Validate Ogmios URL scheme and reject dangerous protocols */
131
110
  private static validateOgmiosUrl;
132
- /**
133
- * Bound an init step in time: the WebSocket connect/handshake has no built-in timeout and
134
- * can hang when the node is busy. The rejection message contains "timeout" so the
135
- * orchestrator's transient-error retry picks it up.
136
- */
137
111
  private withInitTimeout;
138
- /**
139
- * Force-release an interaction socket after a failed/expired open or close. The runtime
140
- * socket is `ws` (has `terminate`); the `close` fallback keeps test doubles working.
141
- */
112
+ /** Force-release a socket after a failed open or close. Test doubles without `terminate` get `close`. */
142
113
  private forceCloseContext;
143
114
  /** Open the interaction context and the query/submission clients. */
144
115
  init(): Promise<boolean>;
145
- /**
146
- * Query client for address queries. The node answers them by scanning its whole UTxO set (seconds
147
- * each), and Ogmios serves the queries of one connection in order; on their own connection they no
148
- * longer hold up tip, epoch and protocol parameters. Opened on first use, reopened after a close.
149
- */
150
116
  private scanQueryClient;
151
- /**
152
- * Reconnect when the WebSocket died since the last init. No-op when never initialized
153
- * (test-injected clients); concurrent callers share one reconnect attempt.
154
- */
117
+ /** Reconnect a dead WebSocket. Concurrent callers share one attempt. No-op before the first init. */
155
118
  private ensureConnected;
156
- /**
157
- * Get specific Block Data (not supported)
158
- * @param _hash block hash (hex)
159
- * @returns {Promise<BlockData>} block data
160
- */
161
119
  getBlock(_hash: string): Promise<BlockData>;
162
- /**
163
- * Get specific Epoch Data (not supported)
164
- * @param _epochNumber epoch number
165
- * @returns {Promise<EpochData>} epoch data
166
- */
120
+ /** Only the current epoch. */
167
121
  getEpoch(epochNumber: number): Promise<EpochData>;
168
- /**
169
- * Get specific Transaction Data (not supported)
170
- * @param _hash transaction hash (hex)
171
- * @returns {Promise<Transaction>} transaction data
172
- */
173
122
  getTransaction(_hash: string): Promise<Transaction>;
174
- /**
175
- * Get specific Transaction Metadata (not supported)
176
- * @param _tx_hash transaction hash (hex)
177
- * @returns {Promise<MetadataLabelTx[]>} transaction metadata list
178
- */
179
123
  getTransactionMetadata(_tx_hash: string): Promise<MetadataLabelTx[]>;
180
- /**
181
- * DRep data from the live ledger state (`queryLedgerState/delegateRepresentatives`) via the
182
- * raw `Method()` primitive, since the client ships no wrapper. Ogmios lists only REGISTERED
183
- * DReps: retired/unknown → NotFoundError; `expired` is derived from the mandate epoch.
184
- * @param drepId CIP-129 bech32 DRep ID (`drep1…`)
185
- */
186
124
  getDrep(drepId: string): Promise<DrepData>;
187
- /**
188
- * Get Asset Info (not supported for Ogmios — no aggregate-supply query in the protocol)
189
- * @param _unit asset unit (policyId + assetNameHex)
190
- * @returns {Promise<AssetInfo>} asset info
191
- */
125
+ /** Not supported. The protocol has no aggregate-supply query. */
192
126
  getAssetInfo(_unit: string): Promise<AssetInfo>;
193
- /**
194
- * Supply figures from `queryLedgerState/treasuryAndReserves`: total = max − reserves.
195
- * Circulating, locked and stake totals are not in the ledger state and stay '0'.
196
- */
127
+ /** Total supply is max supply minus reserves. Circulating, locked and stake totals stay '0'. */
197
128
  getNetworkInformation(): Promise<NetworkInformation>;
198
- /**
199
- * Address at the tip: type, script flag and stake address decoded from the address itself,
200
- * UTxOs from the ledger, balance summed over them. No transaction history (getAddressTransactions).
201
- */
129
+ /** Address at the tip, decoded locally, with UTxOs and balance from the ledger. No tx history. */
202
130
  getAddress(address: string): Promise<Address>;
203
- /** get current specific Address UTxOs
204
- * @param address bech32 address
205
- * @returns {Promise<UTxO[]>} address UTxOs
206
- */
207
131
  getAddressUtxos(address: string): Promise<UTxO[]>;
208
132
  /** Ogmios `Utxo` entry → normalized UTxO line (shared by the address query and the set import). */
209
133
  private mapOgmiosUtxo;
210
- /**
211
- * Run `fn` against the ledger state acquired at `point` on a SEPARATE WebSocket: local-state-query
212
- * holds one acquired point per connection, so the shared socket would pin live queries to the past.
213
- * The point must be inside the node's volatile window (k blocks) or acquisition is refused.
214
- */
215
134
  private withLedgerStateAt;
216
135
  /** Whole UTxO set as of `point` (crawler snapshot import). */
217
136
  queryUtxoSetAt(point: ChainPoint): Promise<UTxO[]>;
218
- /**
219
- * Pools, DReps and pots as of `point` (crawler epoch snapshot), all read from one acquired
220
- * ledger state. Performances are optional: without them (no nOpt) saturation stays 0.
221
- */
137
+ /** Pools, DReps and pots at `point` from one ledger state. Without nOpt saturation stays 0. */
222
138
  epochStateAt(point: ChainPoint): Promise<EpochLedgerState>;
223
- /** Not supported — Ogmios is a live state-query backend; use Blockfrost/Koios. */
139
+ /** Not supported. Ogmios only queries live state. */
224
140
  getAddressTransactions(_address: string): Promise<Transaction[]>;
225
- /**
226
- * Get current specific Pool Data
227
- * @param poolId pool id
228
- * @returns {Promise<PoolData>} pool data
229
- */
230
141
  getPool(poolId: string): Promise<PoolData>;
231
- /**
232
- * Get Account Data for specified stake address
233
- * @param stakeAddress stake address
234
- * @returns {Promise<AccountData>} account data
235
- */
236
142
  getAccount(stakeAddress: string): Promise<AccountData>;
237
- /**
238
- * Submit Transaction to the network
239
- * @param signedTxCbor signed transaction in CBOR hex format
240
- * @returns {Promise<string>} transaction hash
241
- */
242
143
  submitTransaction(signedTxCbor: string): Promise<string>;
243
- /**
244
- * Evaluate transaction script execution units
245
- * @param unsignedTxCbor unsigned transaction in CBOR hex format
246
- * @returns {Promise<ScriptEvaluationResult[]>} evaluation results
247
- */
144
+ /** Hash of a signed transaction, or null when the CBOR does not parse. */
145
+ private txHashOrNull;
146
+ /** Whether the node holds the transaction: in its mempool, or on chain with its first output unspent. */
147
+ private isKnownTransaction;
148
+ /** Mempool lookup on its own short connection, since an acquired mempool snapshot blocks the session. */
149
+ private mempoolHas;
248
150
  evaluateTransaction(unsignedTxCbor: string): Promise<ScriptEvaluationResult[]>;
249
- /**
250
- * Get current Protocol Parameters
251
- * @returns {Promise<LedgerProtocolParameters>} protocol parameters
252
- */
253
151
  getProtocolParameters(): Promise<LedgerProtocolParameters>;
254
- /**
255
- * Get Latest Epoch Data
256
- * @returns {Promise<EpochData>} latest epoch data
257
- */
258
152
  getLatestEpoch(): Promise<EpochData>;
259
- /**
260
- * Get current Latest Block Data
261
- * @returns {Promise<BlockData>} latest block data
262
- */
263
153
  getLatestBlock(): Promise<BlockData>;
264
- /**
265
- * Get the latest chain tip slot.
266
- * @returns {Promise<number>} current chain slot
267
- */
268
154
  getCurrentSlot(): Promise<number>;
269
- /**
270
- * Unspent check via `queryLedgerState/utxo` with an outputReferences filter; empty = spent or nonexistent.
271
- * @param txHash 64-char lowercase hex
272
- * @param outputIndex non-negative integer
273
- */
155
+ /** Unspent check via `queryLedgerState/utxo`. An empty answer means spent or unknown. */
274
156
  isUtxoUnspent(txHash: string, outputIndex: number): Promise<boolean>;
275
157
  /** Outputs among `refs` that are unspent in the live ledger; spent or unknown references are absent. */
276
158
  getUnspentOutputs(refs: Array<{
@@ -281,34 +163,11 @@ export declare class OgmiosBackend implements EvaluatingBackend, ChainSyncBacken
281
163
  shutdown(): Promise<void>;
282
164
  isConnected(): boolean;
283
165
  private ensureNotShutdown;
284
- /**
285
- * Ogmios value `{ ada: { lovelace }, policyId: { assetName: qty } }` →
286
- * `[{ unit: 'lovelace', quantity }, { unit: policyId+assetName, quantity }]`.
287
- */
166
+ /** Ogmios value `{ ada: { lovelace }, policyId: { assetName: qty } }` to a list of units and quantities. */
288
167
  private convertOgmiosValue;
289
- /**
290
- * Open a long-lived chain-sync stream on its own WebSocket. `sequential: true` + `inFlight: 1`
291
- * deliver blocks strictly in order (required by reorg detection and serial persist). Inputs arrive
292
- * as bare references (resolved by the indexer from indexed outputs); per-tx size/deposit are not surfaced.
293
- */
294
168
  openChainSync(from: ChainPoint[] | 'origin', callbacks: ChainSyncCallbacks): Promise<ChainSyncHandle>;
295
- /**
296
- * Map an Ogmios Praos block to BlockData + transactions. Block fees are the sum of per-tx
297
- * fees; epoch/epochSlot derive from the slot via the Shelley anchor. A phase-2 failure without
298
- * `total_collateral` still carries its declared fee here; applyCollateralFees() corrects it.
299
- */
300
169
  private mapOgmiosBlock;
301
- /**
302
- * Map one chain-sync transaction. Inputs stay bare references (resolved by the indexer).
303
- * `spends` selects the ledger-applied partition: a phase-2-invalid tx consumes collaterals
304
- * and creates only its collateral-return output; the fee follows that partition too.
305
- */
306
170
  private mapOgmiosTx;
307
- /**
308
- * Normalize Ogmios certificates onto the shared `CertificateKind` vocabulary. A `stakeDelegation`
309
- * with both pool and DRep target is split into two entries with the same index (as db-sync
310
- * reports it); bare credential hashes are re-encoded as bech32 to match the other tables.
311
- */
312
171
  private mapOgmiosCertificates;
313
172
  }
314
173
  export {};