{
  "format": "delx/intent-card/v1",
  "id": "pnl-abs-api",
  "intent": "Absolute PnL for an agent workflow",
  "title": "Absolute PnL API for agents",
  "description": "Absolute profit/loss from entry, exit, and position size. Call when marking closed trades or paper fills without a broker API. Returns absolute pnl in quote units as deterministic JSON for $0.001 USDC via x402 on Base. First-party local math only—no RPC, live market feed, API keys, storage, or mediagen. Advisory only; the caller owns capital, risk, and production controls.",
  "keywords": [
    "Absolute PnL API",
    "Absolute PnL for agents",
    "pay per result API",
    "x402 API",
    "no API key"
  ],
  "updated_at": "2026-08-23",
  "canonical_url": "https://commerce.delx.ai/intents/pnl-abs-api",
  "machine_url": "https://commerce.delx.ai/intents/pnl-abs-api.json",
  "recommendation": {
    "tool_name": "util_pnl_abs",
    "service_name": "Absolute PnL",
    "method": "POST",
    "resource": "https://api.delx.ai/api/v1/x402/pnl-abs",
    "price_usdc": "0.001",
    "payment_protocols": [
      "x402",
      "mpp"
    ],
    "input_schema": {
      "type": "object",
      "properties": {
        "entry": {
          "description": "Input field: entry.",
          "type": "integer"
        },
        "exit": {
          "description": "Input field: exit.",
          "type": "integer"
        },
        "size": {
          "description": "Input field: size.",
          "type": "integer"
        }
      },
      "required": [
        "entry",
        "exit",
        "size"
      ],
      "additionalProperties": true
    },
    "example_input": {
      "entry": 100,
      "exit": 110,
      "size": 2
    },
    "example_output": {
      "schema": "delx/util-pnl-abs/v1",
      "entry": 100,
      "exit": 110,
      "size": 2,
      "pnl": 20
    },
    "agentcash": {
      "buy": "npx agentcash@latest fetch https://api.delx.ai/api/v1/x402/pnl-abs -m POST -H 'x-delx-source: intent-card-pnl-abs-api' --max-amount 0.001 -b '{\"entry\":100,\"exit\":110,\"size\":2}'",
      "max_amount_usdc": "0.001"
    }
  },
  "attribution": {
    "header": "x-delx-source",
    "value": "intent-card-pnl-abs-api"
  },
  "evidence": {
    "paid_openapi": "https://api.delx.ai/openapi.x402.json",
    "governed_portfolio": "https://api.delx.ai/x402-portfolio.json",
    "live_contract": "https://api.delx.ai/api/v1/x402/pnl-abs"
  }
}
