Questions tagged [cardano-serialization-lib]

Filter by
Sorted by
Tagged with
0 votes
1 answer
23 views

Attaching Datum Value with CSL 10.x

I generate my datum like so: // Build datum const sellerAddressPKH = changeAddressValue.slice(2,58); const datumFields = CSL.PlutusList.new(); datumFields.add(CSL.PlutusData.new_integer(CSL.BigInt....
user avatar
  • 101
1 vote
1 answer
26 views

Building a transaction on cardano-cli/api without running node?

Is there a way to build and sign transactions with the cardano-cli/api without running a node? I am trying to construct a transaction using the cli or api and submit it using blockfrost. It throws an ...
user avatar
1 vote
1 answer
22 views

Haskell + Blockfrost toolchain?

I am looking for a Haskell alternative to the cardano-serialization-lib, which can work in conjunction with blockfrost-haskell. So ideally, it should be able to easily create wallet keys, transactions,...
user avatar
0 votes
1 answer
27 views

What's a Good example of Practle Serialation lib Usage

Okay so I have used an older version of the library by emerugo. And want some examples of the use of the newer version just to make sure I'm not missing anything important. Can someone point me the ...
user avatar
0 votes
1 answer
30 views

Cardano Node Causing Browser Errors

I am not a developer, just a hobbyist. I installed the Cardano Node (1.33.0-win64) so that I could point my Nami Wallet Browser Extension to it, rather than the web server node Nami points to by ...
user avatar
  • 3
0 votes
0 answers
10 views

how to build cardano-serialization-lib ScripHash object from TxOut data hash?

Could anyone give a hint on how to create ScripHash from Haskell ScriptHash/CurrencySymbol value? In a few words. I have built a web server for my contracts. I really want to sign Tx at the client-...
user avatar
1 vote
2 answers
18 views

How to convert from cborHex to VRFKeyHash using both cardanocli-js and cardano-serialization-lib?

I'm using cardanocli-js to create both VRF files for running a stake pool: vrf.vkey and vrf.skey: const vrfKeyAccount = cardanocliJs.nodeKeyGenVRF("Totem"); Then I want to read the vrf.vkey ...
user avatar
0 votes
1 answer
36 views

How to retrieve staking credential hash

How to retrieve staking credential hash using cardano serialization library and what is it? How does it differ from public key hash?
user avatar
  • 3
3 votes
1 answer
29 views

Check status of past transaction using cli

