@odatano/core 2.0.0-rc.43 → 2.0.0-rc.45

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 (171) 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 +36 -20
  4. package/@cds-models/CardanoIndexerService/index.js +4 -0
  5. package/@cds-models/CardanoODataService/index.d.ts +19 -47
  6. package/@cds-models/CardanoSignService/index.d.ts +3 -18
  7. package/@cds-models/CardanoTransactionService/index.d.ts +9 -31
  8. package/@cds-models/CardanoWorkerService/index.d.ts +3 -19
  9. package/@cds-models/index.d.ts +17 -0
  10. package/@cds-models/index.js +2 -0
  11. package/@cds-models/odatano/cardano/index.d.ts +1 -34
  12. package/README.md +6 -6
  13. package/db/schema.cds +29 -44
  14. package/db/types.cds +22 -5
  15. package/package.json +3 -1
  16. package/scripts/migrate-slot-leader.mjs +3 -11
  17. package/scripts/migrate-txseq.mjs +3 -12
  18. package/src/index.d.ts +0 -4
  19. package/src/index.js +3 -5
  20. package/src/plugin.js +4 -8
  21. package/srv/blockchain/asset-decimals.d.ts +7 -0
  22. package/srv/blockchain/asset-decimals.js +91 -0
  23. package/srv/blockchain/backends/blockfrost-backend.d.ts +2 -10
  24. package/srv/blockchain/backends/blockfrost-backend.js +15 -21
  25. package/srv/blockchain/backends/cardano-backend.d.ts +12 -71
  26. package/srv/blockchain/backends/koios-backend.d.ts +14 -147
  27. package/srv/blockchain/backends/koios-backend.js +40 -164
  28. package/srv/blockchain/backends/odatano-backend.d.ts +1 -11
  29. package/srv/blockchain/backends/odatano-backend.js +11 -12
  30. package/srv/blockchain/backends/ogmios-backend.d.ts +13 -160
  31. package/srv/blockchain/backends/ogmios-backend.js +48 -175
  32. package/srv/blockchain/backends/ogmios-frame-guard.d.ts +2 -18
  33. package/srv/blockchain/backends/ogmios-frame-guard.js +8 -20
  34. package/srv/blockchain/cardano-client.d.ts +12 -80
  35. package/srv/blockchain/cardano-client.js +36 -88
  36. package/srv/blockchain/cardano-indexer.d.ts +12 -192
  37. package/srv/blockchain/cardano-indexer.js +132 -222
  38. package/srv/blockchain/cardano-tx-builder.d.ts +1 -28
  39. package/srv/blockchain/cardano-tx-builder.js +17 -34
  40. package/srv/blockchain/circuit-breaker.d.ts +1 -13
  41. package/srv/blockchain/circuit-breaker.js +5 -15
  42. package/srv/blockchain/crawler/asset-decimals-backfill.d.ts +15 -0
  43. package/srv/blockchain/crawler/asset-decimals-backfill.js +56 -0
  44. package/srv/blockchain/crawler/certificate-backfill.d.ts +0 -17
  45. package/srv/blockchain/crawler/certificate-backfill.js +8 -22
  46. package/srv/blockchain/crawler/crawler.d.ts +16 -93
  47. package/srv/blockchain/crawler/crawler.js +85 -160
  48. package/srv/blockchain/crawler/credential-backfill.d.ts +0 -9
  49. package/srv/blockchain/crawler/credential-backfill.js +6 -6
  50. package/srv/blockchain/crawler/hooks.d.ts +1 -5
  51. package/srv/blockchain/crawler/index.d.ts +0 -12
  52. package/srv/blockchain/crawler/index.js +6 -20
  53. package/srv/blockchain/crawler/sync-state.d.ts +6 -44
  54. package/srv/blockchain/crawler/sync-state.js +18 -53
  55. package/srv/blockchain/crawler/transaction-backfill.d.ts +0 -11
  56. package/srv/blockchain/crawler/transaction-backfill.js +11 -30
  57. package/srv/blockchain/crawler/utxo-set-import.d.ts +1 -30
  58. package/srv/blockchain/crawler/utxo-set-import.js +27 -53
  59. package/srv/blockchain/ledger-state.d.ts +10 -54
  60. package/srv/blockchain/ledger-state.js +11 -27
  61. package/srv/blockchain/pending-spends.d.ts +0 -12
  62. package/srv/blockchain/pending-spends.js +4 -12
  63. package/srv/blockchain/request-coalescer.d.ts +2 -16
  64. package/srv/blockchain/request-coalescer.js +2 -16
  65. package/srv/blockchain/signing/cose-verifier.d.ts +0 -9
  66. package/srv/blockchain/signing/cose-verifier.js +4 -10
  67. package/srv/blockchain/signing/external-signer.d.ts +1 -4
  68. package/srv/blockchain/signing/external-signer.js +2 -8
  69. package/srv/blockchain/signing/hsm-signer.d.ts +6 -18
  70. package/srv/blockchain/signing/hsm-signer.js +16 -28
  71. package/srv/blockchain/signing/signature-verifier.d.ts +1 -8
  72. package/srv/blockchain/signing/signature-verifier.js +9 -19
  73. package/srv/blockchain/signing/submission-finalizer.d.ts +10 -16
  74. package/srv/blockchain/signing/submission-finalizer.js +48 -19
  75. package/srv/blockchain/stored-chain.d.ts +1 -14
  76. package/srv/blockchain/stored-chain.js +3 -8
  77. package/srv/blockchain/transaction-building/buildooor-fee-patch.d.ts +0 -4
  78. package/srv/blockchain/transaction-building/buildooor-fee-patch.js +4 -9
  79. package/srv/blockchain/transaction-building/buildooor-tx.d.ts +7 -150
  80. package/srv/blockchain/transaction-building/buildooor-tx.js +91 -196
  81. package/srv/blockchain/transaction-building/caller-datums.d.ts +0 -14
  82. package/srv/blockchain/transaction-building/caller-datums.js +3 -9
  83. package/srv/blockchain/transaction-building/cardano-tx.d.ts +1 -4
  84. package/srv/blockchain/wallet-worker/build-request.d.ts +0 -5
  85. package/srv/blockchain/wallet-worker/build-request.js +6 -9
  86. package/srv/blockchain/wallet-worker/confirmation-tracker.d.ts +5 -23
  87. package/srv/blockchain/wallet-worker/confirmation-tracker.js +16 -20
  88. package/srv/blockchain/wallet-worker/index.d.ts +1 -1
  89. package/srv/blockchain/wallet-worker/index.js +3 -5
  90. package/srv/blockchain/wallet-worker/job-store.d.ts +15 -65
  91. package/srv/blockchain/wallet-worker/job-store.js +0 -0
  92. package/srv/blockchain/wallet-worker/lease-heartbeat.d.ts +2 -10
  93. package/srv/blockchain/wallet-worker/lease-heartbeat.js +6 -12
  94. package/srv/blockchain/wallet-worker/signers.d.ts +3 -11
  95. package/srv/blockchain/wallet-worker/signers.js +3 -6
  96. package/srv/blockchain/wallet-worker/wallet-worker.d.ts +3 -21
  97. package/srv/blockchain/wallet-worker/wallet-worker.js +47 -54
  98. package/srv/cardano-agent-service.cds +123 -146
  99. package/srv/cardano-agent-service.js +2 -5
  100. package/srv/cardano-backend-service.cds +10 -17
  101. package/srv/cardano-backend-service.js +7 -12
  102. package/srv/cardano-indexer-service.cds +35 -37
  103. package/srv/cardano-indexer-service.d.ts +5 -1
  104. package/srv/cardano-indexer-service.js +64 -33
  105. package/srv/cardano-service.cds +56 -40
  106. package/srv/cardano-service.js +42 -69
  107. package/srv/cardano-sign-service.cds +14 -23
  108. package/srv/cardano-sign-service.js +18 -24
  109. package/srv/cardano-tx-service.cds +27 -29
  110. package/srv/cardano-tx-service.js +60 -122
  111. package/srv/cardano-worker-service.cds +109 -125
  112. package/srv/cardano-worker-service.js +21 -31
  113. package/srv/cbor/cip68.d.ts +13 -0
  114. package/srv/cbor/cip68.js +56 -0
  115. package/srv/cbor/index.d.ts +1 -0
  116. package/srv/cbor/index.js +6 -1
  117. package/srv/cbor/parse.d.ts +3 -18
  118. package/srv/cbor/parse.js +2 -7
  119. package/srv/cbor/plutus-data-json.d.ts +0 -4
  120. package/srv/server.d.ts +5 -36
  121. package/srv/server.js +30 -51
  122. package/srv/utils/agent-grants-config.d.ts +0 -18
  123. package/srv/utils/agent-grants-config.js +6 -13
  124. package/srv/utils/agent-grants.d.ts +14 -68
  125. package/srv/utils/agent-grants.js +42 -60
  126. package/srv/utils/agent-token-auth.d.ts +0 -5
  127. package/srv/utils/agent-token-auth.js +2 -5
  128. package/srv/utils/backend-request-handler.d.ts +1 -1
  129. package/srv/utils/collections.d.ts +1 -4
  130. package/srv/utils/collections.js +1 -4
  131. package/srv/utils/const.d.ts +0 -18
  132. package/srv/utils/const.js +7 -18
  133. package/srv/utils/crypto.js +3 -5
  134. package/srv/utils/db-indexes.d.ts +2 -0
  135. package/srv/utils/db-indexes.js +22 -9
  136. package/srv/utils/db-sanitize.d.ts +1 -8
  137. package/srv/utils/db-sanitize.js +3 -8
  138. package/srv/utils/epoch-slots.d.ts +1 -8
  139. package/srv/utils/epoch-slots.js +3 -8
  140. package/srv/utils/error-codes.d.ts +0 -4
  141. package/srv/utils/error-codes.js +2 -4
  142. package/srv/utils/errors.d.ts +2 -22
  143. package/srv/utils/errors.js +13 -27
  144. package/srv/utils/liveness.d.ts +0 -4
  145. package/srv/utils/liveness.js +2 -4
  146. package/srv/utils/mappers.d.ts +0 -37
  147. package/srv/utils/mappers.js +22 -39
  148. package/srv/utils/network-context.js +2 -4
  149. package/srv/utils/paging.d.ts +31 -0
  150. package/srv/utils/paging.js +43 -0
  151. package/srv/utils/pg-inline-json.js +3 -7
  152. package/srv/utils/pg-order-nulls.js +2 -5
  153. package/srv/utils/plutus-placeholders.d.ts +0 -13
  154. package/srv/utils/plutus-placeholders.js +6 -13
  155. package/srv/utils/rate-limiter.d.ts +0 -8
  156. package/srv/utils/rate-limiter.js +2 -4
  157. package/srv/utils/reference-script.d.ts +0 -18
  158. package/srv/utils/reference-script.js +8 -19
  159. package/srv/utils/service-events.d.ts +0 -4
  160. package/srv/utils/service-events.js +2 -4
  161. package/srv/utils/signing-helper.d.ts +1 -8
  162. package/srv/utils/signing-helper.js +3 -8
  163. package/srv/utils/tx-build-helper.d.ts +2 -32
  164. package/srv/utils/tx-build-helper.js +26 -40
  165. package/srv/utils/tx-request-parsers.d.ts +1 -25
  166. package/srv/utils/tx-request-parsers.js +10 -25
  167. package/srv/utils/tx-utils.d.ts +0 -8
  168. package/srv/utils/tx-utils.js +10 -13
  169. package/srv/utils/types.d.ts +2 -37
  170. package/srv/utils/validators.d.ts +0 -4
  171. package/srv/utils/validators.js +2 -4
