Skip to content
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

feat: bitcoin balance and getUtxos support for queries only #706

Merged
merged 6 commits into from
Sep 2, 2024

Conversation

peterpeterparker
Copy link
Member

@peterpeterparker peterpeterparker commented Aug 30, 2024

Motivation

As we learned this week, update calls to the Bitcoin canister for get_balance and get_utxos are only possible when executed from a canister. Therefore, we remove the support for certified calls regarding those endpoints in @dfinity/ckbtc. In addition, to make the exception more obvious and to reflects the actual IC API naming, we also add the suffix Query to the functions.

Documentation

https://internetcomputer.org/docs/current/references/ic-interface-spec/#ic-bitcoin_get_utxos

Changes

  • Remove certified option parameter for getBalance and getUtxos
  • Rename getBalance and getUtxos to getBalanceQuery and getUtxosQuery
  • Add a warning in the documentation
  • Update code to use only endpoints _query
  • Add breaking change in changelog

Copy link
Contributor

github-actions bot commented Aug 30, 2024

size-limit report 📦

Path Size
@dfinity/ckbtc 7.98 KB (-0.18% 🔽)
@dfinity/cketh 3.45 KB (0%)
@dfinity/cmc 1.29 KB (0%)
@dfinity/ledger-icrc 3.89 KB (0%)
@dfinity/ledger-icp 15.23 KB (0%)
@dfinity/nns 36.62 KB (0%)
@dfinity/nns-proto 140.98 KB (0%)
@dfinity/sns 15.92 KB (0%)
@dfinity/utils 4.5 KB (0%)
@dfinity/ic-management 2.92 KB (0%)

Copy link
Contributor

@AntonioVentilii-DFINITY AntonioVentilii-DFINITY left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@peterpeterparker peterpeterparker merged commit 84975a7 into main Sep 2, 2024
10 checks passed
@peterpeterparker peterpeterparker deleted the feat/bitcoin-query-only branch September 2, 2024 07:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants