Send ADA using Cardano-cli to Daedalus, invalid address

Hey guys,

Just setup my first nodes and I now want to send some ADA using Cardano-cli to my Daedalus Wallet. When using Cardano-cli, you first need to ‘draft’ your raw transaction:

cardano-cli shelley transaction build-raw
–tx-in 5751c0dc9a5cbfed13a997eb8a68d64590aa1a806eafc9bea30e796c69b03755#0
–tx-out addr1qp6hddrn62jqggyngfqvg6d0p0pfamnla9af7rdc4jffqgv8v8kz5fqtqx490ky9pjeav49jcnkvg28r9jg55a87txvqulznnm+7000000000
–ttl 0
–fee 0
–out-file tx.raw

As you can see I have used a Daedalus generated address with the --tx-out option. But this gives me the following errormessage: option --tx-out: Failed reading: invalid address

What am I doing wrong here?

You left the TTL (time to live) and the fee spot blank. Don’t forget to deduct the fee from the total UTXO amount. Should look more like this:

cardano-cli shelley transaction build-raw
–tx-in 5751c0dc9a5cbfed13a997eb8a68d64590aa1a806eafc9bea30e796c69b03755#0
–tx-out addr1qp6hddrn62jqggyngfqvg6d0p0pfamnla9af7rdc4jffqgv8v8kz5fqtqx490ky9pjeav49jcnkvg28r9jg55a87txvqulznnm+6999810000
–ttl 15000000
–fee 190000
–out-file tx.draft

This transaction assumes you are sending the full value of the UTXO to the new address. You can use a fee of 190000 lovelace for most transactions. Save yourself some trouble by using that instead of going through the step of calculating it exactly. You can follow the Cardano documentation on creating simple transactions here:

Thanks for your answer. But it’s not so much about leaving the TTL and fee blank. This is just used to setup a draft transaction.

It’s about the Address error message I receive with the address I use at the tx-out option (the error message is “…Failed reading: invalid address”.
This is an address generated in the Daedalus Wallet and this address is also longer (contains more characters) than addresses generated using (for example) Cardano-CLI.

So there are no problems when I use Cardano-cli-generated-addresses, but when I use an address generated by Daedalus, it will not work.

Any ideas why??

I’ve successfully sent from cli to Daedalus many times, so it’s for sure doable. I would double check that the address was copy/pasted correctly and not missing or adding characters. Also check that you are not mixing testnet and mainnet wallets

Both checks done. I’m on testnet with my nodes (where I use Cardano-cli) and I use the testnet version of Daedalus. Next I copy/paste an address from Daedalus Testnet (to receive payments) and use that address with Cardano-cli (also on testnet) to Send ADA to it. But Cardano-cli does not recognise this address…

I’m using the following versions:
Daedalus Testnet version: 2.4.1 build 15062 / Cardano Node version: 1.21.1
Cardano-cli version: 1.21.1

Notes:

  1. Addresses created using Cardano-cli are much shorter in length than addresses created in Daedalus. Maybe that has something to do with it?
  2. The faucet (https://testnets.cardano.org/en/cardano/tools/faucet/) is able to send ADA to both addresses (Cardano-cli and Daedalus)
  3. I can send ADA from Daedalus address to Cardano-cli created address
  4. But I cannot Send ADA back to Daedalus created address from a Cardano-cli created address

Strange right?

On testnet (and only on testnet), you need to convert Daedalus addresses in a format the CLI will accept.

For that, you have to change the prefix of the Daedalus address from ‘addr´ to ´addr_test’ using the bech32 tool that you’d have installed.

Follow the bech32 help section to get the command syntax.

Okay, thanks!
I will give that a try.