@meshsdk/core 1.5.25 → 1.5.29

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 (91) hide show
  1. package/README.md +3 -30
  2. package/dist/index.d.mts +129 -0
  3. package/dist/index.d.ts +129 -11
  4. package/dist/index.js +149 -0
  5. package/dist/index.mjs +91 -0
  6. package/package.json +32 -59
  7. package/dist/common/constants.d.ts +0 -58
  8. package/dist/common/contracts/evaluator.d.ts +0 -4
  9. package/dist/common/contracts/fetcher.d.ts +0 -22
  10. package/dist/common/contracts/index.d.ts +0 -7
  11. package/dist/common/contracts/initiator.d.ts +0 -8
  12. package/dist/common/contracts/listener.d.ts +0 -3
  13. package/dist/common/contracts/signer.d.ts +0 -8
  14. package/dist/common/contracts/submitter.d.ts +0 -3
  15. package/dist/common/contracts/uploader.d.ts +0 -3
  16. package/dist/common/decorators.d.ts +0 -16
  17. package/dist/common/helpers/generateNonce.d.ts +0 -1
  18. package/dist/common/helpers/index.d.ts +0 -4
  19. package/dist/common/helpers/mergeSignatures.d.ts +0 -3
  20. package/dist/common/helpers/readPlutusData.d.ts +0 -2
  21. package/dist/common/helpers/readTransaction.d.ts +0 -2
  22. package/dist/common/types/Account.d.ts +0 -5
  23. package/dist/common/types/AccountInfo.d.ts +0 -7
  24. package/dist/common/types/Action.d.ts +0 -12
  25. package/dist/common/types/Asset.d.ts +0 -7
  26. package/dist/common/types/AssetExtended.d.ts +0 -8
  27. package/dist/common/types/AssetMetadata.d.ts +0 -24
  28. package/dist/common/types/BlockInfo.d.ts +0 -17
  29. package/dist/common/types/Data.d.ts +0 -4
  30. package/dist/common/types/DataSignature.d.ts +0 -4
  31. package/dist/common/types/Era.d.ts +0 -1
  32. package/dist/common/types/Mint.d.ts +0 -10
  33. package/dist/common/types/NativeScript.d.ts +0 -14
  34. package/dist/common/types/Network.d.ts +0 -4
  35. package/dist/common/types/PlutusScript.d.ts +0 -6
  36. package/dist/common/types/PoolParams.d.ts +0 -16
  37. package/dist/common/types/Protocol.d.ts +0 -22
  38. package/dist/common/types/Recipient.d.ts +0 -11
  39. package/dist/common/types/Relay.d.ts +0 -13
  40. package/dist/common/types/Token.d.ts +0 -2
  41. package/dist/common/types/TransactionInfo.d.ts +0 -11
  42. package/dist/common/types/UTxO.d.ts +0 -15
  43. package/dist/common/types/Wallet.d.ts +0 -5
  44. package/dist/common/types/index.d.ts +0 -22
  45. package/dist/common/utils/builder.d.ts +0 -18
  46. package/dist/common/utils/converter.d.ts +0 -27
  47. package/dist/common/utils/deserializer.d.ts +0 -19
  48. package/dist/common/utils/index.d.ts +0 -5
  49. package/dist/common/utils/parser.d.ts +0 -5
  50. package/dist/common/utils/resolver.d.ts +0 -19
  51. package/dist/core/CIP14.d.ts +0 -2
  52. package/dist/core/CIP1852.d.ts +0 -4
  53. package/dist/core/CIP1853.d.ts +0 -1
  54. package/dist/core/CIP1855.d.ts +0 -1
  55. package/dist/core/CIP2.d.ts +0 -4
  56. package/dist/core/CIP25.d.ts +0 -19
  57. package/dist/core/CIP27.d.ts +0 -4
  58. package/dist/core/CIP8.d.ts +0 -15
  59. package/dist/core/CPS-009.d.ts +0 -2
  60. package/dist/core/CSL.d.ts +0 -147
  61. package/dist/core/index.d.ts +0 -9
  62. package/dist/core.cjs +0 -8
  63. package/dist/core.js +0 -5995
  64. package/dist/providers/blockfrost.provider.d.ts +0 -46
  65. package/dist/providers/index.d.ts +0 -6
  66. package/dist/providers/infura.provider.d.ts +0 -12
  67. package/dist/providers/koios.provider.d.ts +0 -27
  68. package/dist/providers/maestro.provider.d.ts +0 -35
  69. package/dist/providers/ogmios.provider.d.ts +0 -12
  70. package/dist/providers/tango.provider.d.ts +0 -25
  71. package/dist/providers/yaci.provider.d.ts +0 -32
  72. package/dist/scripts/forge.script.d.ts +0 -8
  73. package/dist/scripts/index.d.ts +0 -1
  74. package/dist/transaction/index.d.ts +0 -2
  75. package/dist/transaction/meshTxBuilder/index.d.ts +0 -2
  76. package/dist/transaction/meshTxBuilder/meshTxBuilder.service.d.ts +0 -47
  77. package/dist/transaction/meshTxBuilder/meshTxBuilder.spec.d.ts +0 -1
  78. package/dist/transaction/meshTxBuilder/meshTxBuilderCore.d.ts +0 -321
  79. package/dist/transaction/meshTxBuilder/type.d.ts +0 -146
  80. package/dist/transaction/transaction.service.d.ts +0 -157
  81. package/dist/transaction/transaction.service.spec.d.ts +0 -1
  82. package/dist/wallet/app.service.d.ts +0 -45
  83. package/dist/wallet/app.service.spec.d.ts +0 -1
  84. package/dist/wallet/browser.service.d.ts +0 -218
  85. package/dist/wallet/browser.service.spec.d.ts +0 -1
  86. package/dist/wallet/embedded.service.d.ts +0 -21
  87. package/dist/wallet/embedded.service.spec.d.ts +0 -1
  88. package/dist/wallet/index.d.ts +0 -4
  89. package/dist/wallet/mesh.service.d.ts +0 -193
  90. package/dist/wallet/mina.service.d.ts +0 -11
  91. package/dist/wallet/mina.service.spec.d.ts +0 -1
