Pending transactions on Avalanche C-Chain

Hello Moralis devs :slight_smile:

I am in need to access pending transactions / pending blocks on the Avalanche C-Chain.
Does Moralis offer an API which can do that?

Apparently not, based on this thread, but I would like to make sure of it.

Please consider that I cannot run a validator node myself.

Thank you for your time!
Cheers,
Guido

it may work to get the pending transactions using a speedy node, but you may get rate limited, and how fast avalanche moves, it may not make sense to process pending transactions as in 1 second a block could be mined

Oh, thanks @cryptokid!
Does this mean that Speedy Nodes are validator nodes?
AFAIK only validator nodes can access pending transactions.
Thanks

PS: Thank you for the remark about block speed; I am building a bot which will be competing in speed with other bots, hence my interest for pending transactions.

Our speedy nodes are not validator nodes

I see, cheers.
May I ask how can a Speedy Node access pending transactions without being a validator node?

It can have a list of pending transactions, but not a complete one

Please bear with me, but how can I list pending transactions if the node is not a validator?
I was under the impression that web3.eth.subscribe can only be used by full nodes.

The node can receive new transactions and send them to the other nodes

1 Like

Ahh ok, the node propagates some of the pending transactions, but does not validate them… but we can still access them! Cool :slight_smile:
Can I access these transactions with web3.eth.get_block('pending') or do I need something more fancy?

that syntax doesn’t work with our speedy nodes, you can only subscribe to pending transactions

1 Like

Thank you for your patience @cryptokid! I will make some tests and stop bothering you for a while :wink:
Have a nice day!