Skip to main content

1. Check the service is up

curl https://api.vatic.trading/health
{ "ok": true, "service": "vatic-api", "now": "2025-04-07T12:00:00.000Z" }

2. Fetch the current BTC 5-minute target price

curl "https://api.vatic.trading/api/v1/targets/active?asset=btc&types=5min"
{
  "now": "2025-04-07T12:00:00.000Z",
  "asset": "btc",
  "results": [
    {
      "marketType": "5min",
      "ok": true,
      "windowStart": 1744027500,
      "windowStartIso": "2025-04-07T12:05:00.000Z",
      "source": "chainlink",
      "price": 82450.75
    }
  ]
}

3. Get all market windows for today

curl "https://api.vatic.trading/api/v1/markets/timestamps?asset=btc&intervals=5min"
Each entry includes the Polymarket event slug and URL — no manual slug-building needed.

4. Look up a token ID by market slug

curl "https://api.vatic.trading/api/v1/markets/tokenId?slug=will-arsenal-win-the-202526-english-premier-league&outcome=Yes"
{
  "tokenId": "71321045679252212594626385532706912750332728571942532289631379312455583992563",
  "outcome": "Yes",
  "outcomeIndex": 0,
  "conditionId": "0xabc...",
  "negRisk": false
}

5. Place a market order (API key required)

curl -X POST https://api.vatic.trading/api/v1/simpleOrders/easyMarketOrder \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "walletId": "550e8400-e29b-41d4-a716-446655440000",
    "slug": "will-arsenal-win-the-202526-english-premier-league",
    "outcome": "Yes",
    "side": "BUY",
    "amount": 50
  }'
{
  "ok": true,
  "orderId": "0xdef...",
  "status": "matched",
  "latencyS": 0.83,
  "order": { "slug": "...", "outcome": "Yes", "side": "BUY", "amount": 50 }
}
The easyMarketOrder endpoint resolves the token ID for you. For programmatic trading where you already have a tokenId, use createMarketOrder or createLimitOrder directly.