Closed friedger closed 3 years ago
getMapEntry
has the same functionality as SmartContractsApi.getDataMapEntry
of the stacks blockchain api client library. Similar to callReadOnlyFunction
. Does it matter that it is duplicated code?
I'll do the cloning...
What about the hexToCV
? https://github.com/blockstack/stacks-transactions-js/issues/126#issuecomment-703071291
Description
As a Blockstack developer, I would like to query the blockchain for data map entries of a contract. This is needed in the same was as read-only function calls. This pull request adds the
getMapEntry
function which uses helper methodscvToHex
andparseMapEntryResponse
. Both are exported as well.For details refer to issue #126
Type of Change
Does this introduce a breaking change?
No, just a new feature
Are documentation updates required?
yes
Testing information
A new test in builder-tests.js was added that calls
getMapEntry
.Checklist
npm run test
passes