@@ -1,32 +1,6 @@
1
1
  // This is an automatically generated file. Please do not change its contents manually!
2
2
  import * as __ from './../_';
3
3
 
4
- /**
5
- * Cardano Agent Service (v2.0)
6
- *
7
- * Agent grants: scoped, budgeted bearer capabilities an Admin hands to an agent
8
- * instead of a full user.
9
- *
10
- * - CreateAgentGrant / UpdateAgentGrant / RotateAgentGrantToken / RevokeAgentGrant:
11
- * Admin-only administration, rate limited per principal per hour
12
- * (AGENT_GRANT_ADMIN_RATE_LIMIT, default 10). The token is returned ONCE from
13
- * CreateAgentGrant and RotateAgentGrantToken and stored as SHA-256 only.
14
- * - AgentGrants: Admin-only projection (no token hash). A request carrying a token
15
- * runs as the principal `agent:<grantId>` with the role `agent-grant` and sees
16
- * exactly its own row through the row-level restriction below.
17
- * - GetGrantStatus: token self-service — what am I allowed to do, how much budget
18
- * is left, when do I expire. What an MCP tool needs to describe itself honestly.
19
- * - GetGrantUsage: admitted calls per service and action over a window — an Admin
20
- * for any grant, a token for its own (a partner usage view, ledger reconciliation).
21
- *
22
- * A token request never inherits the operator's roles: `@requires: 'Admin'` on the
23
- * four actions, on PauseWorker / ResumeWorker / pauseCrawler / resumeCrawler and on
24
- * every other Admin surface therefore refuses it by construction. The allow list,
25
- * wallet pinning and daily budget are enforced by a before('*') hook on all six
26
- * ODATANO services (srv/utils/agent-grants.ts). The `x-agent-token` header only
27
- * reaches the services when cds.requires.odatano-core.agentGrants.enabled is set
28
- * (srv/utils/agent-token-auth.ts).
29
- */
30
4
  export default class {
31
5
  static readonly GetGrantStatus: typeof GetGrantStatus;
32
6
  static readonly CreateAgentGrant: typeof CreateAgentGrant;
@@ -59,28 +33,8 @@ export declare function _AgentGrantAspect<TBase extends new (...args: any[]) =>
59
33
  readonly elements: __.ElementsOf<AgentGrant>;
60
34
  readonly actions: globalThis.Record<never, never>;
61
35
  };
