Questions tagged [javascript]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
3
votes
1answer
70 views

How do I call the FA2 balance_of endpoint through Truffle?

I have written a contract to implement FA2 and I have a Truffle/JavaScript setup to test this contract while running against a sandboxed node. I can test the transfer endpoint and the update_operators ...
5
votes
3answers
178 views

How to decode raw transaction?

I am using @taquito to build and sign a transaction. But before I send it I want to decode it to check my destination address, amount etc like you would normally do for other blockchains. Not sure ...
1
vote
1answer
42 views

How to increase the counter of a transaction

I am using @taquito/taquito. To transfer tezos tokens from one address to another is am using below function. Tezos.contract.transfer({ to: toAddress, amount: amountToSend, ...
4
votes
1answer
116 views

How to estimate Baker and Storage fee with @taquito for a contract?

I have a simple smart-contract that holds user funds and that can be withdrawn by sending a signed message. However, I would like to offer the possibility for users to anticipate the fees they have ...
1
vote
2answers
150 views

How to retrieve data from smart-contract using javascript?

I have stored data that I would like to retrieve from a deployed smart-contract. The storage structure was defined using SmartPy: def __init__(self): self.init(bmap=sp.big_map(tkey=sp....
1
vote
1answer
14 views

How to fix 'paused before out-of-memory crash' contract deployment error in browser? [ConseilJS]

I wish to deploy a contract using ConseilJS that I am able to originate successfully using smartpy.io However, when I copy the generated Michelson and initial storage into the following function: ...
1
vote
1answer
53 views

How to interact with SmartPy BigMap in contract?

I would like to setup a smart contract that contains (as defined by smartpy) a BigMap storage. I have the following code: import smartpy as sp class contract(sp.Contract): def __init__(self): ...
2
votes
1answer
35 views

ConseilJS TezosContractIntrospector.generateEntryPointsFromAddress `Uncaught (in promise) TypeError: Cannot read property '0' of undefined`

Trying to retrieve contract entry points using the TezosContractIntrospector The following code: async function entry_points(){ const server={ url:'https://conseil-dev.cryptonomic-infra.tech:...
2
votes
1answer
161 views

How to deploy a smart contract influenced by UI inputs using ConseilJS and SmartPy generated Michelson?

I wish to be able to create a smart contract taking input from a UI to supply parameters pubKey,prvKey,pubHash for the deployment and minAmount and maxTime to influence the Michelson. I have the ...
1
vote
1answer
56 views

Transfer operation using ConseilJS

I'm trying to use ConseilJS to make a transfer to a contract from a webpage. I'm using a keystore object based on my tezos-client wallet. const keystore = { publicKey: '...
1
vote
1answer
34 views

How to ensure that operation was included in a block with taquito

When I inject an operation using the taquito library, how can I have my program wait for a specific number of blocks after my operation is included in the network.
1
vote
1answer
77 views

How to originate a smart contract with Taquito

How can I access my contract after originating it using taquito? If I use taquito like this. Tezos.contract.originate({...contractOptions}) How can I access my new originated address and start using ...
1
vote
1answer
74 views

How can I derive a public key from a known private key?

Edpk from a edsk, programmatically?
3
votes
0answers
11 views

API Ballots not working

The API : https://api6.tzscan.io/v3/ballots/11 is not working, I don't understand why. Tzscan API instructions : https://tzscan.io/api#operation/405
2
votes
1answer
39 views

Is there a TzScan API to find the number of Tezos Node?

I'm looking for an API to get the number of Tezos Node or the number of Bakers.
3
votes
0answers
34 views

Is there a TzScan API to find the total number of delegated Tezos?

I'm looking for an API to get the total number of delegated Tezos. I already found an API to get the number of rolls delegated: https://api6.tzscan.io/v3/rolls_history/...
4
votes
2answers
84 views

Issue with API Request Cycle

I have an issue to request the Cycle Number from this API. I don't understand how to use the map to get the data from the last cycle only. const ul2 = document.getElementById('Cycle'); const url2 =...
4
votes
1answer
171 views

API Access HTML/Javascript problem

I have an issue trying to use javascript to get the circulating supply by requesting data from Tzscan API: HTML code to request the circulating supply: <!DOCTYPE html> <html> <head>...
7
votes
2answers
197 views

Base58 encoding/decoding of addresses in Micheline

who know some javascript library for decoding optimized Micheline representation of an address value? 011cd5f135e80fd8ebb6e43335b24ca6116edeba6900 => KT1BDEn6wobs7tDReKkGheXAhoq278TGaNn5