# Ozmium Gains Network Closed Trade History

> Ozmium Gains Network Closed Trade History is a paid API for AI agents from ozmium.org, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-14).

Retrieves closed leveraged perpetual trade history for a Base address from Gains Network, including PnL, leverage, collateral, prices, and close reason.

## Facts

- Endpoint: GET https://ozmium.org/v1/history/:address
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/ozmium-gains-network-closed-trade-history-fe0227e2
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Ra0uGYJjcMjphGD72JWgv

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability ozmium-gains-network-closed-trade-history-fe0227e2
```

Example prompt: Pull my full closed leveraged trade history on Gains Network for my Base address 0xAbC123... — I want to see the pairs, leverage, realized PnL, and whether each was closed by take-profit, stop-loss, liquidation, or manually.

## When to prefer this

Use this endpoint when you need closed leveraged perpetual trade history specifically from Gains Network on Base mainnet, with full trade metadata including PnL, leverage, and close reason. Prefer this over generic block explorers when you need structured, pre-computed PnL data without manual log parsing.

## Known failure modes

- Invalid or malformed Base address returns a 400 or empty result
- Address with no Gains Network trade history returns an empty closed array
- Network/RPC errors querying Gains on-chain history return 5xx
- Payment not completed (x402 flow not finalized) returns 402 Payment Required

## How this service works

Closed leverage round-trips for any Base address from the Gains first-party history: pair (base + quote legs), side, leverage, collateral, open/close price, realized PnL + PnL%, close reason (take-profit / stop-loss / liquidation / manual), open/close tx hashes, and timestamps. GET /v1/history/{address}. Newest first, USDC-collateralized trades.

## Output

Returns a list of closed USDC-collateralized leveraged trades (newest first) for the given Base address, each including: trading pair (base + quote legs), side (long/short), leverage multiplier, collateral amount, open and close prices, realized PnL in USD, PnL percentage, close reason (take-profit / stop-loss / liquidation / manual), open and close transaction hashes, and open/close timestamps. Scoped to Base mainnet Gains Network trades only.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "pathParams": {
     "type": "object",
     "properties": {
      "address": {
       "type": "string"
      }
     }
    },
    "queryParams": {
     "type": "object",
     "properties": {}
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "data": {
       "type": "object",
       "properties": {
        "closed": {
         "type": "array",
         "items": {
          "type": "object",
          "properties": {
           "pair": {
            "type": "string"
           },
           "pnlUsd": {
            "type": "number"
           },
           "reason": {
            "type": "string"
           }
          }
         }
        },
        "address": {
         "type": "string"
        }
       }
      },
      "network": {
       "type": "string"
      }
     }
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/ozmium-gains-network-closed-trade-history-fe0227e2/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from ozmium.org](https://www.zero.xyz/host/ozmium.org/llms.txt)