62
- /**
63
- * Agent grants (v2.0): scoped bearer capabilities an Admin hands to an agent
64
- * instead of a full user. The token is a capability, not an identity — it is
65
- * stored as SHA-256 only, and a request carrying it runs as the principal
66
- * `agent:<ID>` with the role `agent-grant`, never as the operator. Enforcement
67
- * (allow list, wallet pinning, daily budget) lives in srv/utils/agent-grants.ts;
68
- * the transport lane that admits `x-agent-token` in srv/utils/agent-token-auth.ts.
69
- * Admin-only table: creation and revocation happen through CardanoAgentService
70
- * actions, a token request may read its own row only.
71
- */
72
36
  export class AgentGrant extends _AgentGrantAspect(__.Entity) {
73
37
  }
74
- /**
75
- * Agent grants (v2.0): scoped bearer capabilities an Admin hands to an agent
76
- * instead of a full user. The token is a capability, not an identity — it is
77
- * stored as SHA-256 only, and a request carrying it runs as the principal
78
- * `agent:<ID>` with the role `agent-grant`, never as the operator. Enforcement
79
- * (allow list, wallet pinning, daily budget) lives in srv/utils/agent-grants.ts;
80
- * the transport lane that admits `x-agent-token` in srv/utils/agent-token-auth.ts.
81
- * Admin-only table: creation and revocation happen through CardanoAgentService
82
- * actions, a token request may read its own row only.
83
- */
84
38
  export class AgentGrants extends Array<AgentGrant> {
85
39
  $count?: number
86
40
  }
@@ -1,16 +1,6 @@
1
1
  // This is an automatically generated file. Please do not change its contents manually!
2
2
  import * as __ from './../_';
3
3
 
