Skip to main content
POST
/
settlement
/
prepare
curl -X POST https://api.convallax.com/settlement/prepare \
  -H "Content-Type: application/json" \
  -d '{ "seriesId": "98765432109876543210" }'
{
  "success": true,
  "seriesId": "98765432109876543210",
  "resolutionBps": 59,
  "validUntil": 1717189200,
  "signature": "0xabcdef1234...",
  "meta": {
    "vwap": 0.592341,
    "tradeCount": 142,
    "windowStart": 1717187400,
    "windowEnd": 1717189200
  }
}
Compute the resolution price for an expired option series and return a signed settlement attestation. The relay fetches YES token trades from Polymarket, computes the 30-minute VWAP, and signs an EIP-712 SettlementAttestation with the resolution signer’s key. The returned attestation can be relayed on-chain by calling settleWithAttestation() on ConvallaxCore.
This endpoint should be restricted in production. It is intended for cron jobs and internal automation, not public access.
seriesId
string
required
The option series ID to settle. Accepts hex (0x...) or decimal string format.
success
boolean
Whether the attestation was successfully generated.
seriesId
string
The series ID that was settled.
resolutionBps
number
Resolution price in basis points (0–100). Example: 59 = $0.59.
validUntil
number
Attestation expiry (Unix timestamp). Valid for 15 minutes after creation.
signature
string
EIP-712 signature from the resolution signer.
meta
object
curl -X POST https://api.convallax.com/settlement/prepare \
  -H "Content-Type: application/json" \
  -d '{ "seriesId": "98765432109876543210" }'
{
  "success": true,
  "seriesId": "98765432109876543210",
  "resolutionBps": 59,
  "validUntil": 1717189200,
  "signature": "0xabcdef1234...",
  "meta": {
    "vwap": 0.592341,
    "tradeCount": 142,
    "windowStart": 1717187400,
    "windowEnd": 1717189200
  }
}