alperp-1
v0.0.1
Published
Detects the opening of a large positon and increase of an existing large position
Downloads
2
Readme
Large Open/Increase Position Size Bot
Description
This bot detects a large size position opening and a large increase in an existing position. It listens to UpdatePosition
and IncreasePosition
event emissions on Perp Trade Contract and creates a finding if sizeDelta
exceeds a threshold
.
The
threshold
can be adjusted in src/network.ts.
Supported Chains
- Polygon
Alerts
ALPERP-1-1
- Fired when a newly open position size is large
- Severity is always set to "Info".
- Type is always set to "Info".
- Metadata contains:
perpTrade
: Address of Perp Trade contract.account
: Address of position owner.positionSize
: Size of the opened position.positionKey
: Key of the opened position.
ALPERP-1-2
- Fired when there is a large increase of an existing position
- Severity is always set to "Info".
- Type is always set to "Info".
- Metadata contains:
perpTrade
: Address of Perp Trade contract.account
: Address of position owner.positionIncrementSize
: Size of the increased positionfinalPositionSize
: Final position size after incrementpositionKey
: Key of the increased position.
Test Data
The bot behaviour can be verified with the following transactions:
0xa1497f703ad237a5f43a2df93fe961394e5df2ad548d4cb02c45a865d8fda591 -
Arbitrum Mainnet
- UpdatePosition eventPosition size - 147986.41
0x70562d5cda648946dcefaf394f1db5591122b61a7924fc17e473fa0372a13213 -
Arbitrum Mainnet
- IncreasePosition eventPosition increment size - 23928.22