Pretrade
by LiquidVision.app in Onchain & crypto
LiquidVision.app: Pre-trade check for a leveraged crypto perpetual position: liquidation price on 12 exchanges, liquidation levels between the price and it, how often price moved that far, fear & greed, Hyperliquid whale positioning and funding cost, with flags for what goes against the trade.
https://liquidvision.app/api/v1/pretrade- Price
- $0.05
- per call in USDC
- Uptime
- 98.4%
- last 30 days
- Response time
- 204 ms
- 277 ms slowest 5%
- Last check
- Passed
- 5 h ago, next any minute now
Reliability
Status and outage history · Atom feed · Watch with other listings
How to call it
GET https://liquidvision.app/api/v1/pretrade
Each call costs $0.05 in USDC on Arbitrum, paid with the request over x402.
Run a free test callOne unpaid request, the way an agent sends it. You see the payment challenge it gets back. Nothing is charged.
Example request
From the listing.
GET https://liquidvision.app/api/v1/pretrade?leverage=20¬ional_usd=50000&side=long&symbol=BTCParameters
| Parameter | Type | Required | Description |
|---|---|---|---|
leverage | string | No | |
notional_usd | string | No | |
side | string | No | |
symbol | string | No |
Example response
The provider's example. We can't check it without paying.
Example response, 62 lines
{
"entry": 68518.8,
"entry_assumed_at_mark": true,
"fear_greed": {
"label": "neutral",
"score": 44.1
},
"flags": [
"the largest modeled cex liquidation level on your side ($498,094,633 at -3.0%) sits before your liquidation price"
],
"funding_cost_per_day_usd": {
"max": 17.9,
"min": -1.2
},
"hyperliquid_whales": {
"long_share_pct": 43.4,
"long_usd": 948683593,
"short_usd": 1239241010
},
"leverage": 20,
"liquidation": {
"archive": {
"hours_in_archive": 2819,
"share_of_hours_price_moved_that_far_against_you_72h_pct": 5.1
},
"farthest": {
"distance_pct": -4.64,
"price": 65336.3,
"venue": "binance"
},
"nearest": {
"distance_pct": -4.55,
"price": 65402.1,
"venue": "gate"
},
"venues": [
{
"distance_pct": -4.64,
"funding_cost_per_day_usd": 5.65,
"margin_source": "exchange",
"price": 65336.3,
"venue": "binance"
}
]
},
"liquidation_levels": {
"modeled_cex": {
"largest_level_below": {
"distance_pct": -3,
"price_from": 65863.7,
"price_to": 67235.8,
"usd": 498094633
},
"longs_liquidated_below_usd": 1279094279
}
},
"mark": 68518.8,
"notional_usd": 50000,
"side": "long",
"symbol": "BTCUSDT",
"ts": 1794550000000
}Call it from code
The curl command shows the payment challenge. The JavaScript and Python versions pay and call, and never pay more than $0.05.
curl: see the payment challenge
# bash or zsh: see the payment challenge. Nothing is charged.
curl -sS -g -i 'https://liquidvision.app/api/v1/pretrade?leverage=20¬ional_usd=50000&side=long&symbol=BTC'
# x402 v2 sends the challenge base64-encoded in the PAYMENT-REQUIRED header (v1 sends it in the body).
# To read the header:
curl -sS -g -o /dev/null -D - 'https://liquidvision.app/api/v1/pretrade?leverage=20¬ional_usd=50000&side=long&symbol=BTC' \
| grep -i '^payment-required:' | cut -d' ' -f2 | tr -d '\r' | base64 --decodeJavaScript: pay and call
// npm i @x402/fetch @x402/evm viem
import { wrapFetchWithPayment, x402Client } from "@x402/fetch";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
// Pays at most $0.05 per call.
const client = new x402Client().setSpendControls({ maxAmountPerPayment: "$0.05" });
registerExactEvmScheme(client, { signer: privateKeyToAccount(process.env.EVM_PRIVATE_KEY) });
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? ToolVet checks it first for $0.005. Pay for that from a separate
// client: this one is capped at $0.05 per payment. GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fliquidvision.app%2Fapi%2Fv1%2Fpretrade
const res = await pay("https://liquidvision.app/api/v1/pretrade?leverage=20¬ional_usd=50000&side=long&symbol=BTC");
console.log(res.status, await res.text());Python: pay and call
# pip install "x402[requests,evm]"
import os
from eth_account import Account
from x402 import x402ClientSync
from x402.http.clients import x402_requests
from x402.mechanisms.evm import EthAccountSigner
from x402.mechanisms.evm.exact.register import register_exact_evm_client
# Pays at most $0.05 per call.
client = x402ClientSync().set_spend_controls({"max_amount_per_payment": "$0.05"})
register_exact_evm_client(client, EthAccountSigner(Account.from_key(os.environ["EVM_PRIVATE_KEY"])))
with x402_requests(client) as session:
res = session.get("https://liquidvision.app/api/v1/pretrade?leverage=20¬ional_usd=50000&side=long&symbol=BTC")
print(res.status_code, res.text)Security scan
No findings
We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 5 h ago | Passed | 402 | 149 ms | $0.05 |
| 16 h ago | Passed | 402 | 183 ms | $0.05 |
| 26 h ago | Passed | 402 | 159 ms | $0.05 |
| 36 h ago | Passed | 402 | 183 ms | $0.05 |
| 46 h ago | Passed | 402 | 90 ms | $0.05 |
Show 10 older checks
| 2 days ago | Passed | 402 | 179 ms | $0.05 |
| 3 days ago | Passed | 402 | 64 ms | $0.05 |
| 5 days ago | Timed out | - | - | - |
| 6 days ago | Passed | 402 | 200 ms | $0.05 |
| 7 days ago | Passed | 402 | 62 ms | $0.05 |
| 7 days ago | Passed | 402 | 254 ms | $0.05 |
| 7 days ago | Passed | 402 | 113 ms | $0.05 |
| 8 days ago | Passed | 402 | 105 ms | $0.05 |
| 8 days ago | Passed | 402 | 198 ms | $0.05 |
| 9 days ago | Passed | 402 | 62 ms | $0.05 |