Read the fields
Developer reference.
Inspect synthetic option records, review the schema, and practice an explicit contract → observation → quality workflow. No credentials or private accounts are involved.
Local files. Working examples.
These resources are ordinary static JSON files served by this website. They demonstrate a proposed schema, not a live data subscription or a universal provider format. Download a file directly or inspect the selected fields in the explorer.
The example contract expiry is a scenario field. The fixture observation time is September 10, 2026 at 14:30 UTC; no displayed value refreshes with market activity.
{
"data_mode": "synthetic",
"contract_id": "EXAMPLE-20261218-C-100",
"option_type": "call",
"strike": 100,
"premium_currency": "USD",
"premium_multiplier": 100
}{
"data_mode": "synthetic",
"contract_id": "EXAMPLE-20261218-C-100",
"observed_at": "2026-09-10T14:30:00Z",
"bid": 2.1,
"ask": 2.4,
"midpoint": 2.25,
"quote_unit": "USD per share",
"is_live": false
}{
"data_mode": "synthetic",
"contract_id": "EXAMPLE-20261218-C-105",
"bid": null,
"ask": 0.9,
"midpoint": null,
"quality": {
"status": "incomplete",
"reason": "Missing bid; no two-sided midpoint is calculated."
},
"is_live": false
}A chain with its units attached.
All six rows are invented. Premium quotations are USD per share, the illustrative premium multiplier is 100, and the expiration date is December 18, 2026. The spread below is ask minus bid; it is not an execution guarantee.
| Contract ID | Type | Strike | Bid | Ask | Spread |
|---|---|---|---|---|---|
| EXAMPLE-20261218-C-95 | Call | 95 | 6.10 | 6.40 | 0.30 |
| EXAMPLE-20261218-C-100 | Call | 100 | 2.10 | 2.40 | 0.30 |
| EXAMPLE-20261218-C-105 | Call | 105 | 0.70 | 0.90 | 0.20 |
| EXAMPLE-20261218-P-95 | Put | 95 | 0.60 | 0.80 | 0.20 |
| EXAMPLE-20261218-P-100 | Put | 100 | 2.00 | 2.30 | 0.30 |
| EXAMPLE-20261218-P-105 | Put | 105 | 5.70 | 6.00 | 0.30 |
No Greeks are supplied in this fixture. The missing-bid example deliberately leaves its midpoint null instead of converting unknown data to zero.
Three layers to keep separate
1. Contract reference
Identity, underlying, strike, expiry, exercise style, settlement method and premium scale describe the instrument. The minimal schema validates the local demonstration only. A production catalog may need adjusted baskets, more precise clocks and additional product-specific fields.
2. Observations
Quotes and trades carry their own source times and units. Preserve raw values and provider identifiers before normalizing them. A collection timestamp is not automatically the time when the market last changed a field.
3. Calculations and quality
Keep midpoint, spread and modeled values separate from observed fields. State required inputs and return unavailable when those inputs are missing. A syntactically valid file does not establish correct economic interpretation.
Integration boundaries
Live data requires a provider, verified instrument coverage and the appropriate permissions. Private credentials do not belong in public HTML or JavaScript. Order routing requires a separate account-authorized service and independent checks; none is included or simulated here.
Start with a contract catalog, test complete and incomplete snapshots, then evaluate pagination, timestamps, reconnects and source limits against the provider’s actual documentation. The option API guide develops that workflow.
The model-assisted workflow belongs in a different control layer. Read the AI options control article before interpreting a proposal as an instruction that has permission to execute.
Read a local example in JavaScript
Run this from a page on OptionAPI.com or the same-origin hosted copy. It reads the static fixture and prints its rows. It does not contact an exchange or submit an order.
// Local synthetic fixture: no key, provider call, or order routing.
async function readSampleChain() {
const response = await fetch('/assets/data/sample-chain.json');
if (!response.ok) throw new Error(`HTTP ${response.status}`);
const data = await response.json();
if (data.data_mode !== 'synthetic' || !Array.isArray(data.contracts)) {
throw new Error('Unexpected sample structure');
}
return data.contracts.map(record => {
const valid = Number.isFinite(record.bid)
&& Number.isFinite(record.ask)
&& record.ask >= record.bid;
return { ...record, spread: valid ? record.ask - record.bid : null };
});
}
readSampleChain().then(console.table).catch(console.error);Inspect the file with Python
Save the Python inspector and the sample chain in the same local folder. Python 3 and its standard library are sufficient. Run:
python3 inspect-chain.py sample-chain.jsonThe inspector rejects a file that is not labeled synthetic and prints unavailable for an incomplete or inconsistent quotation. It is a small teaching example, not a complete market-data validator.
Read the record.
Build with clarity.
Go from a market label to a field you can explain. Start with the guides, then inspect the local JSON examples.