@anastasia-labs/cardano-multiplatform-lib-nodejs 6.0.2-1 → 6.0.2-2

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.
@@ -17,6 +17,18 @@ export function emip3_encrypt_with_password(password: string, salt: string, nonc
17
17
  */
18
18
  export function emip3_decrypt_with_password(password: string, data: string): string;
19
19
  /**
20
+ * encodes arbitrary bytes into chunks of 64 bytes (the limit for bytes) as a list to be valid Metadata
21
+ * @param {Uint8Array} bytes
22
+ * @returns {TransactionMetadatum}
23
+ */
24
+ export function encode_arbitrary_bytes_as_metadatum(bytes: Uint8Array): TransactionMetadatum;
25
+ /**
26
+ * decodes from chunks of bytes in a list to a byte vector if that is the metadata format, otherwise returns None
27
+ * @param {TransactionMetadatum} metadata
28
+ * @returns {Uint8Array | undefined}
29
+ */
30
+ export function decode_arbitrary_bytes_from_metadatum(metadata: TransactionMetadatum): Uint8Array | undefined;
31
+ /**
20
32
  * @param {AuxiliaryData} auxiliary_data
21
33
  * @returns {AuxiliaryDataHash}
22
34
  */
@@ -92,6 +104,33 @@ export function get_implicit_input(txbody: TransactionBody, pool_deposit: bigint
92
104
  */
93
105
  export function get_deposit(txbody: TransactionBody, pool_deposit: bigint, key_deposit: bigint): bigint;
94
106
  /**
107
+ *
108
+ * * Min fee for JUST the script, NOT including ref inputs
109
+ *
110
+ * @param {Transaction} tx
111
+ * @param {ExUnitPrices} ex_unit_prices
112
+ * @returns {bigint}
113
+ */
114
+ export function min_script_fee(tx: Transaction, ex_unit_prices: ExUnitPrices): bigint;
115
+ /**
116
+ * @param {Transaction} tx
117
+ * @param {LinearFee} linear_fee
118
+ * @returns {bigint}
119
+ */
120
+ export function min_no_script_fee(tx: Transaction, linear_fee: LinearFee): bigint;
121
+ /**
122
+ *
123
+ * * Calculates the cost of all ref scripts
124
+ * * * `total_ref_script_size` - Total size (original, not hashes) of all ref scripts. Duplicate scripts are counted as many times as they occur
125
+ *
126
+ * @param {Transaction} tx
127
+ * @param {LinearFee} linear_fee
128
+ * @param {ExUnitPrices} ex_unit_prices
129
+ * @param {bigint} total_ref_script_size
130
+ * @returns {bigint}
131
+ */
132
+ export function min_fee(tx: Transaction, linear_fee: LinearFee, ex_unit_prices: ExUnitPrices, total_ref_script_size: bigint): bigint;
133
+ /**
95
134
  * Converts JSON to Metadata according to MetadataJsonSchema
96
135
  * @param {string} json
97
136
  * @param {MetadataJsonSchema} schema
@@ -106,47 +145,11 @@ export function encode_json_str_to_metadatum(json: string, schema: MetadataJsonS
106
145
  */
107
146
  export function decode_metadatum_to_json_str(metadatum: TransactionMetadatum, schema: MetadataJsonSchema): string;
108
147
  /**
109
- * @param {string} json
110
- * @param {CardanoNodePlutusDatumSchema} schema
111
- * @returns {PlutusData}
112
- */
113
- export function encode_json_str_to_plutus_datum(json: string, schema: CardanoNodePlutusDatumSchema): PlutusData;
114
- /**
115
- * @param {PlutusData} datum
116
- * @param {CardanoNodePlutusDatumSchema} schema
117
- * @returns {string}
118
- */
119
- export function decode_plutus_datum_to_json_str(datum: PlutusData, schema: CardanoNodePlutusDatumSchema): string;
120
- /**
121
- * @param {TransactionOutput} output
122
- * @param {bigint} coins_per_utxo_byte
123
- * @returns {bigint}
124
- */
125
- export function min_ada_required(output: TransactionOutput, coins_per_utxo_byte: bigint): bigint;
126
- /**
127
148
  * @param {Redeemers} redeemers
128
149
  * @returns {ExUnits}
129
150
  */
130
151
  export function compute_total_ex_units(redeemers: Redeemers): ExUnits;
131
152
  /**
132
- * encodes arbitrary bytes into chunks of 64 bytes (the limit for bytes) as a list to be valid Metadata
133
- * @param {Uint8Array} bytes
134
- * @returns {TransactionMetadatum}
135
- */
136
- export function encode_arbitrary_bytes_as_metadatum(bytes: Uint8Array): TransactionMetadatum;
137
- /**
138
- * decodes from chunks of bytes in a list to a byte vector if that is the metadata format, otherwise returns None
139
- * @param {TransactionMetadatum} metadata
140
- * @returns {Uint8Array | undefined}
141
- */
142
- export function decode_arbitrary_bytes_from_metadatum(metadata: TransactionMetadatum): Uint8Array | undefined;
143
- /**
144
- * @param {TransactionHash} tx_body_hash
145
- * @param {PrivateKey} sk
146
- * @returns {Vkeywitness}
147
- */
148
- export function make_vkey_witness(tx_body_hash: TransactionHash, sk: PrivateKey): Vkeywitness;
149
- /**
150
153
  * @param {TransactionHash} tx_body_hash
151
154
  * @param {ByronAddress} addr
152
155
  * @param {LegacyDaedalusPrivateKey} key
@@ -161,50 +164,37 @@ export function make_daedalus_bootstrap_witness(tx_body_hash: TransactionHash, a
161
164
  */
162
165
  export function make_icarus_bootstrap_witness(tx_body_hash: TransactionHash, addr: ByronAddress, key: Bip32PrivateKey): BootstrapWitness;
163
166
  /**
164
- *
165
- * * Min fee for JUST the script, NOT including ref inputs
166
- *
167
- * @param {Transaction} tx
168
- * @param {ExUnitPrices} ex_unit_prices
169
- * @returns {bigint}
170
- */
171
- export function min_script_fee(tx: Transaction, ex_unit_prices: ExUnitPrices): bigint;
172
- /**
173
- * @param {Transaction} tx
174
- * @param {LinearFee} linear_fee
175
- * @returns {bigint}
167
+ * @param {TransactionHash} tx_body_hash
168
+ * @param {PrivateKey} sk
169
+ * @returns {Vkeywitness}
176
170
  */
177
- export function min_no_script_fee(tx: Transaction, linear_fee: LinearFee): bigint;
171
+ export function make_vkey_witness(tx_body_hash: TransactionHash, sk: PrivateKey): Vkeywitness;
178
172
  /**
179
- *
180
- * * Calculates the cost of all ref scripts
181
- * * * `total_ref_script_size` - Total size (original, not hashes) of all ref scripts. Duplicate scripts are counted as many times as they occur
182
- *
183
- * @param {Transaction} tx
184
- * @param {LinearFee} linear_fee
185
- * @param {ExUnitPrices} ex_unit_prices
186
- * @param {bigint} total_ref_script_size
173
+ * @param {TransactionOutput} output
174
+ * @param {bigint} coins_per_utxo_byte
187
175
  * @returns {bigint}
188
176
  */
189
- export function min_fee(tx: Transaction, linear_fee: LinearFee, ex_unit_prices: ExUnitPrices, total_ref_script_size: bigint): bigint;
177
+ export function min_ada_required(output: TransactionOutput, coins_per_utxo_byte: bigint): bigint;
190
178
  /**
179
+ * @param {string} json
180
+ * @param {CardanoNodePlutusDatumSchema} schema
181
+ * @returns {PlutusData}
191
182
  */
192
- export enum DelegationDistributionKind {
193
- Weighted = 0,
194
- Legacy = 1,
195
- }
183
+ export function encode_json_str_to_plutus_datum(json: string, schema: CardanoNodePlutusDatumSchema): PlutusData;
196
184
  /**
185
+ * @param {PlutusData} datum
186
+ * @param {CardanoNodePlutusDatumSchema} schema
187
+ * @returns {string}
197
188
  */
198
- export enum AuxiliaryDataKind {
199
- Shelley = 0,
200
- ShelleyMA = 1,
201
- Conway = 2,
202
- }
189
+ export function decode_plutus_datum_to_json_str(datum: PlutusData, schema: CardanoNodePlutusDatumSchema): string;
203
190
  /**
204
191
  */
205
- export enum ChunkableStringKind {
206
- Single = 0,
207
- Chunked = 1,
192
+ export enum AddressKind {
193
+ Base = 0,
194
+ Ptr = 1,
195
+ Enterprise = 2,
196
+ Reward = 3,
197
+ Byron = 4,
208
198
  }
209
199
  /**
210
200
  */
@@ -228,81 +218,126 @@ export enum CertificateKind {
228
218
  UpdateDrepCert = 16,
229
219
  }
230
220
  /**
221
+ * JSON <-> PlutusData conversion schemas.
222
+ * Follows ScriptDataJsonSchema in cardano-cli defined at:
223
+ * https://github.com/input-output-hk/cardano-node/blob/master/cardano-api/src/Cardano/Api/ScriptData.hs#L254
224
+ *
225
+ * All methods here have the following restrictions due to limitations on dependencies:
226
+ * * JSON numbers above u64::MAX (positive) or below i64::MIN (negative) will throw errors
227
+ * * Hex strings for bytes don't accept odd-length (half-byte) strings.
228
+ * cardano-cli seems to support these however but it seems to be different than just 0-padding
229
+ * on either side when tested so proceed with caution
231
230
  */
232
- export enum ScriptKind {
233
- Native = 0,
234
- PlutusV1 = 1,
235
- PlutusV2 = 2,
236
- PlutusV3 = 3,
237
- }
238
- /**
239
- */
240
- export enum AddressKind {
241
- Base = 0,
242
- Ptr = 1,
243
- Enterprise = 2,
244
- Reward = 3,
245
- Byron = 4,
246
- }
231
+ export enum CardanoNodePlutusDatumSchema {
247
232
  /**
248
- * Which version of the CIP25 spec to use. See CIP25 for details.
249
- * This will change how things are encoded but for the most part contains
250
- * the same information.
233
+ * ScriptDataJsonNoSchema in cardano-node.
234
+ *
235
+ * This is the format used by --script-data-value in cardano-cli
236
+ * This tries to accept most JSON but does not support the full spectrum of Plutus datums.
237
+ * From JSON:
238
+ * * null/true/false/floats NOT supported
239
+ * * strings starting with 0x are treated as hex bytes. All other strings are encoded as their utf8 bytes.
240
+ * To JSON:
241
+ * * ConstrPlutusData not supported in ANY FORM (neither keys nor values)
242
+ * * Lists not supported in keys
243
+ * * Maps not supported in keys
251
244
  */
252
- export enum CIP25Version {
245
+ BasicConversions = 0,
253
246
  /**
254
- * Initial version of CIP25 with only string (utf8) asset names allowed.
247
+ * ScriptDataJsonDetailedSchema in cardano-node.
248
+ *
249
+ * This is the format used by --script-data-file in cardano-cli
250
+ * This covers almost all (only minor exceptions) Plutus datums, but the JSON must conform to a strict schema.
251
+ * The schema specifies that ALL keys and ALL values must be contained in a JSON map with 2 cases:
252
+ * 1. For ConstrPlutusData there must be two fields "constructor" contianing a number and "fields" containing its fields
253
+ * e.g. { "constructor": 2, "fields": [{"int": 2}, {"list": [{"bytes": "CAFEF00D"}]}]}
254
+ * 2. For all other cases there must be only one field named "int", "bytes", "list" or "map"
255
+ * BigInteger's value is a JSON number e.g. {"int": 100}
256
+ * Bytes' value is a hex string representing the bytes WITHOUT any prefix e.g. {"bytes": "CAFEF00D"}
257
+ * Lists' value is a JSON list of its elements encoded via the same schema e.g. {"list": [{"bytes": "CAFEF00D"}]}
258
+ * Maps' value is a JSON list of objects, one for each key-value pair in the map, with keys "k" and "v"
259
+ * respectively with their values being the plutus datum encoded via this same schema
260
+ * e.g. {"map": [
261
+ * {"k": {"int": 2}, "v": {"int": 5}},
262
+ * {"k": {"map": [{"k": {"list": [{"int": 1}]}, "v": {"bytes": "FF03"}}]}, "v": {"list": []}}
263
+ * ]}
264
+ * From JSON:
265
+ * * null/true/false/floats NOT supported
266
+ * * the JSON must conform to a very specific schema
267
+ * To JSON:
268
+ * * all Plutus datums should be fully supported outside of the integer range limitations outlined above.
255
269
  */
256
- V1 = 0,
270
+ DetailedSchema = 1,
271
+ }
257
272
  /**
258
- * Second version of CIP25. Supports any type of asset names.
259
273
  */
260
- V2 = 1,
274
+ export enum Vote {
275
+ No = 0,
276
+ Yes = 1,
277
+ Abstain = 2,
261
278
  }
262
279
  /**
263
280
  */
264
- export enum DatumOptionKind {
265
- Hash = 0,
266
- Datum = 1,
281
+ export enum RedeemerTag {
282
+ Spend = 0,
283
+ Mint = 1,
284
+ Cert = 2,
285
+ Reward = 3,
286
+ Voting = 4,
287
+ Proposing = 5,
267
288
  }
268
289
  /**
290
+ * Careful: this enum doesn't include the network ID part of the header
291
+ * ex: base address isn't 0b0000_0000 but instead 0b0000
292
+ * Use `header_matches_kind` if you don't want to implement the bitwise operators yourself
269
293
  */
270
- export enum TransactionOutputKind {
271
- AlonzoFormatTxOut = 0,
272
- ConwayFormatTxOut = 1,
294
+ export enum AddressHeaderKind {
295
+ BasePaymentKeyStakeKey = 0,
296
+ BasePaymentScriptStakeKey = 1,
297
+ BasePaymentKeyStakeScript = 2,
298
+ BasePaymentScriptStakeScript = 3,
299
+ PointerKey = 4,
300
+ PointerScript = 5,
301
+ EnterpriseKey = 6,
302
+ EnterpriseScript = 7,
303
+ Byron = 8,
304
+ RewardKey = 14,
305
+ RewardScript = 15,
273
306
  }
274
307
  /**
275
308
  */
276
- export enum MetadataJsonSchema {
277
- NoConversions = 0,
278
- BasicConversions = 1,
279
- DetailedSchema = 2,
309
+ export enum StakeDistributionKind {
310
+ SingleKey = 0,
311
+ BootstrapEra = 1,
280
312
  }
281
313
  /**
282
314
  */
283
- export enum RelayKind {
284
- SingleHostAddr = 0,
285
- SingleHostName = 1,
286
- MultiHostName = 2,
315
+ export enum NonceKind {
316
+ Identity = 0,
317
+ Hash = 1,
287
318
  }
288
319
  /**
289
320
  */
290
- export enum DRepKind {
291
- Key = 0,
292
- Script = 1,
293
- AlwaysAbstain = 2,
294
- AlwaysNoConfidence = 3,
321
+ export enum SpendingDataKind {
322
+ SpendingDataPubKey = 0,
323
+ SpendingDataScript = 1,
324
+ SpendingDataRedeem = 2,
295
325
  }
296
326
  /**
297
327
  */
298
- export enum StakeDistributionKind {
299
- SingleKey = 0,
300
- BootstrapEra = 1,
328
+ export enum ChunkableStringKind {
329
+ Single = 0,
330
+ Chunked = 1,
301
331
  }
302
332
  /**
303
333
  */
304
- export enum ChangeSelectionAlgo {
305
- Default = 0,
334
+ export enum NativeScriptKind {
335
+ ScriptPubkey = 0,
336
+ ScriptAll = 1,
337
+ ScriptAny = 2,
338
+ ScriptNOfK = 3,
339
+ ScriptInvalidBefore = 4,
340
+ ScriptInvalidHereafter = 5,
306
341
  }
307
342
  /**
308
343
  */
@@ -326,20 +361,40 @@ export enum CoinSelectionStrategyCIP2 {
326
361
  }
327
362
  /**
328
363
  */
329
- export enum ByronAddrType {
330
- PublicKey = 0,
364
+ export enum RedeemersKind {
365
+ ArrLegacyRedeemer = 0,
366
+ MapRedeemerKeyToRedeemerVal = 1,
367
+ }
368
+ /**
369
+ */
370
+ export enum Language {
371
+ PlutusV1 = 0,
372
+ PlutusV2 = 1,
373
+ PlutusV3 = 2,
374
+ }
375
+ /**
376
+ */
377
+ export enum RelayKind {
378
+ SingleHostAddr = 0,
379
+ SingleHostName = 1,
380
+ MultiHostName = 2,
381
+ }
382
+ /**
383
+ */
384
+ export enum CredentialKind {
385
+ PubKey = 0,
331
386
  Script = 1,
332
- Redeem = 2,
333
387
  }
334
388
  /**
335
389
  */
336
- export enum RedeemerTag {
337
- Spend = 0,
338
- Mint = 1,
339
- Cert = 2,
340
- Reward = 3,
341
- Voting = 4,
342
- Proposing = 5,
390
+ export enum GovActionKind {
391
+ ParameterChangeAction = 0,
392
+ HardForkInitiationAction = 1,
393
+ TreasuryWithdrawalsAction = 2,
394
+ NoConfidence = 3,
395
+ UpdateCommittee = 4,
396
+ NewConstitution = 5,
397
+ InfoAction = 6,
343
398
  }
344
399
  /**
345
400
  */
@@ -352,151 +407,96 @@ export enum VoterKind {
352
407
  }
353
408
  /**
354
409
  */
355
- export enum RedeemersKind {
356
- ArrLegacyRedeemer = 0,
357
- MapRedeemerKeyToRedeemerVal = 1,
410
+ export enum DRepKind {
411
+ Key = 0,
412
+ Script = 1,
413
+ AlwaysAbstain = 2,
414
+ AlwaysNoConfidence = 3,
358
415
  }
359
416
  /**
360
417
  */
361
- export enum SpendingDataKind {
362
- SpendingDataPubKey = 0,
363
- SpendingDataScript = 1,
364
- SpendingDataRedeem = 2,
418
+ export enum DatumOptionKind {
419
+ Hash = 0,
420
+ Datum = 1,
365
421
  }
366
422
  /**
367
- * JSON <-> PlutusData conversion schemas.
368
- * Follows ScriptDataJsonSchema in cardano-cli defined at:
369
- * https://github.com/input-output-hk/cardano-node/blob/master/cardano-api/src/Cardano/Api/ScriptData.hs#L254
370
- *
371
- * All methods here have the following restrictions due to limitations on dependencies:
372
- * * JSON numbers above u64::MAX (positive) or below i64::MIN (negative) will throw errors
373
- * * Hex strings for bytes don't accept odd-length (half-byte) strings.
374
- * cardano-cli seems to support these however but it seems to be different than just 0-padding
375
- * on either side when tested so proceed with caution
423
+ * Which version of the CIP25 spec to use. See CIP25 for details.
424
+ * This will change how things are encoded but for the most part contains
425
+ * the same information.
376
426
  */
377
- export enum CardanoNodePlutusDatumSchema {
427
+ export enum CIP25Version {
378
428
  /**
379
- * ScriptDataJsonNoSchema in cardano-node.
380
- *
381
- * This is the format used by --script-data-value in cardano-cli
382
- * This tries to accept most JSON but does not support the full spectrum of Plutus datums.
383
- * From JSON:
384
- * * null/true/false/floats NOT supported
385
- * * strings starting with 0x are treated as hex bytes. All other strings are encoded as their utf8 bytes.
386
- * To JSON:
387
- * * ConstrPlutusData not supported in ANY FORM (neither keys nor values)
388
- * * Lists not supported in keys
389
- * * Maps not supported in keys
429
+ * Initial version of CIP25 with only string (utf8) asset names allowed.
390
430
  */
391
- BasicConversions = 0,
431
+ V1 = 0,
392
432
  /**
393
- * ScriptDataJsonDetailedSchema in cardano-node.
394
- *
395
- * This is the format used by --script-data-file in cardano-cli
396
- * This covers almost all (only minor exceptions) Plutus datums, but the JSON must conform to a strict schema.
397
- * The schema specifies that ALL keys and ALL values must be contained in a JSON map with 2 cases:
398
- * 1. For ConstrPlutusData there must be two fields "constructor" contianing a number and "fields" containing its fields
399
- * e.g. { "constructor": 2, "fields": [{"int": 2}, {"list": [{"bytes": "CAFEF00D"}]}]}
400
- * 2. For all other cases there must be only one field named "int", "bytes", "list" or "map"
401
- * BigInteger's value is a JSON number e.g. {"int": 100}
402
- * Bytes' value is a hex string representing the bytes WITHOUT any prefix e.g. {"bytes": "CAFEF00D"}
403
- * Lists' value is a JSON list of its elements encoded via the same schema e.g. {"list": [{"bytes": "CAFEF00D"}]}
404
- * Maps' value is a JSON list of objects, one for each key-value pair in the map, with keys "k" and "v"
405
- * respectively with their values being the plutus datum encoded via this same schema
406
- * e.g. {"map": [
407
- * {"k": {"int": 2}, "v": {"int": 5}},
408
- * {"k": {"map": [{"k": {"list": [{"int": 1}]}, "v": {"bytes": "FF03"}}]}, "v": {"list": []}}
409
- * ]}
410
- * From JSON:
411
- * * null/true/false/floats NOT supported
412
- * * the JSON must conform to a very specific schema
413
- * To JSON:
414
- * * all Plutus datums should be fully supported outside of the integer range limitations outlined above.
433
+ * Second version of CIP25. Supports any type of asset names.
415
434
  */
416
- DetailedSchema = 1,
435
+ V2 = 1,
417
436
  }
418
437
  /**
419
438
  */
420
- export enum GovActionKind {
421
- ParameterChangeAction = 0,
422
- HardForkInitiationAction = 1,
423
- TreasuryWithdrawalsAction = 2,
424
- NoConfidence = 3,
425
- UpdateCommittee = 4,
426
- NewConstitution = 5,
427
- InfoAction = 6,
439
+ export enum PlutusDataKind {
440
+ ConstrPlutusData = 0,
441
+ Map = 1,
442
+ List = 2,
443
+ Integer = 3,
444
+ Bytes = 4,
428
445
  }
429
446
  /**
430
- * Careful: this enum doesn't include the network ID part of the header
431
- * ex: base address isn't 0b0000_0000 but instead 0b0000
432
- * Use `header_matches_kind` if you don't want to implement the bitwise operators yourself
433
447
  */
434
- export enum AddressHeaderKind {
435
- BasePaymentKeyStakeKey = 0,
436
- BasePaymentScriptStakeKey = 1,
437
- BasePaymentKeyStakeScript = 2,
438
- BasePaymentScriptStakeScript = 3,
439
- PointerKey = 4,
440
- PointerScript = 5,
441
- EnterpriseKey = 6,
442
- EnterpriseScript = 7,
443
- Byron = 8,
444
- RewardKey = 14,
445
- RewardScript = 15,
448
+ export enum AuxiliaryDataKind {
449
+ Shelley = 0,
450
+ ShelleyMA = 1,
451
+ Conway = 2,
446
452
  }
447
453
  /**
448
454
  */
449
- export enum TransactionMetadatumKind {
450
- Map = 0,
451
- List = 1,
452
- Int = 2,
453
- Bytes = 3,
454
- Text = 4,
455
+ export enum DelegationDistributionKind {
456
+ Weighted = 0,
457
+ Legacy = 1,
455
458
  }
456
459
  /**
457
460
  */
458
- export enum Language {
459
- PlutusV1 = 0,
460
- PlutusV2 = 1,
461
- PlutusV3 = 2,
461
+ export enum ChangeSelectionAlgo {
462
+ Default = 0,
462
463
  }
463
464
  /**
464
465
  */
465
- export enum NativeScriptKind {
466
- ScriptPubkey = 0,
467
- ScriptAll = 1,
468
- ScriptAny = 2,
469
- ScriptNOfK = 3,
470
- ScriptInvalidBefore = 4,
471
- ScriptInvalidHereafter = 5,
466
+ export enum TransactionOutputKind {
467
+ AlonzoFormatTxOut = 0,
468
+ ConwayFormatTxOut = 1,
472
469
  }
473
470
  /**
474
471
  */
475
- export enum CredentialKind {
476
- PubKey = 0,
477
- Script = 1,
472
+ export enum TransactionMetadatumKind {
473
+ Map = 0,
474
+ List = 1,
475
+ Int = 2,
476
+ Bytes = 3,
477
+ Text = 4,
478
478
  }
479
479
  /**
480
480
  */
481
- export enum Vote {
482
- No = 0,
483
- Yes = 1,
484
- Abstain = 2,
481
+ export enum MetadataJsonSchema {
482
+ NoConversions = 0,
483
+ BasicConversions = 1,
484
+ DetailedSchema = 2,
485
485
  }
486
486
  /**
487
487
  */
488
- export enum PlutusDataKind {
489
- ConstrPlutusData = 0,
490
- Map = 1,
491
- List = 2,
492
- Integer = 3,
493
- Bytes = 4,
488
+ export enum ByronAddrType {
489
+ PublicKey = 0,
490
+ Script = 1,
491
+ Redeem = 2,
494
492
  }
495
493
  /**
496
494
  */
497
- export enum NonceKind {
498
- Identity = 0,
499
- Hash = 1,
495
+ export enum ScriptKind {
496
+ Native = 0,
497
+ PlutusV1 = 1,
498
+ PlutusV2 = 2,
499
+ PlutusV3 = 3,
500
500
  }
501
501
  /**
502
502
  */
@@ -1072,51 +1072,6 @@ export class AssetName {
1072
1072
  free(): void;
1073
1073
  /**
1074
1074
  *
1075
- * * Create an AssetName from utf8 string. 64 byte (not char!) maximum.
1076
- *
1077
- * @param {string} utf8_str
1078
- * @returns {AssetName}
1079
- */
1080
- static from_str(utf8_str: string): AssetName;
1081
- /**
1082
- *
1083
- * * AssetName as a utf8 string if it's possible. Will error if the asset is not utf8
1084
- *
1085
- * @returns {string}
1086
- */
1087
- to_str(): string;
1088
- /**
1089
- *
1090
- * * Direct raw bytes without any CBOR structure
1091
- *
1092
- * @returns {Uint8Array}
1093
- */
1094
- to_raw_bytes(): Uint8Array;
1095
- /**
1096
- *
1097
- * * Parse from the direct raw bytes, without any CBOR structure
1098
- *
1099
- * @param {Uint8Array} bytes
1100
- * @returns {AssetName}
1101
- */
1102
- static from_raw_bytes(bytes: Uint8Array): AssetName;
1103
- /**
1104
- *
1105
- * * Direct raw bytes without any CBOR structure, as a hex-encoded string
1106
- *
1107
- * @returns {string}
1108
- */
1109
- to_hex(): string;
1110
- /**
1111
- *
1112
- * * Parse from a hex string of the direct raw bytes, without any CBOR structure
1113
- *
1114
- * @param {string} input
1115
- * @returns {AssetName}
1116
- */
1117
- static from_hex(input: string): AssetName;
1118
- /**
1119
- *
1120
1075
  * * Serialize this type to CBOR bytes
1121
1076
  * * This type type supports encoding preservation so this will preserve round-trip CBOR formats.
1122
1077
  * * If created from scratch the CBOR will be canonical.
@@ -1177,6 +1132,51 @@ export class AssetName {
1177
1132
  * @returns {AssetName}
1178
1133
  */
1179
1134
  static from_json(json: string): AssetName;
1135
+ /**
1136
+ *
1137
+ * * Create an AssetName from utf8 string. 64 byte (not char!) maximum.
1138
+ *
1139
+ * @param {string} utf8_str
1140
+ * @returns {AssetName}
1141
+ */
1142
+ static from_str(utf8_str: string): AssetName;
1143
+ /**
1144
+ *
1145
+ * * AssetName as a utf8 string if it's possible. Will error if the asset is not utf8
1146
+ *
1147
+ * @returns {string}
1148
+ */
1149
+ to_str(): string;
1150
+ /**
1151
+ *
1152
+ * * Direct raw bytes without any CBOR structure
1153
+ *
1154
+ * @returns {Uint8Array}
1155
+ */
1156
+ to_raw_bytes(): Uint8Array;
1157
+ /**
1158
+ *
1159
+ * * Parse from the direct raw bytes, without any CBOR structure
1160
+ *
1161
+ * @param {Uint8Array} bytes
1162
+ * @returns {AssetName}
1163
+ */
1164
+ static from_raw_bytes(bytes: Uint8Array): AssetName;
1165
+ /**
1166
+ *
1167
+ * * Direct raw bytes without any CBOR structure, as a hex-encoded string
1168
+ *
1169
+ * @returns {string}
1170
+ */
1171
+ to_hex(): string;
1172
+ /**
1173
+ *
1174
+ * * Parse from a hex string of the direct raw bytes, without any CBOR structure
1175
+ *
1176
+ * @param {string} input
1177
+ * @returns {AssetName}
1178
+ */
1179
+ static from_hex(input: string): AssetName;
1180
1180
  }
1181
1181
  /**
1182
1182
  */