@koralabs/kora-labs-common 6.15.1 → 6.15.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@koralabs/kora-labs-common",
3
- "version": "6.15.1",
3
+ "version": "6.15.3",
4
4
  "description": "Kora Labs Common Utilities",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -77,7 +77,7 @@
77
77
  "@cardano-sdk/core": "^0.46.12 || ^0.47.0",
78
78
  "@cardano-sdk/crypto": "^0.4.5",
79
79
  "@emurgo/cardano-message-signing-nodejs": "^1.1.0",
80
- "bip39": "^3.1.0",
80
+ "bip39": "^3.0.4",
81
81
  "cassandra-driver": "^4.9.0",
82
82
  "scalus": "^0.15.0"
83
83
  },
@@ -58,6 +58,11 @@ export declare class BlockfrostTxClient {
58
58
  getAddressAssetUtxos(address: string, unit: string): Promise<Cardano.Utxo[]>;
59
59
  /** The UTxO `txHash#index`; throws `already spent` when it has been consumed. */
60
60
  getUtxo(ref: string): Promise<Cardano.Utxo>;
61
+ /** A stake address's registration state; null when the chain has never seen it. */
62
+ getAccount(stakeAddress: string): Promise<{
63
+ stake_address: string;
64
+ active: boolean;
65
+ } | null>;
61
66
  /** Node (Ogmios) evaluation of every redeemer; `additionalUtxos` supplies inputs not yet on chain. */
62
67
  evaluateTx(cbor: string, additionalUtxos?: Cardano.Utxo[]): Promise<Map<RedeemerKey, ExUnits>>;
63
68
  /** Submit a signed tx; returns its hash. */
@@ -188,6 +188,10 @@ class BlockfrostTxClient {
188
188
  throw new Error(`${ref} already spent by ${output.consumed_by_tx}`);
189
189
  return this.toUtxo(output, txHash, output.address);
190
190
  }
191
+ /** A stake address's registration state; null when the chain has never seen it. */
192
+ getAccount(stakeAddress) {
193
+ return this.getOrNull(`accounts/${stakeAddress}`);
194
+ }
191
195
  /** Node (Ogmios) evaluation of every redeemer; `additionalUtxos` supplies inputs not yet on chain. */
192
196
  async evaluateTx(cbor, additionalUtxos = []) {
193
197
  var _a, _b, _c, _d, _e;