4
- /**
5
- * Cardano Backend Service
6
- *
7
- * The data a CardanoBackend needs, for another ODATANO instance that uses this one as its
8
- * backend (`backends: ["odatano"]`). Every operation answers the provider shape as a JSON
9
- * string (`value`), so the caller maps it exactly like a Koios or Blockfrost answer.
10
- * Stored blocks and transactions come from this instance's index; everything else goes
11
- * through its own backends and crawled data, as the read service does. Nothing is persisted
12
- * for the caller.
13
- */
14
4
  export default class {
15
5
  static readonly GetTransaction: typeof GetTransaction;
16
6
  static readonly GetTransactionsBatch: typeof GetTransactionsBatch;
@@ -2,23 +2,6 @@
2
2
  import * as _ from './..';
3
3
  import * as __ from './../_';
4
4
 
5
- /**
6
- * Cardano Indexer Service (v2.0)
7
- *
8
- * Control + observability surface for the chain crawler / pre-sync engine:
9
- * - read-only projections of the sync cursor and reorg audit log
10
- * - status function + pause/resume actions delegating to the crawler singleton
11
- *
12
- * Security note: see CardanoODataService (cardano-service.cds) for the rationale on
13
- * auth. pause/resume are operational actions — gate behind a dedicated Admin scope.
14
- * Read-only status and audit data remain available to authenticated users.
15
- *
16
- * Deliberately NO service-level @requires: CAP checks a service-level requirement
17
- * on every request BEFORE the operation's own annotation, so an operation-level
18
- * `@requires: 'any'` can never open a single function on an otherwise
19
- * authenticated service (anonymous callers get the 401 challenge first). The
20
- * requirement therefore sits on each element, and getLiveness() alone is 'any'.
21
- */
22
5
  export default class {
23
6
  static readonly getStatus: typeof getStatus;
24
7
  static readonly getLiveness: typeof getLiveness;
@@ -28,6 +11,7 @@ export default class {
28
11
  static readonly backfillCertificates: typeof backfillCertificates;
29
12
  static readonly backfillTransactions: typeof backfillTransactions;
30
13
  static readonly backfillPaymentCredentials: typeof backfillPaymentCredentials;
14
+ static readonly backfillAssetDecimals: typeof backfillAssetDecimals;
31
15
  }
32
16
 
33
17
  // entity 'SyncState'
@@ -102,10 +86,13 @@ export declare function _CrawlerStatusAspect<TBase extends new (...args: any[])
102
86
  tipHeight?: string | null
103
87
  syncProgress?: string | null
104
88
  consecutiveErrors?: number | null
89
+ lastIndexedAt?: __.CdsTimestamp | null
90
+ stalled?: boolean | null
105
91
  utxoSet?: UtxoSetStatus | null
106
92
  certificateBackfill?: CertificateBackfillStatus | null
107
93
  transactionBackfill?: TransactionBackfillStatus | null
108
94
  credentialBackfill?: CredentialBackfillStatus | null
95
+ decimalsBackfill?: DecimalsBackfillStatus | null
109
96
  epochSnapshots?: EpochSnapshotStatus | null
110
97
  } & InstanceType<TBase>
111
98
  readonly kind: 'type';
@@ -201,6 +188,25 @@ export declare function _CredentialBackfillStatusAspect<TBase extends new (...ar
201
188
  export class CredentialBackfillStatus extends _CredentialBackfillStatusAspect(__.Entity) {
202
189
  }
203
190
 
191
+ // entity 'DecimalsBackfillStatus'
192
+ export declare function _DecimalsBackfillStatusAspect<TBase extends new (...args: any[]) => object>(Base: TBase): {
193
+ new (...args: any[]): {
194
+ status?: string | null
195
+ scanned?: number | null
196
+ candidates?: number | null
197
+ filled?: number | null
198
+ startedAt?: __.CdsTimestamp | null
199
+ finishedAt?: __.CdsTimestamp | null
200
+ error?: string | null
201
+ } & InstanceType<TBase>
202
+ readonly kind: 'type';
203
+ readonly keys: __.KeysOf<DecimalsBackfillStatus>;
204
+ readonly elements: __.ElementsOf<DecimalsBackfillStatus>;
205
+ readonly actions: globalThis.Record<never, never>;
206
+ };
207
+ export class DecimalsBackfillStatus extends _DecimalsBackfillStatusAspect(__.Entity) {
208
+ }
209
+
204
210
  // entity 'BackfillResult'
205
211
  export declare function _BackfillResultAspect<TBase extends new (...args: any[]) => object>(Base: TBase): {
206
212
  new (...args: any[]): {
@@ -342,11 +348,11 @@ export declare const resumeCrawler: {
342
348
 
343
349
  export declare const importUtxoSet: {
344
350
  // positional
345
- (source: string | null, filePath: string | null, anchorSlot: number | null, anchorHash: string | null): globalThis.Promise<UtxoSetImportResult | null> | UtxoSetImportResult | null
351
+ (source: _.UtxoSetImportSource | null, filePath: string | null, anchorSlot: number | null, anchorHash: string | null): globalThis.Promise<UtxoSetImportResult | null> | UtxoSetImportResult | null
346
352
  // named
347
- ({source, filePath, anchorSlot, anchorHash}: {source?: string | null, filePath?: string | null, anchorSlot?: number | null, anchorHash?: string | null}): globalThis.Promise<UtxoSetImportResult | null> | UtxoSetImportResult | null
353
+ ({source, filePath, anchorSlot, anchorHash}: {source?: _.UtxoSetImportSource | null, filePath?: string | null, anchorSlot?: number | null, anchorHash?: string | null}): globalThis.Promise<UtxoSetImportResult | null> | UtxoSetImportResult | null
348
354
  // metadata (do not use)
349
- __parameters: {source?: string | null, filePath?: string | null, anchorSlot?: number | null, anchorHash?: string | null}, __returns: globalThis.Promise<UtxoSetImportResult | null> | UtxoSetImportResult | null, __self: never
355
+ __parameters: {source?: _.UtxoSetImportSource | null, filePath?: string | null, anchorSlot?: number | null, anchorHash?: string | null}, __returns: globalThis.Promise<UtxoSetImportResult | null> | UtxoSetImportResult | null, __self: never
350
356
  kind: 'action'
351
357
  }
352
358
 
@@ -378,4 +384,14 @@ export declare const backfillPaymentCredentials: {
378
384
  // metadata (do not use)
379
385
  __parameters: globalThis.Record<never, never>, __returns: globalThis.Promise<BackfillResult | null> | BackfillResult | null, __self: never
380
386
  kind: 'action'
387
+ }
388
+
389
+ export declare const backfillAssetDecimals: {
390
+ // positional
391
+ (): globalThis.Promise<BackfillResult | null> | BackfillResult | null
392
+ // named
393
+ ({}: globalThis.Record<never, never>): globalThis.Promise<BackfillResult | null> | BackfillResult | null
394
+ // metadata (do not use)
395
+ __parameters: globalThis.Record<never, never>, __returns: globalThis.Promise<BackfillResult | null> | BackfillResult | null, __self: never
396
+ kind: 'action'
381
397
  }
@@ -25,6 +25,9 @@ module.exports.__Array_TransactionBackfillStatus_ = createEntityProxy(['CardanoI
25
25
  // CredentialBackfillStatus
26
26
  module.exports.CredentialBackfillStatus = createEntityProxy(['CardanoIndexerService', 'CredentialBackfillStatus'], { target: { is_singular: true } })
27
27
  module.exports.__Array_CredentialBackfillStatus_ = createEntityProxy(['CardanoIndexerService', 'CredentialBackfillStatus'], { target: { is_singular: false }})
28
+ // DecimalsBackfillStatus
29
+ module.exports.DecimalsBackfillStatus = createEntityProxy(['CardanoIndexerService', 'DecimalsBackfillStatus'], { target: { is_singular: true } })
30
+ module.exports.__Array_DecimalsBackfillStatus_ = createEntityProxy(['CardanoIndexerService', 'DecimalsBackfillStatus'], { target: { is_singular: false }})
28
31
  // BackfillResult
29
32
  module.exports.BackfillResult = createEntityProxy(['CardanoIndexerService', 'BackfillResult'], { target: { is_singular: true } })
30
33
  module.exports.__Array_BackfillResult_ = createEntityProxy(['CardanoIndexerService', 'BackfillResult'], { target: { is_singular: false }})
@@ -52,4 +55,5 @@ module.exports.importUtxoSet = 'importUtxoSet'
52
55
  module.exports.backfillCertificates = 'backfillCertificates'
53
56
  module.exports.backfillTransactions = 'backfillTransactions'
54
57
  module.exports.backfillPaymentCredentials = 'backfillPaymentCredentials'
58
+ module.exports.backfillAssetDecimals = 'backfillAssetDecimals'
55
59
  // enums
@@ -2,35 +2,6 @@
2
2
  import * as _ from './..';
3
3
  import * as __ from './../_';
4
4
 
5
- /**
6
- * Cardano OData Service
7
- *
8
- * Handles external read-only queries for Cardano blockchain data, including:
9
- * - Retrieving network information, blocks, epochs, pools, dreps, transactions, accounts, addresses, UTxOs, assets, and metadata
10
- * - Providing actions for fetching specific data by identifiers (hashes, addresses, etc.) and for retrieving the latest blockchain state (latest block, epoch, protocol parameters)
11
- *
12
- * ## Security: Authentication & Authorization
13
- *
14
- * All services use `@requires: 'authenticated-user'` (service-level gate).
15
- * The XSUAA scopes defined in xs-security.json (Read, Transact, Sign) are available
16
- * for consumer-level role assignment but are NOT enforced per-action in ODATANO itself.
17
- *
18
- * This is intentional — ODATANO is a blockchain bridge, not a multi-tenant application.
19
- * Per-resource ownership checks (IDOR prevention) are deliberately omitted because:
20
- *
21
- * 1. **Blockchain security model**: Unsigned transaction CBOR is not exploitable without
22
- * the corresponding private key. Viewing a build/signing request does not enable
23
- * fund theft — only the key holder can sign and submit.
24
- *
25
- * 2. **Cross-address operations are legitimate**: Smart contract interactions routinely
26
- * require building transactions for addresses the caller does not own — e.g. script
27
- * redemptions, multi-party Plutus workflows, or DApp backends building on behalf of users.
28
- * Enforcing sender == authenticated user would break these use cases.
29
- *
30
- * 3. **Consumer responsibility**: Consumers deploying ODATANO in multi-user environments
31
- * should add their own authorization layer (e.g. `@restrict` annotations, custom
32
- * middleware) that maps JWT claims to allowed wallet addresses if needed.
33
- */
34
5
  export default class {
35
6
  static readonly GetNetworkInformation: typeof GetNetworkInformation;
36
7
  static readonly GetBlockByHash: typeof GetBlockByHash;
@@ -295,6 +266,7 @@ export declare function _AssetAspect<TBase extends new (...args: any[]) => objec
295
266
  registryName?: string | null
296
267
  registryTicker?: string | null
297
268
  registryDecimals?: number | null
269
+ decimals?: number | null
298
270
  registryDescription?: string | null
299
271
  registryUrl?: string | null
300
272
  registryLogo?: string | null
@@ -990,11 +962,11 @@ export declare const GetAssetInfo: {
990
962
 
991
963
  export declare const GetAssetHistory: {
992
964
  // positional
993
- (unit: _.AssetUnit | null, limit: number | null): globalThis.Promise<Array<AssetHistory>> | Array<AssetHistory>
965
+ (unit: _.AssetUnit | null, limit: number | null, skip: number | null): globalThis.Promise<Array<AssetHistory>> | Array<AssetHistory>
994
966
  // named
995
- ({unit, limit}: {unit?: _.AssetUnit | null, limit?: number | null}): globalThis.Promise<Array<AssetHistory>> | Array<AssetHistory>
967
+ ({unit, limit, skip}: {unit?: _.AssetUnit | null, limit?: number | null, skip?: number | null}): globalThis.Promise<Array<AssetHistory>> | Array<AssetHistory>
996
968
  // metadata (do not use)
997
- __parameters: {unit?: _.AssetUnit | null, limit?: number | null}, __returns: globalThis.Promise<Array<AssetHistory>> | Array<AssetHistory>, __self: never
969
+ __parameters: {unit?: _.AssetUnit | null, limit?: number | null, skip?: number | null}, __returns: globalThis.Promise<Array<AssetHistory>> | Array<AssetHistory>, __self: never
998
970
  kind: 'action'
999
971
  }
1000
972
 
@@ -1030,11 +1002,11 @@ export declare const GetTransactionConfirmations: {
1030
1002
 
1031
1003
  export declare const GetMetadataByTxHash: {
1032
1004
  // positional
1033
- (txHash: _.Blake2b256 | null): globalThis.Promise<Array<TransactionMetadata>> | Array<TransactionMetadata>
1005
+ (txHash: _.Blake2b256 | null, limit: number | null, skip: number | null): globalThis.Promise<Array<TransactionMetadata>> | Array<TransactionMetadata>
1034
1006
  // named
1035
- ({txHash}: {txHash?: _.Blake2b256 | null}): globalThis.Promise<Array<TransactionMetadata>> | Array<TransactionMetadata>
1007
+ ({txHash, limit, skip}: {txHash?: _.Blake2b256 | null, limit?: number | null, skip?: number | null}): globalThis.Promise<Array<TransactionMetadata>> | Array<TransactionMetadata>
1036
1008
  // metadata (do not use)
1037
- __parameters: {txHash?: _.Blake2b256 | null}, __returns: globalThis.Promise<Array<TransactionMetadata>> | Array<TransactionMetadata>, __self: never
1009
+ __parameters: {txHash?: _.Blake2b256 | null, limit?: number | null, skip?: number | null}, __returns: globalThis.Promise<Array<TransactionMetadata>> | Array<TransactionMetadata>, __self: never
1038
1010
  kind: 'action'
1039
1011
  }
1040
1012
 
@@ -1050,41 +1022,41 @@ export declare const GetAddressByBech32: {
1050
1022
 
1051
1023
  export declare const GetUTxOsByAddress: {
1052
1024
  // positional
1053
- (address: _.Bech32 | null): globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>
1025
+ (address: _.Bech32 | null, limit: number | null, skip: number | null): globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>
1054
1026
  // named
1055
- ({address}: {address?: _.Bech32 | null}): globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>
1027
+ ({address, limit, skip}: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}): globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>
1056
1028
  // metadata (do not use)
1057
- __parameters: {address?: _.Bech32 | null}, __returns: globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>, __self: never
1029
+ __parameters: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}, __returns: globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>, __self: never
1058
1030
  kind: 'action'
1059
1031
  }
1060
1032
 
1061
1033
  export declare const GetUTxOsByCredential: {
1062
1034
  // positional
1063
- (credential: string | null): globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>
1035
+ (credential: string | null, limit: number | null, skip: number | null): globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>
1064
1036
  // named
1065
- ({credential}: {credential?: string | null}): globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>
1037
+ ({credential, limit, skip}: {credential?: string | null, limit?: number | null, skip?: number | null}): globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>
1066
1038
  // metadata (do not use)
1067
- __parameters: {credential?: string | null}, __returns: globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>, __self: never
1039
+ __parameters: {credential?: string | null, limit?: number | null, skip?: number | null}, __returns: globalThis.Promise<Array<AddressUTxO>> | Array<AddressUTxO>, __self: never
1068
1040
  kind: 'action'
1069
1041
  }
1070
1042
 
1071
1043
  export declare const GetAssetsByAddress: {
1072
1044
  // positional
1073
- (address: _.Bech32 | null): globalThis.Promise<Array<AddressAsset>> | Array<AddressAsset>
1045
+ (address: _.Bech32 | null, limit: number | null, skip: number | null): globalThis.Promise<Array<AddressAsset>> | Array<AddressAsset>
1074
1046
  // named
1075
- ({address}: {address?: _.Bech32 | null}): globalThis.Promise<Array<AddressAsset>> | Array<AddressAsset>
1047
+ ({address, limit, skip}: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}): globalThis.Promise<Array<AddressAsset>> | Array<AddressAsset>
1076
1048
  // metadata (do not use)
1077
- __parameters: {address?: _.Bech32 | null}, __returns: globalThis.Promise<Array<AddressAsset>> | Array<AddressAsset>, __self: never
1049
+ __parameters: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}, __returns: globalThis.Promise<Array<AddressAsset>> | Array<AddressAsset>, __self: never
1078
1050
  kind: 'action'
1079
1051
  }
1080
1052
 
1081
1053
  export declare const GetLatestTransactionsByAddress: {
1082
1054
  // positional
1083
- (address: _.Bech32 | null, limit: number | null): globalThis.Promise<Array<AddressTransaction>> | Array<AddressTransaction>
1055
+ (address: _.Bech32 | null, limit: number | null, skip: number | null): globalThis.Promise<Array<AddressTransaction>> | Array<AddressTransaction>
1084
1056
  // named
1085
- ({address, limit}: {address?: _.Bech32 | null, limit?: number | null}): globalThis.Promise<Array<AddressTransaction>> | Array<AddressTransaction>
1057
+ ({address, limit, skip}: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}): globalThis.Promise<Array<AddressTransaction>> | Array<AddressTransaction>
1086
1058
  // metadata (do not use)
1087
- __parameters: {address?: _.Bech32 | null, limit?: number | null}, __returns: globalThis.Promise<Array<AddressTransaction>> | Array<AddressTransaction>, __self: never
1059
+ __parameters: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}, __returns: globalThis.Promise<Array<AddressTransaction>> | Array<AddressTransaction>, __self: never
1088
1060
  kind: 'action'
1089
1061
  }
1090
1062
 
@@ -3,21 +3,6 @@ import * as __ from './../_';
3
3
  import * as _ from './..';
4
4
  import * as _odatano_cardano from './../odatano/cardano';
5
5
 
6
- /**
7
- * Cardano Sign Service
8
- *
9
- * Handles the external signing workflow for Cardano transactions, including:
10
- * - Creating signing requests with transaction details and signing instructions
11
- * - Verifying signatures of signed transactions and storing verification results
12
- * - Submitting verified transactions to the blockchain and tracking submission status
13
- * - Providing actions for signing with a Hardware Security Module (HSM) and retrieving HSM status
14
- *
15
- * Security note: see CardanoODataService (cardano-service.cds) for the rationale on auth
16
- * without per-resource ownership enforcement. Deliberately NO service-level @requires:
17
- * CAP checks it on every request BEFORE the operation annotation, which silenced the
18
- * `any` on VerifyDataSignature (anonymous callers got the 401 challenge first). The
19
- * requirement therefore sits on each element; VerifyDataSignature alone is public.
20
- */
21
6
  export default class {
22
7
  static readonly VerifySignature: typeof VerifySignature;
23
8
  static readonly SubmitVerifiedTransaction: typeof SubmitVerifiedTransaction;
@@ -507,11 +492,11 @@ export declare const GetSigningRequest: {
507
492
 
508
493
  export declare const GetSigningRequestsByAddress: {
509
494
  // positional
510
- (address: _.Bech32 | null): globalThis.Promise<Array<AddressSigningRequest>> | Array<AddressSigningRequest>
495
+ (address: _.Bech32 | null, limit: number | null, skip: number | null): globalThis.Promise<Array<AddressSigningRequest>> | Array<AddressSigningRequest>
511
496
  // named
512
- ({address}: {address?: _.Bech32 | null}): globalThis.Promise<Array<AddressSigningRequest>> | Array<AddressSigningRequest>
497
+ ({address, limit, skip}: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}): globalThis.Promise<Array<AddressSigningRequest>> | Array<AddressSigningRequest>
513
498
  // metadata (do not use)
514
- __parameters: {address?: _.Bech32 | null}, __returns: globalThis.Promise<Array<AddressSigningRequest>> | Array<AddressSigningRequest>, __self: never
499
+ __parameters: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}, __returns: globalThis.Promise<Array<AddressSigningRequest>> | Array<AddressSigningRequest>, __self: never
515
500
  kind: 'action'
516
501
  }
517
502
 
@@ -3,16 +3,6 @@ import * as _ from './..';
3
3
  import * as __ from './../_';
4
4
  import * as _odatano_cardano from './../odatano/cardano';
5
5
 
6
- /**
7
- * Cardano Transaction Service
8
- *
9
- * Handles transaction building and submission operations.
10
- * Separate from the read-only CardanoODataService to provide
11
- * clear separation between general query and command operations.
12
- *
13
- * Security note: see CardanoODataService (cardano-service.cds) for the rationale
14
- * on service-level auth without per-resource ownership enforcement.
15
- */
16
6
  export default class {
17
7
  static readonly BuildSimpleAdaTransaction: typeof BuildSimpleAdaTransaction;
18
8
  static readonly BuildTransactionWithMetadata: typeof BuildTransactionWithMetadata;
@@ -217,20 +207,8 @@ export declare function _TransactionSubmissionAspect<TBase extends new (...args:
217
207
  }
218
208
  };
219
209
  };
220
- /**
221
- * TransactionSubmissions status flow:
222
- * pending -> [submit to chain] -> submitted (internal, in SubmitTransaction handler)
223
- * submitted -> [CheckSubmissionStatus] confirmed | stays submitted (conditional)
224
- * pending | submitted -> failed (blockchain error)
225
- */
226
210
  export class TransactionSubmission extends _TransactionSubmissionAspect(__.Entity) {
227
211
  }
228
- /**
229
- * TransactionSubmissions status flow:
230
- * pending -> [submit to chain] -> submitted (internal, in SubmitTransaction handler)
231
- * submitted -> [CheckSubmissionStatus] confirmed | stays submitted (conditional)
232
- * pending | submitted -> failed (blockchain error)
233
- */
234
212
  export class TransactionSubmissions extends Array<TransactionSubmission> {
235
213
  $count?: number
236
214
  }
@@ -476,11 +454,11 @@ export declare const SubmitTransaction: {
476
454
 
477
455
  export declare const SubmitSignedTransaction: {
478
456
  // positional
479
- (signedTxCbor: string | null, network: string | null): globalThis.Promise<TransactionSubmission | null> | TransactionSubmission | null
457
+ (signedTxCbor: string | null, network: _.CardanoNetwork | null): globalThis.Promise<TransactionSubmission | null> | TransactionSubmission | null
480
458
  // named
481
- ({signedTxCbor, network}: {signedTxCbor?: string | null, network?: string | null}): globalThis.Promise<TransactionSubmission | null> | TransactionSubmission | null
459
+ ({signedTxCbor, network}: {signedTxCbor?: string | null, network?: _.CardanoNetwork | null}): globalThis.Promise<TransactionSubmission | null> | TransactionSubmission | null
482
460
  // metadata (do not use)
483
- __parameters: {signedTxCbor?: string | null, network?: string | null}, __returns: globalThis.Promise<TransactionSubmission | null> | TransactionSubmission | null, __self: never
461
+ __parameters: {signedTxCbor?: string | null, network?: _.CardanoNetwork | null}, __returns: globalThis.Promise<TransactionSubmission | null> | TransactionSubmission | null, __self: never
484
462
  kind: 'action'
485
463
  }
486
464
 
@@ -516,21 +494,21 @@ export declare const SetCollateral: {
516
494
 
517
495
  export declare const GetTransactionBuildsByAddress: {
518
496
  // positional
519
- (address: _.Bech32 | null): globalThis.Promise<Array<AddressTransactionBuild>> | Array<AddressTransactionBuild>
497
+ (address: _.Bech32 | null, limit: number | null, skip: number | null): globalThis.Promise<Array<AddressTransactionBuild>> | Array<AddressTransactionBuild>
520
498
  // named
521
- ({address}: {address?: _.Bech32 | null}): globalThis.Promise<Array<AddressTransactionBuild>> | Array<AddressTransactionBuild>
499
+ ({address, limit, skip}: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}): globalThis.Promise<Array<AddressTransactionBuild>> | Array<AddressTransactionBuild>
522
500
  // metadata (do not use)
523
- __parameters: {address?: _.Bech32 | null}, __returns: globalThis.Promise<Array<AddressTransactionBuild>> | Array<AddressTransactionBuild>, __self: never
501
+ __parameters: {address?: _.Bech32 | null, limit?: number | null, skip?: number | null}, __returns: globalThis.Promise<Array<AddressTransactionBuild>> | Array<AddressTransactionBuild>, __self: never
524
502
  kind: 'action'
525
503
  }
526
504
 
527
505
  export declare const DeriveScriptAddress: {
528
506
  // positional
529
- (validatorScript: string | null, scriptParamsJson: string | null, network: string | null): globalThis.Promise<{ scriptAddress?: string | null, scriptHash?: string | null, } | null> | { scriptAddress?: string | null, scriptHash?: string | null, } | null
507
+ (validatorScript: string | null, scriptParamsJson: string | null, network: _.CardanoNetwork | null): globalThis.Promise<{ scriptAddress?: string | null, scriptHash?: string | null, } | null> | { scriptAddress?: string | null, scriptHash?: string | null, } | null
530
508
  // named
531
- ({validatorScript, scriptParamsJson, network}: {validatorScript?: string | null, scriptParamsJson?: string | null, network?: string | null}): globalThis.Promise<{ scriptAddress?: string | null, scriptHash?: string | null, } | null> | { scriptAddress?: string | null, scriptHash?: string | null, } | null
509
+ ({validatorScript, scriptParamsJson, network}: {validatorScript?: string | null, scriptParamsJson?: string | null, network?: _.CardanoNetwork | null}): globalThis.Promise<{ scriptAddress?: string | null, scriptHash?: string | null, } | null> | { scriptAddress?: string | null, scriptHash?: string | null, } | null
532
510
  // metadata (do not use)
533
- __parameters: {validatorScript?: string | null, scriptParamsJson?: string | null, network?: string | null}, __returns: globalThis.Promise<{ scriptAddress?: string | null, scriptHash?: string | null, } | null> | { scriptAddress?: string | null, scriptHash?: string | null, } | null, __self: never
511
+ __parameters: {validatorScript?: string | null, scriptParamsJson?: string | null, network?: _.CardanoNetwork | null}, __returns: globalThis.Promise<{ scriptAddress?: string | null, scriptHash?: string | null, } | null> | { scriptAddress?: string | null, scriptHash?: string | null, } | null, __self: never
534
512
  kind: 'action'
535
513
  }
536
514
 
@@ -2,22 +2,6 @@
2
2
  import * as _ from './..';
3
3
  import * as __ from './../_';
4
4
 
5
- /**
6
- * Cardano Wallet Worker Service (v2.0)
7
- *
8
- * Control + observability surface for the wallet worker / job engine:
9
- * - job submission (async build → sign → submit → confirm from server-side wallets)
10
- * - job status polling + cancellation
11
- * - read-only projections of jobs and registered worker wallets
12
- * - pause/resume of the local worker instance (admin)
13
- *
14
- * Security note: SubmitWalletJob executes value transfers with server-held keys —
15
- * the service requires authentication throughout; control actions and foreign-job
16
- * visibility are gated behind the Admin role. Jobs on HSM-backed wallets addition-
17
- * ally require the configured hsm.requiresRole (HSM_REQUIRES_ROLE), the same gate
18
- * the synchronous SignWithHsm path enforces. Keys are NEVER accepted or exposed
19
- * through this surface.
20
- */
21
5
  export default class {
22
6
  static readonly SubmitWalletJob: typeof SubmitWalletJob;
23
7
  static readonly CancelJob: typeof CancelJob;
@@ -165,11 +149,11 @@ export declare class jobFailed {
165
149
 
166
150
  export declare const SubmitWalletJob: {
167
151
  // positional
168
- (walletId: string | null, kind: string | null, requestJson: string | null, idempotencyKey: string | null, priority: number | null, notBefore: __.CdsTimestamp | null): globalThis.Promise<JobSubmissionResult | null> | JobSubmissionResult | null
152
+ (walletId: string | null, kind: _.WalletJobKind | null, requestJson: string | null, idempotencyKey: string | null, priority: number | null, notBefore: __.CdsTimestamp | null): globalThis.Promise<JobSubmissionResult | null> | JobSubmissionResult | null
169
153
  // named
170
- ({walletId, kind, requestJson, idempotencyKey, priority, notBefore}: {walletId?: string | null, kind?: string | null, requestJson?: string | null, idempotencyKey?: string | null, priority?: number | null, notBefore?: __.CdsTimestamp | null}): globalThis.Promise<JobSubmissionResult | null> | JobSubmissionResult | null
154
+ ({walletId, kind, requestJson, idempotencyKey, priority, notBefore}: {walletId?: string | null, kind?: _.WalletJobKind | null, requestJson?: string | null, idempotencyKey?: string | null, priority?: number | null, notBefore?: __.CdsTimestamp | null}): globalThis.Promise<JobSubmissionResult | null> | JobSubmissionResult | null
171
155
  // metadata (do not use)
172
- __parameters: {walletId?: string | null, kind?: string | null, requestJson?: string | null, idempotencyKey?: string | null, priority?: number | null, notBefore?: __.CdsTimestamp | null}, __returns: globalThis.Promise<JobSubmissionResult | null> | JobSubmissionResult | null, __self: never
156
+ __parameters: {walletId?: string | null, kind?: _.WalletJobKind | null, requestJson?: string | null, idempotencyKey?: string | null, priority?: number | null, notBefore?: __.CdsTimestamp | null}, __returns: globalThis.Promise<JobSubmissionResult | null> | JobSubmissionResult | null, __self: never
173
157
  kind: 'action'
174
158
  }
175
159
 
@@ -84,6 +84,23 @@ export const WorkerSignerType: {
84
84
  }
85
85
  export type WorkerSignerType = "hsm" | "software"
86
86
 
87
+ // enum
88
+ export const CardanoNetwork: {
89
+ mainnet: "mainnet",
90
+ preview: "preview",
91
+ preprod: "preprod",
92
+ }
93
+ export type CardanoNetwork = "mainnet" | "preview" | "preprod"
94
+
95
+ // enum
96
+ export const UtxoSetImportSource: {
97
+ ogmios: "ogmios",
98
+ file: "file",
99
+ aggregates: "aggregates",
100
+ scripts: "scripts",
101
+ }
102
+ export type UtxoSetImportSource = "ogmios" | "file" | "aggregates" | "scripts"
103
+
87
104
  // the following represents the CDS aspect 'cuid'
88
105
  export declare function _cuidAspect<TBase extends new (...args: any[]) => object>(Base: TBase): {
89
106
  new (...args: any[]): {
@@ -46,3 +46,5 @@ module.exports.ReorgStatus ??= { detected: "detected", rolling_back: "rolling_ba
46
46
  module.exports.WalletJobStatus ??= { pending: "pending", building: "building", submitting: "submitting", submitted: "submitted", confirmed: "confirmed", failed: "failed", cancelled: "cancelled" }
47
47
  module.exports.WalletJobKind ??= { simpleAda: "simpleAda", metadata: "metadata", multiAsset: "multiAsset", mint: "mint", plutusSpend: "plutusSpend", submitSigned: "submitSigned" }
48
48
  module.exports.WorkerSignerType ??= { hsm: "hsm", software: "software" }
49
+ module.exports.CardanoNetwork ??= { mainnet: "mainnet", preview: "preview", preprod: "preprod" }
50
+ module.exports.UtxoSetImportSource ??= { ogmios: "ogmios", file: "file", aggregates: "aggregates", scripts: "scripts" }
@@ -218,6 +218,7 @@ export declare function _AssetAspect<TBase extends new (...args: any[]) => objec
218
218
  registryName?: string | null
219
219
  registryTicker?: string | null
220
220
  registryDecimals?: number | null
221
+ decimals?: number | null
221
222
  registryDescription?: string | null
222
223
  registryUrl?: string | null
223
224
  registryLogo?: string | null
@@ -1331,28 +1332,8 @@ export declare function _CardanoAgentGrantAspect<TBase extends new (...args: any
1331
1332
  readonly elements: __.ElementsOf<CardanoAgentGrant>;
1332
1333
  readonly actions: globalThis.Record<never, never>;
1333
1334
  };
1334
- /**
1335
- * Agent grants (v2.0): scoped bearer capabilities an Admin hands to an agent
1336
- * instead of a full user. The token is a capability, not an identity — it is
1337
- * stored as SHA-256 only, and a request carrying it runs as the principal
1338
- * `agent:<ID>` with the role `agent-grant`, never as the operator. Enforcement
1339
- * (allow list, wallet pinning, daily budget) lives in srv/utils/agent-grants.ts;
1340
- * the transport lane that admits `x-agent-token` in srv/utils/agent-token-auth.ts.
1341
- * Admin-only table: creation and revocation happen through CardanoAgentService
1342
- * actions, a token request may read its own row only.
1343
- */
1344
1335
  export class CardanoAgentGrant extends _CardanoAgentGrantAspect(__.Entity) {
1345
1336
  }
1346
- /**
1347
- * Agent grants (v2.0): scoped bearer capabilities an Admin hands to an agent
1348
- * instead of a full user. The token is a capability, not an identity — it is
1349
- * stored as SHA-256 only, and a request carrying it runs as the principal
1350
- * `agent:<ID>` with the role `agent-grant`, never as the operator. Enforcement
1351
- * (allow list, wallet pinning, daily budget) lives in srv/utils/agent-grants.ts;
1352
- * the transport lane that admits `x-agent-token` in srv/utils/agent-token-auth.ts.
1353
- * Admin-only table: creation and revocation happen through CardanoAgentService
1354
- * actions, a token request may read its own row only.
1355
- */
1356
1337
  export class CardanoAgentGrants extends Array<CardanoAgentGrant> {
1357
1338
  $count?: number
1358
1339
  }
@@ -1373,22 +1354,8 @@ export declare function _CardanoAgentGrantUsageAspect<TBase extends new (...args
1373
1354
  readonly elements: __.ElementsOf<CardanoAgentGrantUsage>;
1374
1355
  readonly actions: globalThis.Record<never, never>;
1375
1356
  };
1376
- /**
1377
- * Daily per-action counters of admitted calls under a grant (feeds
1378
- * CardanoAgentService.GetGrantUsage). Written by the enforcement hook next to
1379
- * the daily budget: `calls + 1` when a call is admitted, `refunded + 1` when the
1380
- * handler then refuses its input. Not exposed as an entity — the function is
1381
- * the contract. A few dozen rows per grant and day at most; no retention job yet.
1382
- */
1383
1357
  export class CardanoAgentGrantUsage extends _CardanoAgentGrantUsageAspect(__.Entity) {
1384
1358
  }
1385
- /**
1386
- * Daily per-action counters of admitted calls under a grant (feeds
1387
- * CardanoAgentService.GetGrantUsage). Written by the enforcement hook next to
1388
- * the daily budget: `calls + 1` when a call is admitted, `refunded + 1` when the
1389
- * handler then refuses its input. Not exposed as an entity — the function is
1390
- * the contract. A few dozen rows per grant and day at most; no retention job yet.
1391
- */
1392
1359
  export class CardanoAgentGrantUsage_ extends Array<CardanoAgentGrantUsage> {
1393
1360
  $count?: number
1394
1361
  }
package/README.md CHANGED
@@ -103,13 +103,13 @@ Service available at `http://localhost:4004`. See the [Quick Start Guide](docs/Q
103
103
  | Service | Path | Purpose |
104
104
  |---|---|---|
105
105
  | CardanoODataService | `/odata/v4/cardano/` | Read blockchain data (32 entities, 21 actions) |
106
- | CardanoTransactionService | `/odata/v4/cardano-transaction/` | Build & submit transactions (13 actions) |
106
+ | CardanoTransactionService | `/odata/v4/cardano-transaction/` | Build & submit transactions (14 actions) |
107
107
  | CardanoSignService | `/odata/v4/cardano-sign/` | External signing + HSM (9 actions) |
108
- | CardanoIndexerService | `/odata/v4/cardano-indexer/` | Chain crawler / pre-sync control (v2.0, off by default) |
109
- | CardanoWorkerService | `/odata/v4/cardano-worker/` | Asynchronous wallet jobs (v2.0, off by default) |
110
- | CardanoAgentService | `/odata/v4/cardano-agent/` | Agent grants: scoped bearer tokens for agents (v2.0, off by default) |
108
+ | CardanoIndexerService | `/odata/v4/cardano-indexer/` | Chain crawler / pre-sync control (off by default) |
109
+ | CardanoWorkerService | `/odata/v4/cardano-worker/` | Asynchronous wallet jobs (off by default) |
110
+ | CardanoAgentService | `/odata/v4/cardano-agent/` | Agent grants: scoped bearer tokens for agents (off by default) |
111
111
 
112
- Both v2.0 services also publish **CAP events**, so a consumer can subscribe instead of polling —
112
+ Both services also publish **CAP events**, so a consumer can subscribe instead of polling —
113
113
  in-process, no broker required:
114
114
 
115
115
  ```js
@@ -117,7 +117,7 @@ in-process, no broker required:
117
117
  (await cds.connect.to('CardanoIndexerService')).on('blockIndexed', ({ data }) => …)
118
118
  ```
119
119
 
120
- ## Agent grants (v2.0, off by default)
120
+ ## Agent grants (off by default)
121
121
 
122
122
  Hand an agent a **scoped, budgeted token** instead of a user.
123
123