# OI per Expiry `GET` `https://api.unusualwhales.com/api/stock/{ticker}/oi-per-expiry` Returns the total open interest for calls and puts for a specific expiry date. ## Authentication ``` Authorization: Bearer YOUR_API_KEY ``` ## Path Parameters | Name | Type | Required | Description | |------|------|----------|-------------| | `ticker` | SingleTicker | Yes | A single ticker | ## Query Parameters | Name | Type | Required | Description | |------|------|----------|-------------| | `date` | Optional Market Date | No | A trading date in the format of YYYY-MM-DD. This is optional and by default the last trading date. | ## Response (200) | Field | Type | Description | |-------|------|-------------| | `call_oi` | Total Call Open interest | The total call open interest. | | `date` | Market General Trading day | A trading date in ISO format. | | `expiry` | Option Contract Expiry | The contract expiry date in ISO format. | | `put_oi` | Total Put Open interest | The total put open interest. | ## Example ### curl ```bash curl -X GET "https://api.unusualwhales.com/api/stock/{ticker}/oi-per-expiry" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Accept: application/json" ``` ### Python ```python import http.client conn = http.client.HTTPSConnection("api.unusualwhales.com") headers = {"Authorization": "Bearer YOUR_API_KEY", "Accept": "application/json"} conn.request("GET", "/api/stock/{ticker}/oi-per-expiry", headers=headers) response = conn.getresponse() print(response.read().decode("utf-8")) ``` ## Response Example ```json { "data": [ { "call_oi": 1123, "date": "2024-12-02", "expiry": "2024-12-06", "put_oi": 24443 } ] } ```