How can you check the status of a past transaction given the TxHash (i.e. pending, failed, or successful) and also the assurance level / number of confirmations and block number? (like on Cardanoscan ...
user avatar
  • 125
1 vote
1 answer
24 views

Can I generate a VRF key hash without using cardano-cli?

I need to generate a VRF Key Hash in this format: vrf_vk13hg4gg5fg67399nuz2ldk89kqw9h379cfgtkpvd83ra89f908kcqv2cw3j When I generate it using cardano-cli, I get this: { "type": "...
user avatar
0 votes
0 answers
27 views

MissingScriptWitnessesUTXOW while minting NFTs my own NFTS with Nami Wallet?

I am trying to mint NFTs from Nami wallet. I get the following errors. I look like i didn't sign the nativescripts? transaction submit error ShelleyTxValidationError ShelleyBasedEraAlonzo (...
user avatar
1 vote
1 answer
31 views

How to provide Datum value using serialization lib

I am consuming a script output and also create a new one at the same script address. The validator script requires the output producer to provide the datum value due to making assertions on it. ...
user avatar
0 votes
0 answers
12 views

How can I generate a KES VKey using cardano-serialization-lib?

Cardano Serialization lib has this class: export class KESVKey { free(): void; /** * @returns {Uint8Array} */ to_bytes(): Uint8Array; /** * @param {string} prefix * @returns {string} */ ...
user avatar
2 votes
1 answer
36 views

Derive public key hash from bech32 address using python

I know that this is possible in javascript using the cardano serialization lib, as follows: function toHex(bytes){ return Buffer.from(bytes).toString("hex"); } function addrToPubKeyHash(...
user avatar
  • 733
0 votes
1 answer
65 views

Create transaction serialization-lib > version 10

I'm using cardano-serialization-lib ^9.1.2 to create transaction. I'm using method that are now deprecated in version 10, so is there an example of transaction with serialization-lib latest version ...
user avatar
2 votes
0 answers
26 views

Cardano serialization lib for PHP

I'm trying to authenticate a user against a (or any) PHP platform (Drupal, Symfony, Laravel,..) by having the user connect with their wallet (Eternl, Nami, ...). As far as I understand, the following ...
user avatar
  • 21
5 votes
1 answer
82 views

window.cardano undefined

I would to use window.cardano when a user just "enter" to website. Sometimes window.cardano is still undefined How can i solve this problem? I try to use await window.cardano but is not a ...
user avatar
  • 51
1 vote
0 answers
8 views

How can I generate a KES Signature using cardano-serialization-lib?

Cardano Serialization Lib has this class: export class KESSignature { free(): void; /** * @returns {Uint8Array} */ to_bytes(): Uint8Array; /** * @param {Uint8Array} bytes * @returns {KESSignature} ...
user avatar
0 votes
0 answers
7 views

How can I issue an operational certificate using cardano-serialization-lib?

Cardano Serialization Lib has this class: export class OperationalCert { free(): void; /** * @returns {Uint8Array} */ to_bytes(): Uint8Array; /** * @param {Uint8Array} bytes * @returns {...
user avatar
2 votes
0 answers
28 views

Meaning of Index of Redeemer in Serialization Lib 10.4

What is the meaning of the index in the redeemer ? redeemer = [ tag: redeemer_tag, index: uint, data: plutus_data, ex_units: ex_units for context see: https://github.com/input-output-hk/cardano-...
user avatar
0 votes
2 answers
41 views

Is it possible to generate all stake pool files and keys using Cardano Serialization Lib?

To successfully create and register a stake pool, we are require to generate: Payment keys and address Stake keys and address Stake pool cold key Stake pool hot key Stake pool VRF key Stake pool ...
user avatar
0 votes
0 answers
16 views

walletid from mnemonic using the cardano-serialization-lib

You need to know the walletid if you want to do anything in the cardano-wallet backend service. One particular use case that I need to solve is where a wallet was created using the cardano-wallet ...
user avatar
  • 76
2 votes
2 answers
58 views

PlutusData construction using @emurgo cardano-serialization-lib-browser

I have a JSON format needed for PlutusData serialization (but the format is not a standard datum in a list). The datum is wrapped in Maybe monad, so you'll note the nested lists (an array inside the ...
user avatar
0 votes
1 answer
43 views

Is it possible to get root key from CLI generated private key?

Objective To load a private key generated by cardano-cli into cardano-serialization lib Details Using cardano-cli cardano-cli address key-gen, we get this: { "type": "...
user avatar
  • 103
3 votes
1 answer
104 views

Cardano Serialization Lib Usage

I am going through Cardano developer docs and the different APIs used to interact with the Cardano network. In the list is Cardano Serialization Lib which has the description, This is a library for ...
user avatar
  • 305
0 votes
1 answer
42 views

How do you make a faucet for native assets such as NFTS on cardano?

im trying to make an NFT faucet for a NFT drop. How do I make the basic faucet is there an example that I could build upon?
user avatar
0 votes
0 answers
55 views

Get witness set from serialization library and submit it with cardano-cli

By creating an API that builds the transaction with cardano-cli and sends the CBOR to the front-end to sign it, I was able to reduce the resource consumption from the browser and keep every thing in ...
user avatar
  • 733
0 votes
0 answers
45 views

Error: submit tx failed: Error: 400: 0: "278ad827cb923ed800fcb2028114ee8e9bca875059e1389ca1f49755c1c9a629"

this.API.submitTx is throwing error Error: submit tx failed: Error: 400: 0: "278ad827cb923ed800fcb2028114ee8e9bca875059e1389ca1f49755c1c9a629" at checkResponseNoError (apiDom.ts:334:1) at ...
user avatar
0 votes
2 answers
319 views

Not enough ADA leftover to include non-ADA assets in a change address

I am getting the error when using @emurgo\cardano-serialization-lib-asmjs txBuilder.add_change_if_needed(shelleyChangeAddress) throws an exception Not enough ADA leftover to include non-ADA assets in ...
user avatar
2 votes
0 answers
70 views

Building alonzo transaction using cardano-cli and signing it with serialization-lib

I created an API that based on a request builds the body of a transaction with cardano-cli and returns the cbor to the front-end. In the front-end, I'm using the cardano-serialization-lib to load the ...
user avatar
  • 733
0 votes
0 answers
38 views

How to sign transaction externally?

I am using the cardano-serialization-lib to derive addresses and create a transaction unsigned. I am then passing that transaction hash in CBOR to an external program to handle the signing process. I ...
user avatar
  • 40
0 votes
1 answer
86 views

Is there good examples for building a transaction using serialization-lib?

I am trying to find an example of building a simple Tx of ADA in, ADA out type of transaction using sterilization-lib to get cbor and pass it to Wallet.signTx(cbor). developer.cardano.org has a great ...
user avatar
  • 21
0 votes
1 answer
53 views

Submitting Transaction with CSL Metadata Isn't Showing

I've forked a dApp Connector I found on Github and I'm trying to add some transaction metadata to the ADA transaction it builds. This is what I currently have: buildSendADATransaction = async () => ...
user avatar
0 votes
1 answer
89 views

How to generate TransactionBody in cardano-serialization lib from cardano-cli's TxBodyAlonzo cborHex

I want to get cborHex from cardano-cli transaction build output and use it with cardano-serialization-lib to recreate the transaction body. I tried the following: cborHex = '...
user avatar
  • 369
2 votes
1 answer
75 views

How to convert a Stake Key Address from hash to BECH32?

I have this Stake Key: https://testnet.cardanoscan.io/stakekey/7622b4611b15441e7e15cba128ff999ad72388aeb267adc6e70cc9bc?tab=stakehistory I want to convert from ...
user avatar
0 votes
1 answer
56 views

What am i doing wrong while creating this staking transaction?

i am trying to create a staking transaction using cardano serialisation library and then use blockfrost/infinito to send the transaction. I am using @emurgo/cardano-serialization-lib-nodejs: ^9.1.4, ...
user avatar
0 votes
0 answers
90 views

How to generate script address from plutus script cborhex

I want to generate the address from the plutus script's cborhex value, but so far without much luck. I am using the alwayssucceeds.plutus contract as an example for which the cborhex value is ...
user avatar
  • 76
0 votes
0 answers
19 views

Class Transaction/TransactionHash . to_bytes() returns empty Uint8Array(0) [] - Cardano Serialisation lib

I am currently facing this issue: transaction.to_bytes() defined in (blockfrost-js/index.ts at master · blockfrost/blockfrost-js · GitHub) returns an empty array Uint8Array(0) It sometimes returns a ...
user avatar
1 vote
1 answer
61 views

How to add multiasset as input to txBuilder?

I'm trying to add lovelaces + native assets to input as multiAsset. However I get Inputs do not conform to this spec or are otherwise invalid. Here is my code: const assetsToSend = this.S....
user avatar
0 votes
1 answer
67 views

TransctionBuilder.new() in cardano-serialization-lib 10.0.0

With the new version of library TranasctionBuilder.new() arguments have changed. When running: const txBuilder = this.S.TransactionBuilder.new( this.S.LinearFee.new( this.S.BigNum....
user avatar
1 vote
2 answers
62 views

Javascript assetName Decoding

I'm trying to figure out a reliable way to decode an assetName using JavaScript. My current implementation is this: function hexToBytes (hex) { if(!hex){ return hex; } else { ...
user avatar
0 votes
0 answers
89 views

How can I mint/sell bundles of NFTs as a pack?

There are many use cases for bundling NFTS. Example: If I am creating a Trading card game and have packs of multiple NFTs (6 cards). How do I make users purchase my packs of of 6 cards. I thought pre-...
user avatar
0 votes
1 answer
45 views

TransactionBuilder and add_from_inputs

Looking through the cardano-serialization-lib I see a TransactionBuilderConfig and a TransactionBuilder constructor that looks like it takes the Config and exposes add_from_inputs that maybe does the ...
user avatar
1 vote
1 answer
71 views

How can I convert Key Hash to bech32 in Cardano serialization lib?

I generate my Key Hash Using the Following Function const getAddressKeyHash = (address) => { return toHex( Cardano.Instance.BaseAddress.from_address( Cardano.Instance.Address.from_bech32(address) ) ...
user avatar
0 votes
1 answer
139 views

Error loading cardano-serialization-lib

Trying a few different examples out there and I am getting the error: The requested module '/node_modules/@emurgo/cardano-serialization-lib-browser/cardano_serialization_lib_bg.wasm?import' does not ...
user avatar
0 votes
2 answers
64 views

help, i register script policy with pool.pm was not approved? [closed]

I'm learning to create nft. by using cardano serialization lib and nami wallet but the nft I created, register script policy with pool.pm was not approved. I don't know if it's caused by a signed key ...
user avatar
1 vote
1 answer
235 views

Error submiting Smart Contract with Nami, What does this error means?

I am running one smart contract with the Nami Wallet but I get this error: ""transaction submit error ShelleyTxValidationError ShelleyBasedEraAlonzo (ApplyTxError [UtxowFailure (...
user avatar
1 vote
2 answers
449 views

How can I use cardano-serialization-lib in the browser to decode CBOR?

I'm building a simple website with pure HTML and JS (no React, Angular, etc.). I use Nami to connect to a Cardano wallet and use the Nami's cardano.getBalance() method to get the balance of the wallet....
user avatar
  • 3,026
1 vote
0 answers
112 views

Mint tokens using plutus scripts with the serialization lib

As I understand, in order to mint a token with the serialization-lib, you must use the function set_mint_scripts, providing a NativeScripts object. This collection of NativeScript objects should ...
user avatar
  • 733
0 votes
1 answer
120 views

NativeScript vs PlutusScript

In cardano serialization lib what is the difference between NativeScript and PlutusScript? Is there a way to convert from one to the other? I'm trying to load a minting policy script I made as a ...
user avatar
  • 733