Skip to content
Socket

Catalog / module / Socket plug-ins

Trade tracker

v1

On-chain counters and a recent-trades feed for your socket pool, for dashboards and bots.

Runs on every swapWatches trades
  • Watches trades: Is told about each trade after it settles. It cannot change or block it.

What it does

Trade tracker (volume-observer v1)

A socket hooklet that records the trades in your socket pool on-chain, so dashboards and bots can read them. Robinhood Chain's public RPC only returns 5 blocks of logs, so on-chain counters are the reliable source.

What it records

- **Totals:** number of trades and buys, ETH volume, buy volume, token volume, ETH taken by fee hooklets, first and last trade time. - **Recent trades:** the last 64 trades with time, side, ETH and token amounts. Older trades are overwritten.

Roles

- **Owner:** can pause tracking and resume it. - **The socket:** the only address that can report trades.

Risks in plain English

- It never takes, holds or moves funds. - It only sees trades through your socket pool, not trades made on pons directly. - It adds a little gas to every trade in your socket pool.

Fee lanes

None. It has no income.

What if

- **It breaks?** The socket skips it after three failures in an hour. Trading is never affected. - **I pause it?** Trades during the pause are not counted. - **I want more than 64 recent trades?** Read the counters regularly, or run the Socket worker, which keeps history off-chain.

Risks in plain English

  • It only sees trades through your socket pool, not trades made on pons directly.
  • It keeps the last 64 trades; older ones are overwritten. Totals are never reset.

What if…

Does it cost traders anything?
No fee. It adds a little gas to each trade in your socket pool.
What if it breaks?
The socket skips it after three failures in an hour. Trading is never affected.
Can it move funds?
No. It never takes or holds anything.

Fees

No protocol fee on this module.

Evidence

Form check
Built from the source files
Implementation
—
Code hash
—

Settings you choose at deploy

    Used in recipes