-
Notifications
You must be signed in to change notification settings - Fork 217
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot create a wallet using the account public key returned by the API. #4886
Comments
Thanks for reporting the issue @Melraidin. I agree this discrepancy is annoying, and to be honest it's not the only place where the output of the API is not directly consumable by the API: I just found out it was also the case for mint/burn of assets, as one input asset names in human readable form but they are output hex-encoded. I am not sure we are going to change the behaviour at this stage, but we can definitely improve the documentation and provide users with instructions on how to convert the account extended key's output into the right format. |
I understand the hesitation to change the API's output. That makes sense. But please do provide instructions on how to convert from the response format to the format the API can consume to restore the wallet later. I'm currently at a loss as to how to do so. If it helps and you're able to provide instructions here I could submit a PR to update the docs once I have my head around the process. Thanks for your help with this. |
It's actually pretty simple and you're definitely right this should be properly documented. You need to find the bech32 binary and then do:
|
A PR would be much appreciated if you are willing and able to do it 🙏 |
hi, This is the flow that should work:
|
Just checking...
cardano-wallet
bug.cardano-wallet
release.cardano-node
version for that release ofcardano-wallet
.Version
v2024-11-18 (git revision: 0000000000000000000000000000000000000000)
Platform
Ubuntu 22.04.4 LTS
Installation method
Binary from GitHub release page
Network configuration
Preview testnet
Context
API docs: https://cardano-foundation.github.io/cardano-wallet/api/edge/#operation/postWallet
Third-party API docs: https://bump.sh/hal-cardano-foundation/doc/cardano-wallet-backend/operation/operation-postwallet#operation-postwallet-body-application-json-shelley-from-xpub
Description
Steps to Reproduce
The response is a 404 containing:
v2
to the path:The key returned will look like
acct_xvk[...]
, just as the docs describe in the200 Ok
response.The response is a 404 containing:
v2
to the path:The response is a 400 containing:
v2
to the path and using theaccount_public_key
shown in the request example here: https://bump.sh/hal-cardano-foundation/doc/cardano-wallet-backend/operation/operation-postwallet#operation-postwallet-body-application-json-shelley-from-xpubThe response shows the wallet is successfully restored.
Expected behavior
I expected that the extended account public key retrieved from the API would be the correct form to use to restore the same wallet.
Actual behavior
The extended account public key retrieved from the API is in the documented form for the response but is not in the correct form to restore the wallet. It seems the term
extended account public key
is being used to refer to two different things or that the docs should not be using this term for one of these two endpoints.It does appear that a wallet may be restored using the sample data from some other (linked above) docs but this only begs the question of how to retrieve this value for my own wallet.
The text was updated successfully, but these errors were encountered: