Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Join us in building a kind, collaborative learning community via our updated Code of Conduct.

For questions related to IOTA's Application Programming Interface (API)

3
votes
1answer
71 views

What IRI API commands should only be executed on a node that is synced to the latest milestone?

I want to load balance commands to my nodes. But not all nodes are equally fast. Some commands do not need a node that is completely up to date to finish successfully, like attachToTangle. Therefore I ...
3
votes
1answer
39 views

Why is anyone with API access allowed to cancel the 'attachToTangle' operation of another user?

In the IRI, there is no filter that prevents anyone from cancelling another users 'attachToTangle' operation when the POW is in progress. See API.java, case "interruptAttachingToTangle" Why is that?
6
votes
1answer
86 views

IOTA API error when making send transaction call with Node.js client library

I made some test codes to send transactions with Node.js client library, and received the below error response. I cannot find the cause of this error. Did this happen to anyone before? And can anyone ...
1
vote
1answer
45 views

Is there an IOTA PHP library?

How can I implement IOTA in my website in a way people can't see the code (contrary of javascript)? Each user would have an seed, how can I handle this sensitive information using IRI API?
2
votes
1answer
60 views

How do I send a transaction using only POST requests?

On small boards like arduino micro, NodeMCU(esp8266), or teensy, I cannot run an iota node or wallet. I can only transmit POST requests to a iri server. Given a seed, and a message, how do I attach ...
0
votes
0answers
37 views

getTips returns an empty array after days / hours of inactivity on isolated node

On an isolated iota tangle, let's say there is no recent activity for a day or two. Why does getTips return empty after such time? Edit: The getTransactionsToApprove API command is does not show this ...
0
votes
1answer
75 views

Tangle and transaction explorer

I want to have an isolated tangle for testing purposes. I want to explore and browse this tangle for individual transactions, as I attach new transactions on this tangle. Is there an open source ...
1
vote
1answer
72 views

findTransactionObjects() call returning empty array when searching for tag [duplicate]

With this findTransactionObjects call: iota.api.findTransactionObjects({ tags: [ 'ZARCXARCQCVAZA9BUAZASCVAEXP' ]}, callback) I am getting back an empty array. However, when I search for the tag on ...
2
votes
1answer
67 views

sendTransfer() 'Invalid transaction hash' when running mainnet but fine on testnet

When running a sendTransfer() on a testnet node (https://testnet140.tangle.works) I can attach without any problems. When I try to use a mainnet node (http://nodes.iota.fm:80) I get Invalid ...
5
votes
1answer
127 views

findTransaction not finding tag

I was experimenting with some transactions and I wonder why the node cant find a transaction when I search for it by its TAG, yet finds it when I search for it by its transaction hash. Example: ...
3
votes
0answers
78 views

How to connect cli-app with IOTA Javascript Library

I installed IOTA CLI Wallet and executing 'iota-cli' works after iri is executed. I get NodeInfo command run on iota-cli from my terminal also. So I guess a stand alone IOTA wallet core is now ...
4
votes
1answer
232 views

Iota ZeroMQ consumer

I would like to consume events from my Iota Zmq node. Can somebody help me to do it? I enabled Zmq on my iota node by adding those lines in my iota.ini file : ZMQ_ENABLED = true ZMQ_PORT = 5555 I ...
1
vote
1answer
234 views

How do you find addresses with balance with the seed?

I'm trying to build a small C# client and use the C#-Api on Github. My problem is: With one seed I can generate millions of adresses. How do I find all addresses with balance when I type in my seed? ...
3
votes
2answers
95 views

Attaching an address to the tangle via the API

This is a follow-up question to What does the ATTACH TO TANGLE button do? When using the js-/Python-API, I assume that you have to specify the receive address as the target of the 0-value transaction....
3
votes
1answer
154 views

How to attach an address to tangle programmatically?

Say I have a script to generate addresses automatically, how can I attach it to the tangle using the library? From the Javascript library I see that these are the parameters: * @param {string} ...
2
votes
2answers
144 views

Understanding getTransactionsToApprove

The official docs for getTransactionsToApprove state The higher your depth value, the more "babysitting" you do for the network (as you have to confirm more transactions). I don’t exactly ...
0
votes
2answers
118 views

Python API - Reattaching transactions after snapshot

I have a small seed for testing using the Python API, linking to a local CarrIOTA node. The seed has only one used address. If I run get_account_data(), the balance shows as 0 since I haven't ...
1
vote
0answers
27 views

Caching account data

Reading through the documentation for the IOTA Javascript Library I realized the method iota.api.getAccountData can be provided with an starting index: iota.api.getAccountData(seed, {start: 123}, ...
1
vote
1answer
50 views

How to save the bundle trytes to reattach after a snapshot? [closed]

How to save the bundle trytes to reattach it after a snapshot? How to do this using the JavaScript library?
1
vote
1answer
177 views

How to validate bundle hash

I've been working with a C# port of the API and have managed to get messages posted to the tangle. As most of these are zero values I thought I'd try reattach.online to help get them confirmed. When I ...
1
vote
1answer
222 views

Where is the IOTA-Data-MarketPlace API? [closed]

Is the IOTA-Data-MarketPlace API available? At the moment it looks like only the transactions API is available, correct?
4
votes
1answer
85 views

How to get child transactions?

What is the best way to get all children of a certain transaction using any of the IOTA libraries/the IOTA API? By children of a transaction, I mean all transactions that directly reference it.
1
vote
1answer
115 views

Is there a list of all IOTA addresses with non-zero balances?

I would like to know if we could fetch the Tangle to find every addresses with non-zero balances, or if there is already an existing list of all non-zero addresses?
7
votes
0answers
93 views

How to get the cumulative weight (and score, height, depth) of a transaction?

I know that I can get the weight of a transaction by converting the transaction hash into trits and count the trailing number of zeros. import iota def get_transaction_weight(transaction_hash): ...
2
votes
1answer
104 views

Compute key digest for multi sig wallet

Reading Generating Secure Multisig Addresses (for hot wallets and cold storage), I see the term "key digest". Is this key a private key associated with an address? How to compute the digest? Since ...
4
votes
1answer
224 views

How to get the sender address from an IOTA transfer

When calling the API with iota.api.getAccountData(receiveSeed, function(e, accountData), the transfer objects I see contain a field called "address" which contains the received address. I would like ...
6
votes
1answer
92 views

'Host Unkown' when trying to connect to Sandbox

We are trying to use the sandbox to test out some functions. I get no response when I ping http://sandbox.iotatoken.com/api/v1/. This does not work: var iota = new IOTA({ 'provider': 'http://...
4
votes
1answer
459 views

Extracting data from the tangle

The ownership distribution of Iota has been written about but HOW does one get these addresses? I looked at the Iota API and dont see an obvious way. And the tangle seems like some of it is in binary ...
6
votes
1answer
135 views

Is it correct that a wallet which does PoW never needs to call attachToTangle?

This is more or less to confirm my deeper understanding of IRI and how it all works. From the docs and the code what I see is, that attachToTangle outsources the PoW to a node. It is ...
5
votes
1answer
103 views

Attaching an address generated by an old version of the library?

For starters, let it be known that attaching an address to a seed is easy using the JS library: iota.api.sendTransfer(seed, 3, 14, [{"address": address, "value": 0, "message": "", "tag": ""}], ...
1
vote
1answer
94 views

How to restrict access to certain API commands so that only certain clients can call them?

If wallets use the API port and therefore access to certain functions needs to be restricted, how can a script of mine use the full API without those restrictions? For example https://iotasupport.com/...
4
votes
1answer
64 views

How do I find out whether a TX has been reattached?

Querying thetangle.org for one of my addresses, displays all TXs (= transactions) for this address and their state. thetangle.org displays pending, confirmed and reattached confirmed. I am wondering, ...
6
votes
1answer
84 views

Javascript Transaction object Message versus Tag

What is the difference between the Message and Tag values when creating a new transaction object via the JS library
2
votes
1answer
32 views

How do I convert the nonce into an integer value with the official JS lib?

I tried to use fromTrytes() but the function does not accept trytes with an odd length. The nonce appears to always have an odd length, e.g. EPV9MUTXNFDAFNIQLAZWTOLAFJT.
8
votes
2answers
129 views

Does “transactionsToRequest==0” mean a node is fully synced with its immediate peers?

I've read through the docs and other posts here. However, I'm not 100% clear as to what transactionsToRequest returned by getNodeInfo() means. Does "transactionsToRequest==0" mean, my node is fully ...
4
votes
1answer
31 views

Same Bundle Hash but currentIndex is always 0

I'm using findTransactionObjects() to receive all transaction objects for a given {address} which I used to receive IOTA. In the data structure that gets returned, one of the Bundle Hashes can be ...
2
votes
1answer
50 views

Invalid address input returned by findTransactions() though TX is avail on thetangle.org

If I submit my address ZOWKEWUCNRDICY9DWEPWGYCUZBZIFHR9MFK9ECSEDDTWNHVQYYHH9YMTVFODAWEEMNLURHCTXDXPGIVADBCXR9OOCZ at https://thetangle.org/ I get all the details for TXs on this address. However, ...
7
votes
1answer
109 views

Is it safe to expose the API to the public? [duplicate]

I just got a full node up and running, following the guide on here http://iota.partners/. I have a firewall on, so all ports are blocked except for UDP 14600 and TCP 15600. In my iota.ini file I have ...
2
votes
1answer
83 views

API Validation failed: Could not complete request

The following message is thrown in the logs when attempting to access my wallet: API Validation failed: Could not complete request
3
votes
1answer
61 views

Get approvers of transaction using api?

Given a transaction, how do I get a list of all of the transactions that reference it as their trunk or branch? I'm using pyota, but solutions in the other libraries would be appreciated too.
3
votes
1answer
67 views

What does the `security` param for `getNewAddress` do?

When I create addresses in the API library (i.e., using getNewAddress()), there is an optional security parameter. What does this parameter do, and what values does it accept?
6
votes
1answer
124 views

How does a client detect new IOTA transactions?

I am trying to understand IOTA at code level and the APIs. 1) How does a client know that there is a new transaction that it needs to fetch from a node? Does it keep calling findTransactions and ...
4
votes
2answers
75 views

ProxyPass a path to IRI's API

I would like to be able to set up a webserver on the same address as my node such that curl https://iota.example.com <html><body> Welcome to My IOTA Node! </body></html> and ...
8
votes
1answer
281 views

How to know a transaction is “confirmed”?

I'm building a little IOTA test project with TypeScript + Node.js. I want to start an action when IOTAs are received on an certain address. I've tried the findTransactionObjects function, but I don'...
2
votes
1answer
93 views

What commands are available via the API?

Where can I find a list of all the commands that the API accepts?
4
votes
1answer
54 views

Why can I not run commands on a node?

I am trying to query a node: curl http://my.node.addr:14265 \ > -X POST \ > -H 'Content-Type: application/json' \ > -H 'X-IOTA-API-Version: 1' \ > -d '{"command": "getNodeInfo"}'...
3
votes
1answer
66 views

How do I configure a public node?

How can I configure my node such that it is secure for public access? I am aware that I can use either the --remote-limit-api launch argument, or by setting it in my ini; REMOTE_LIMIT_API=...
5
votes
2answers
154 views

Authenticated remote IRI API calls. Fullnode startup flags and config

I want to enable API calls to my full node from an host besides localhost. The question is what startup flags or equivalent entries in an .ini config file do I need to make authenticated API calls? ...