@@ -1,58 +0,0 @@
1
- import { csl } from '@mesh/core';
2
- import type { Costmdls } from '@mesh/core';
3
- import type { Budget, Era, Network, Protocol } from './types';
4
- export declare const DEFAULT_REDEEMER_BUDGET: Budget;
5
- export declare const DEFAULT_PROTOCOL_PARAMETERS: Protocol;
6
- export declare const HARDENED_KEY_START = 2147483648;
7
- export declare const LANGUAGE_VERSIONS: {
8
- V1: csl.Language;
9
- V2: csl.Language;
10
- };
11
- export declare const POLICY_ID_LENGTH = 56;
12
- export declare const REDEEMER_TAGS: {
13
- CERT: csl.RedeemerTag;
14
- MINT: csl.RedeemerTag;
15
- REWARD: csl.RedeemerTag;
16
- SPEND: csl.RedeemerTag;
17
- };
18
- export declare const SUPPORTED_CLOCKS: Record<Network, [
19
- epoch: string,
20
- slot: string,
21
- systemStart: string,
22
- epochLength: string
23
- ]>;
24
- export declare const SUPPORTED_COST_MODELS: Record<Era, Costmdls>;
25
- export declare const SUPPORTED_LANGUAGE_VIEWS: Record<Era, Partial<Record<keyof typeof LANGUAGE_VERSIONS, string>>>;
26
- export declare const SUPPORTED_HANDLES: Record<number, string>;
27
- export declare const SUPPORTED_OGMIOS_LINKS: Record<Network, string>;
28
- export declare const SUPPORTED_TOKENS: {
29
- LQ: string;
30
- MIN: string;
31
- NTX: string;
32
- iBTC: string;
33
- iETH: string;
34
- iUSD: string;
35
- MILK: string;
36
- AGIX: string;
37
- MELD: string;
38
- INDY: string;
39
- CLAY: string;
40
- MCOS: string;
41
- DING: string;
42
- GERO: string;
43
- NMKR: string;
44
- PAVIA: string;
45
- HOSKY: string;
46
- YUMMI: string;
47
- C3: string;
48
- GIMBAL: string;
49
- SUNDAE: string;
50
- GREENS: string;
51
- GENS: string;
52
- SOCIETY: string;
53
- DJED: string;
54
- SHEN: string;
55
- WMT: string;
56
- COPI: string;
57
- };
58
- export declare const SUPPORTED_WALLETS: string[];
@@ -1,4 +0,0 @@
1
- import { Action } from '@mesh/common/types';
2
- export interface IEvaluator {
3
- evaluateTx(tx: string): Promise<Omit<Action, 'data'>[]>;
4
- }
@@ -1,22 +0,0 @@
1
- import type { AccountInfo, Asset, AssetMetadata, BlockInfo, Protocol, TransactionInfo, UTxO } from '@mesh/common/types';
2
- /**
3
- * Fetcher interface defines end points to query blockchain data.
4
- */
5
- export interface IFetcher {
6
- fetchAccountInfo(address: string): Promise<AccountInfo>;
7
- fetchAddressUTxOs(address: string, asset?: string): Promise<UTxO[]>;
8
- fetchAssetAddresses(asset: string): Promise<{
9
- address: string;
10
- quantity: string;
11
- }[]>;
12
- fetchAssetMetadata(asset: string): Promise<AssetMetadata>;
13
- fetchBlockInfo(hash: string): Promise<BlockInfo>;
14
- fetchCollectionAssets(policyId: string, cursor?: number | string): Promise<{
15
- assets: Asset[];
16
- next: string | number | null;
17
- }>;
18
- fetchHandleAddress(handle: string): Promise<string>;
19
- fetchProtocolParameters(epoch: number): Promise<Protocol>;
20
- fetchTxInfo(hash: string): Promise<TransactionInfo>;
21
- fetchUTxOs(hash: string): Promise<UTxO[]>;
22
- }
@@ -1,7 +0,0 @@
1
- export * from './evaluator';
2
- export * from './fetcher';
3
- export * from './initiator';
4
- export * from './listener';
5
- export * from './signer';
6
- export * from './submitter';
7
- export * from './uploader';
@@ -1,8 +0,0 @@
1
- import type { Address, TransactionUnspentOutput } from '@mesh/core';
2
- export interface IInitiator {
3
- getUsedAddress(): SometimesPromise<Address>;
4
- getUsedCollateral(limit?: number): SometimesPromise<TransactionUnspentOutput[]>;
5
- getUsedUTxOs(): SometimesPromise<TransactionUnspentOutput[]>;
6
- }
7
- type SometimesPromise<T> = Promise<T> | T;
8
- export {};
@@ -1,3 +0,0 @@
1
- export interface IListener {
2
- onTxConfirmed(txHash: string, callback: () => void, limit?: number): void;
3
- }
@@ -1,8 +0,0 @@
1
- import { DataSignature } from '@mesh/common/types';
2
- export interface ISigner {
3
- signData(address: string, payload: string): SometimesPromise<DataSignature>;
4
- signTx(unsignedTx: string, partialSign: boolean): SometimesPromise<string>;
5
- signTxs(unsignedTxs: string[], partialSign: boolean): SometimesPromise<string[]>;
6
- }
7
- type SometimesPromise<T> = Promise<T> | T;
8
- export {};
@@ -1,3 +0,0 @@
1
- export interface ISubmitter {
2
- submitTx(tx: string): Promise<string>;
3
- }
@@ -1,3 +0,0 @@
1
- export interface IUploader {
2
- uploadContent(content: FormData, recursive: boolean): Promise<string>;
3
- }
@@ -1,16 +0,0 @@
1
- export declare const Trackable: <T extends new (...args: any[]) => Object>(constructor: T) => {
2
- new (...args: any[]): {
3
- __visits: never[];
4
- constructor: Function;
5
- toString(): string;
6
- toLocaleString(): string;
7
- valueOf(): Object;
8
- hasOwnProperty(v: PropertyKey): boolean;
9
- isPrototypeOf(v: Object): boolean;
10
- propertyIsEnumerable(v: PropertyKey): boolean;
11
- };
12
- } & T;
13
- export declare const Checkpoint: () => (_target: Object, propertyKey: string | symbol, descriptor: PropertyDescriptor) => void;
14
- export interface TrackableObject {
15
- __visits: unknown[];
16
- }
@@ -1 +0,0 @@
1
- export declare const generateNonce: (label?: string, length?: number) => string;
@@ -1,4 +0,0 @@
1
- export * from './generateNonce';
2
- export * from './mergeSignatures';
3
- export * from './readPlutusData';
4
- export * from './readTransaction';
@@ -1,3 +0,0 @@
1
- import { csl } from '@mesh/core';
2
- import type { TransactionWitnessSet, Vkeywitnesses } from '@mesh/core';
3
- export declare const mergeSignatures: (txWitnessSet: TransactionWitnessSet, newSignatures: Vkeywitnesses) => csl.Vkeywitnesses;
@@ -1,2 +0,0 @@
1
- import type { Data } from '@mesh/common/types';
2
- export declare const readPlutusData: (plutusData: string) => Data;
@@ -1,2 +0,0 @@
1
- import { csl } from '@mesh/core';
2
- export declare const readTransaction: (tx: string) => csl.TransactionJSON;
@@ -1,5 +0,0 @@
1
- export type Account = {
2
- baseAddress: string;
3
- enterpriseAddress: string;
4
- rewardAddress: string;
5
- };
@@ -1,7 +0,0 @@
1
- export type AccountInfo = {
2
- active: boolean;
3
- poolId?: string;
4
- balance: string;
5
- rewards: string;
6
- withdrawals: string;
7
- };
@@ -1,12 +0,0 @@
1
- import { REDEEMER_TAGS } from '@mesh/common/constants';
2
- import { Data } from './Data';
3
- export type Action = {
4
- data: Data;
5
- index: number;
6
- budget: Budget;
7
- tag: keyof typeof REDEEMER_TAGS;
8
- };
9
- export type Budget = {
10
- mem: number;
11
- steps: number;
12
- };
@@ -1,7 +0,0 @@
1
- export type Asset = {
2
- unit: Unit;
3
- quantity: Quantity;
4
- };
5
- export type Unit = string;
6
- export type Quantity = string;
7
- export declare const mergeAssets: (assets: Asset[]) => Asset[];
@@ -1,8 +0,0 @@
1
- import { Quantity, Unit } from './Asset';
2
- export type AssetExtended = {
3
- unit: Unit;
4
- policyId: string;
5
- assetName: string;
6
- fingerprint: string;
7
- quantity: Quantity;
8
- };
@@ -1,24 +0,0 @@
1
- import type { MetadataStandard, Files, RoyaltiesStandard } from '@mesh/core';
2
- export type AssetMetadata = FungibleAssetMetadata | NonFungibleAssetMetadata | RoyaltiesStandard;
3
- export type FungibleAssetMetadata = MetadataStandard & {
4
- ticker: string;
5
- decimals: number;
6
- version: `${number}.${number}`;
7
- };
8
- export type NonFungibleAssetMetadata = AudioAssetMetadata | ImageAssetMetadata | SmartAssetMetadata | VideoAssetMetadata;
9
- type AudioAssetMetadata = MetadataStandard & Files;
10
- export type ImageAssetMetadata = MetadataStandard & Files & {
11
- artists?: [
12
- {
13
- name: string;
14
- twitter?: `https://twitter.com/${string}`;
15
- }
16
- ];
17
- attributes?: {
18
- [key: string]: string;
19
- };
20
- traits?: string[];
21
- };
22
- type SmartAssetMetadata = MetadataStandard & Files;
23
- type VideoAssetMetadata = MetadataStandard & Files;
24
- export {};
@@ -1,17 +0,0 @@
1
- export type BlockInfo = {
2
- time: number;
3
- hash: string;
4
- slot: string;
5
- epoch: number;
6
- epochSlot: string;
7
- slotLeader: string;
8
- size: number;
9
- txCount: number;
10
- output: string;
11
- fees: string;
12
- previousBlock: string;
13
- nextBlock: string;
14
- confirmations: number;
15
- operationalCertificate: string;
16
- VRFKey: string;
17
- };
@@ -1,4 +0,0 @@
1
- export type Data = string | number | bigint | Array<Data> | Map<Data, Data> | {
2
- alternative: number;
3
- fields: Array<Data>;
4
- };
@@ -1,4 +0,0 @@
1
- export type DataSignature = {
2
- signature: string;
3
- key: string;
4
- };
@@ -1 +0,0 @@
1
- export type Era = 'ALONZO' | 'BABBAGE';
@@ -1,10 +0,0 @@
1
- import { Quantity } from './Asset';
2
- import { AssetMetadata } from './AssetMetadata';
3
- import { Recipient } from './Recipient';
4
- export type Mint = {
5
- assetName: string;
6
- assetQuantity: Quantity;
7
- metadata: AssetMetadata;
8
- recipient: Recipient;
9
- label: '20' | '721' | '777' | `${number}`;
10
- };
@@ -1,14 +0,0 @@
1
- export type NativeScript = {
2
- type: 'after' | 'before';
3
- slot: string;
4
- } | {
5
- type: 'all' | 'any';
6
- scripts: NativeScript[];
7
- } | {
8
- type: 'atLeast';
9
- required: number;
10
- scripts: NativeScript[];
11
- } | {
12
- type: 'sig';
13
- keyHash: string;
14
- };
@@ -1,4 +0,0 @@
1
- declare const ALL_NETWORKS: readonly ["testnet", "preview", "preprod", "mainnet"];
2
- export type Network = typeof ALL_NETWORKS[number];
3
- export declare const isNetwork: (value: unknown) => value is "testnet" | "preview" | "preprod" | "mainnet";
4
- export {};
@@ -1,6 +0,0 @@
1
- import { LANGUAGE_VERSIONS } from '../constants';
2
- export type PlutusScript = {
3
- version: LanguageVersion;
4
- code: string;
5
- };
6
- export type LanguageVersion = keyof typeof LANGUAGE_VERSIONS;
@@ -1,16 +0,0 @@
1
- import { Relay } from './Relay';
2
- export type PoolParams = {
3
- VRFKeyHash: string;
4
- operator: string;
5
- pledge: string;
6
- cost: string;
7
- margin: number;
8
- relays: Relay[];
9
- owners: string[];
10
- rewardAddress: string;
11
- metadata?: PoolMetadata;
12
- };
13
- export type PoolMetadata = {
14
- URL: string;
15
- hash: string;
16
- };
@@ -1,22 +0,0 @@
1
- export type Protocol = {
2
- epoch: number;
3
- minFeeA: number;
4
- minFeeB: number;
5
- maxBlockSize: number;
6
- maxTxSize: number;
7
- maxBlockHeaderSize: number;
8
- keyDeposit: string;
9
- poolDeposit: string;
10
- decentralisation: number;
11
- minPoolCost: string;
12
- priceMem: number;
13
- priceStep: number;
14
- maxTxExMem: string;
15
- maxTxExSteps: string;
16
- maxBlockExMem: string;
17
- maxBlockExSteps: string;
18
- maxValSize: string;
19
- collateralPercent: number;
20
- maxCollateralInputs: number;
21
- coinsPerUTxOSize: string;
22
- };
@@ -1,11 +0,0 @@
1
- import { Data } from './Data';
2
- import { NativeScript } from './NativeScript';
3
- import { PlutusScript } from './PlutusScript';
4
- export type Recipient = string | {
5
- address: string;
6
- datum?: {
7
- value: Data;
8
- inline?: boolean;
9
- };
10
- script?: PlutusScript | NativeScript;
11
- };
@@ -1,13 +0,0 @@
1
- export type Relay = {
2
- type: 'SingleHostAddr';
3
- IPV4?: string;
4
- IPV6?: string;
5
- port?: number;
6
- } | {
7
- type: 'SingleHostName';
8
- domainName: string;
9
- port?: number;
10
- } | {
11
- type: 'MultiHostName';
12
- domainName: string;
13
- };
@@ -1,2 +0,0 @@
1
- import { SUPPORTED_TOKENS } from '@mesh/common/constants';
2
- export type Token = keyof typeof SUPPORTED_TOKENS;
@@ -1,11 +0,0 @@
1
- export type TransactionInfo = {
2
- index: number;
3
- block: string;
4
- hash: string;
5
- slot: string;
6
- fees: string;
7
- size: number;
8
- deposit: string;
9
- invalidBefore: string;
10
- invalidAfter: string;
11
- };
@@ -1,15 +0,0 @@
1
- import { Asset } from './Asset';
2
- export type UTxO = {
3
- input: {
4
- outputIndex: number;
5
- txHash: string;
6
- };
7
- output: {
8
- address: string;
9
- amount: Asset[];
10
- dataHash?: string;
11
- plutusData?: string;
12
- scriptRef?: string;
13
- scriptHash?: string;
14
- };
15
- };
@@ -1,5 +0,0 @@
1
- export type Wallet = {
2
- name: string;
3
- icon: string;
4
- version: string;
5
- };
@@ -1,22 +0,0 @@
1
- export * from './Account';
2
- export * from './AccountInfo';
3
- export * from './Action';
4
- export * from './Asset';
5
- export * from './AssetExtended';
6
- export * from './AssetMetadata';
7
- export * from './BlockInfo';
8
- export * from './Data';
9
- export * from './DataSignature';
10
- export * from './Era';
11
- export * from './Mint';
12
- export * from './NativeScript';
13
- export * from './Network';
14
- export * from './PlutusScript';
15
- export * from './PoolParams';
16
- export * from './Protocol';
17
- export * from './Recipient';
18
- export * from './Relay';
19
- export * from './Token';
20
- export * from './TransactionInfo';
21
- export * from './UTxO';
22
- export * from './Wallet';
@@ -1,18 +0,0 @@
1
- import { csl } from '@mesh/core';
2
- import type { BaseAddress, Bip32PrivateKey, DataCost, DatumSource, Ed25519KeyHash, EnterpriseAddress, MintWitness, PlutusScriptSource, RewardAddress, TransactionBuilder, TransactionOutputBuilder, TxInputsBuilder } from '@mesh/core';
3
- import type { Action, Data, PlutusScript, Recipient, UTxO } from '@mesh/common/types';
4
- export declare const buildBaseAddress: (networkId: number, paymentKeyHash: Ed25519KeyHash, stakeKeyHash: Ed25519KeyHash) => BaseAddress;
5
- export declare const buildBip32PrivateKey: (entropy: string, password?: string) => Bip32PrivateKey;
6
- export declare const buildDataCost: (coinsPerByte: string) => DataCost;
7
- export declare const buildDatumSource: (datum: Data | UTxO) => DatumSource;
8
- export declare const buildEnterpriseAddress: (networkId: number, paymentKeyHash: Ed25519KeyHash) => EnterpriseAddress;
9
- export declare const buildGeneralTxMetadata: (metadata: Record<string, unknown>) => csl.GeneralTransactionMetadata;
10
- export declare const buildMintWitness: (script: string | PlutusScript | UTxO, redeemer?: Partial<Action>) => MintWitness;
11
- export declare const buildRewardAddress: (networkId: number, stakeKeyHash: Ed25519KeyHash) => RewardAddress;
12
- export declare const buildPlutusScriptSource: (script: PlutusScript | UTxO) => PlutusScriptSource;
13
- export declare const buildScriptPubkey: (keyHash: Ed25519KeyHash) => csl.NativeScript;
14
- export declare const buildTimelockExpiry: (slot: string) => csl.NativeScript;
15
- export declare const buildTimelockStart: (slot: string) => csl.NativeScript;
16
- export declare const buildTxBuilder: (parameters?: import("@mesh/common/types").Protocol) => TransactionBuilder;
17
- export declare const buildTxInputsBuilder: (utxos: unknown[]) => TxInputsBuilder;
18
- export declare const buildTxOutputBuilder: (recipient: Recipient) => TransactionOutputBuilder;
@@ -1,27 +0,0 @@
1
- import { csl } from '@mesh/core';
2
- import type { PlutusData, ScriptRef, TransactionUnspentOutput, Value } from '@mesh/core';
3
- import type { Action, Asset, Data, NativeScript, PlutusScript, PoolParams, Relay, UTxO } from '@mesh/common/types';
4
- export declare const toAddress: (bech32: string) => csl.Address;
5
- export declare const toBaseAddress: (bech32: string) => csl.BaseAddress | undefined;
6
- export declare const toEnterpriseAddress: (bech32: string) => csl.EnterpriseAddress | undefined;
7
- export declare const toRewardAddress: (bech32: string) => csl.RewardAddress | undefined;
8
- export declare const fromBytes: (bytes: Uint8Array) => string;
9
- export declare const toBytes: (hex: string) => Uint8Array;
10
- export declare const fromLovelace: (lovelace: number) => number;
11
- export declare const toLovelace: (ada: number) => number;
12
- export declare const fromNativeScript: (script: csl.NativeScript) => NativeScript;
13
- export declare const toNativeScript: (script: NativeScript) => csl.NativeScript;
14
- export declare const fromPlutusData: (plutusData: PlutusData) => Data;
15
- export declare const toPlutusData: (data: Data) => csl.PlutusData;
16
- export declare const toPoolParams: (params: PoolParams) => never;
17
- export declare const toRedeemer: (action: Action) => csl.Redeemer;
18
- export declare const toRelay: (relay: Relay) => csl.Relay;
19
- export declare const fromScriptRef: (scriptRef: ScriptRef) => NativeScript | PlutusScript;
20
- export declare const toScriptRef: (script: PlutusScript | NativeScript) => csl.ScriptRef;
21
- export declare const fromTxUnspentOutput: (txUnspentOutput: TransactionUnspentOutput) => UTxO;
22
- export declare const toTxUnspentOutput: (utxo: UTxO) => csl.TransactionUnspentOutput;
23
- export declare const toUnitInterval: (float: string) => csl.UnitInterval;
24
- export declare const fromUTF8: (utf8: string) => string;
25
- export declare const toUTF8: (hex: string) => string;
26
- export declare const fromValue: (value: Value) => Asset[];
27
- export declare const toValue: (assets: Asset[]) => csl.Value;
@@ -1,19 +0,0 @@
1
- import { csl } from '@mesh/core';
2
- import type { LanguageVersion } from '@mesh/common/types';
3
- export declare const deserializeAddress: (address: string) => csl.Address;
4
- export declare const deserializeBip32PrivateKey: (bip32PrivateKey: string) => csl.Bip32PrivateKey;
5
- export declare const deserializeDataHash: (dataHash: string) => csl.DataHash;
6
- export declare const deserializeEd25519KeyHash: (ed25519KeyHash: string) => csl.Ed25519KeyHash;
7
- export declare const deserializeEd25519Signature: (ed25519Signature: string) => csl.Ed25519Signature;
8
- export declare const deserializeNativeScript: (nativeScript: string) => csl.NativeScript;
9
- export declare const deserializePublicKey: (publicKey: string) => csl.PublicKey;
10
- export declare const deserializePlutusData: (plutusData: string) => csl.PlutusData;
11
- export declare const deserializePlutusScript: (plutusScript: string, version: LanguageVersion) => csl.PlutusScript;
12
- export declare const deserializeScriptRef: (scriptRef: string) => csl.ScriptRef;
13
- export declare const deserializeScriptHash: (scriptHash: string) => csl.ScriptHash;
14
- export declare const deserializeTx: (tx: string) => csl.Transaction;
15
- export declare const deserializeTxBody: (txBody: string) => csl.TransactionBody;
16
- export declare const deserializeTxHash: (txHash: string) => csl.TransactionHash;
17
- export declare const deserializeTxUnspentOutput: (txUnspentOutput: string) => csl.TransactionUnspentOutput;
18
- export declare const deserializeTxWitnessSet: (txWitnessSet: string) => csl.TransactionWitnessSet;
19
- export declare const deserializeValue: (value: string) => csl.Value;
@@ -1,5 +0,0 @@
1
- export * from './builder';
2
- export * from './converter';
3
- export * from './deserializer';
4
- export * from './parser';
5
- export * from './resolver';
@@ -1,5 +0,0 @@
1
- export declare const parseAssetUnit: (unit: string) => {
2
- policyId: string;
3
- assetName: string;
4
- };
5
- export declare const parseHttpError: (error: unknown) => string;
@@ -1,19 +0,0 @@
1
- import type { Data, Era, LanguageVersion, NativeScript, Network, PlutusScript } from '@mesh/common/types';
2
- export declare const resolveDataHash: (data: Data) => string;
3
- export declare const resolveEpochNo: (network: Network, milliseconds?: number) => number;
4
- export declare const resolveFingerprint: (policyId: string, assetName: string) => string;
5
- export declare const resolveLanguageView: (era: Era, version: LanguageVersion) => string | undefined;
6
- export declare const resolveNativeScriptAddress: (script: NativeScript, networkId?: number) => string;
7
- export declare const resolveNativeScriptHash: (script: NativeScript) => string;
8
- export declare const resolveNativeScriptHex: (script: NativeScript) => string;
9
- export declare const resolvePaymentKeyHash: (bech32: string) => string;
10
- export declare const resolvePlutusScriptAddress: (script: PlutusScript, networkId?: number) => string;
11
- export declare const resolvePlutusScriptHash: (bech32: string) => string;
12
- export declare const resolvePoolId: (hash: string) => string;
13
- export declare const resolvePrivateKey: (words: string[]) => string;
14
- export declare const resolveScriptRef: (script: PlutusScript | NativeScript) => string;
15
- export declare const resolveSlotNo: (network: Network, milliseconds?: number) => string;
16
- export declare const resolveRewardAddress: (bech32: string) => string;
17
- export declare const resolveStakeKeyHash: (bech32: string) => string;
18
- export declare const resolveTxFees: (txSize: number, minFeeA?: number, minFeeB?: number) => string;
19
- export declare const resolveTxHash: (txHex: string) => string;
@@ -1,2 +0,0 @@
1
- import CIP14 from '@emurgo/cip14-js';
2
- export declare const AssetFingerprint: typeof CIP14;
@@ -1,4 +0,0 @@
1
- export declare const deriveAccountKeys: (rootKey: string, accountIndex: number, keyIndex?: number) => {
2
- paymentKey: import("@emurgo/cardano-serialization-lib-nodejs").PrivateKey;
3
- stakeKey: import("@emurgo/cardano-serialization-lib-nodejs").PrivateKey;
4
- };
@@ -1 +0,0 @@
1
- export declare const deriveStakePoolColdKey: (rootKey: string, coldIndex: number) => import("@emurgo/cardano-serialization-lib-nodejs").PrivateKey;
@@ -1 +0,0 @@
1
- export declare const deriveForgingPolicyKey: (rootKey: string, policyIndex: number) => import("@emurgo/cardano-serialization-lib-nodejs").PrivateKey;
@@ -1,4 +0,0 @@
1
- import type { Protocol, Quantity, Unit, UTxO } from '@mesh/common/types';
2
- export declare const keepRelevant: (requestedOutputSet: Map<Unit, Quantity>, initialUTxOSet: UTxO[], minimumLovelaceRequired?: string) => UTxO[];
3
- export declare const largestFirst: (lovelace: Quantity, initialUTxOSet: UTxO[], includeTxFees?: boolean, { maxTxSize, minFeeA, minFeeB }?: Protocol) => UTxO[];
4
- export declare const largestFirstMultiAsset: (requestedOutputSet: Map<Unit, Quantity>, initialUTxOSet: UTxO[], includeTxFees?: boolean, parameters?: Protocol) => UTxO[];
@@ -1,19 +0,0 @@
1
- export type MetadataStandard = {
2
- name: string;
3
- image: `${string}://${string}`;
4
- mediaType?: `image/${string}`;
5
- description?: string | string[];
6
- instagram?: `https://instagram.com/${string}`;
7
- twitter?: `https://twitter.com/${string}`;
8
- discord?: `https://discord.gg/${string}`;
9
- website?: `https://${string}`;
10
- };
11
- export type Files = {
12
- files?: [
13
- {
14
- name: string;
15
- src: `${string}://${string}`;
16
- mediaType: `${string}/${string}`;
17
- }
18
- ];
19
- };
@@ -1,4 +0,0 @@
1
- export type RoyaltiesStandard = {
2
- rate: string;
3
- address: string;
4
- };
@@ -1,15 +0,0 @@
1
- import type { DataSignature } from '@mesh/common/types';
2
- import type { Address, PrivateKey } from '@mesh/core';
3
- export declare const signMessage: (message: Message, signer: Signer) => {
4
- coseKey: string;
5
- coseSign1: string;
6
- };
7
- export declare const checkSignature: (message: string, signer: string, { key, signature }: DataSignature) => boolean;
8
- export type Message = {
9
- payload: string;
10
- externalAAD?: string;
11
- };
12
- export type Signer = {
13
- address: Address;
14
- key: PrivateKey;
15
- };
@@ -1,2 +0,0 @@
1
- import type { Quantity, UTxO, Unit } from '@mesh/common/types';
2
- export declare const selectUtxos: (inputs: UTxO[], requiredAssets: Map<Unit, Quantity>, threshold: Quantity) => UTxO[];