getEquityOptionsIntraday API

The getEquityOptionsIntraday API provides intraday options data such as strike, expiration date, volatility, etc.

All APIs

Contact Us to Get Access

Inputs

underlying_symbols required

A valid equity symbol

Type
list (A comma or semi-colon delimited string.) 
Example
AAPL 

type optional

The type of option desired, Call or Put.

Type
string (A sequence of characters. (example: GOOG)) 
Example
Call 

strikePrice optional

The strike price of the option.

Type
double (A numeric type defining a number with fractional parts. (example: 2.14)) 
Example
37.5 

expirationMonth optional

The numeric representation of the expiration month.

Type
string (A sequence of characters. (example: GOOG)) 
Example
05 

expirationDate optional

The numeric date for of the expiration day.

Type
string (A sequence of characters. (example: GOOG)) 
Example
2017-11-07 

fields optional

Additional fields requested.

Type
list (A comma or semi-colon delimited string.) 
Example
bid,bidSize,ask,askSize 

onlyStrikes optional

To return only the strike prices.

Type
boolean (A logical type representing the truth of a value as 'true' or 'false'.) 
Example

Outputs

Name / Requirement
Description
Type
underlying_symbol
always returned
The actual equity symbol.
string
A sequence of characters. (example: GOOG)
symbol
always returned
A symbol or code that identifies the equity contract.
string
A sequence of characters. (example: GOOG)
exchange
always returned
The name of the exchange the instrument belongs to.
string
A sequence of characters. (example: GOOG)
type
always returned
Either Call or Put.
string
A sequence of characters. (example: GOOG)
strike
always returned
The option's strike price.
double
A numeric type defining a number with fractional parts. (example: 2.14)
expirationDate
always returned
The expiration date.
date
A date in the format of YYYY-MM-DD.
expirationType
always returned
The expiration type.
string
A sequence of characters. (example: GOOG)
date
always returned
The price date.
datetime
A date and time in the format of YYYY-MM-DD HH:MI:SS<TIMEZONE_OFFSET>.
volatility
as requested
The estimated volatility of a security's price.
double
A numeric type defining a number with fractional parts. (example: 2.14)
delta
as requested
The option's delta value.
double
A numeric type defining a number with fractional parts. (example: 2.14)
gamma
as requested
The option's gamma value.
double
A numeric type defining a number with fractional parts. (example: 2.14)
theta
as requested
The option's theta value.
double
A numeric type defining a number with fractional parts. (example: 2.14)
vega
as requested
The option's vega value.
double
A numeric type defining a number with fractional parts. (example: 2.14)
rho
as requested
The option's rho value.
double
A numeric type defining a number with fractional parts. (example: 2.14)
bid
as requested
The current bid price.
double
A numeric type defining a number with fractional parts. (example: 2.14)
bidSize
as requested
The size (quantity) of the current bid price.
int
A numeric type defining a whole number. (example: 2)
bidDate
as requested
The date of the current bid price.
date
A date in the format of YYYY-MM-DD.
ask
as requested
The current ask price.
double
A numeric type defining a number with fractional parts. (example: 2.14)
askSize
as requested
The size (quantity) of the current ask price.
int
A numeric type defining a whole number. (example: 2)
askDate
as requested
The date of the current ask price.
date
A date in the format of YYYY-MM-DD.
open
always returned
The opening (first) price for the session.
double
A numeric type defining a number with fractional parts. (example: 2.14)
high
always returned
The highest traded price for the session.
double
A numeric type defining a number with fractional parts. (example: 2.14)
low
always returned
The lowest traded price for the session.
double
A numeric type defining a number with fractional parts. (example: 2.14)
last
always returned
The last price the instrument traded.
double
A numeric type defining a number with fractional parts. (example: 2.14)
change
always returned
The difference between the last traded price and the previous close.
double
A numeric type defining a number with fractional parts. (example: 2.14)
percentChange
always returned
The percent difference between the last traded price and the previous close.
double
A numeric type defining a number with fractional parts. (example: 2.14)
premium
as requested
The option's premium
double
A numeric type defining a number with fractional parts. (example: 2.14)
flag
as requested
The option's settled flag)
string
A sequence of characters. (example: GOOG)
settlement
as requested
The option's settlement price
double
A numeric type defining a number with fractional parts. (example: 2.14)
lastTradeDate
as requested
The last trading date for the option
date
A date in the format of YYYY-MM-DD.
volume
always returned
The trading volume for the option
integer
A numeric type defining a whole number. (example: 2)
openInterest
as requested
The open interest for the option
integer
A numeric type defining a whole number. (example: 2)
lastUpdateDate
as requested
The timestamp for the last traded option price.
dateTime
A date and time in the format of YYYY-MM-DD HH:MI:SS<TIMEZONE_OFFSET>.

Status Code Responses

200
OK
Success
400
Bad Request
The request was invalid, please see the message for more information.
500
Internal Server Error
Something is not working correctly, please contact support.


JSON

GET

GET https://ondemand.websol.barchart.com/getEquityOptionsIntraday.json?apikey=<YOUR API KEY>&underlying_symbols=AAPL&type=Call&expirationMonth=05&fields=bid%2CbidSize%2Cask%2CaskSize&onlyStrikes=1
Host: ondemand.websol.barchart.com

POST

POST https://ondemand.websol.barchart.com/getEquityOptionsIntraday.json
Host: ondemand.websol.barchart.com
Content-Type: application/x-www-form-urlencoded
Content-Length: length

apikey=<YOUR API KEY>&underlying_symbols=AAPL&type=Call&expirationMonth=05&fields=bid%2CbidSize%2Cask%2CaskSize&onlyStrikes=1

Response

{
    "status": {
        "code": 204,
        "message": "Success, but no content to return."
    },
    "results": null
}

XML

GET

GET https://ondemand.websol.barchart.com/getEquityOptionsIntraday.xml?apikey=<YOUR API KEY>&underlying_symbols=AAPL&type=Call&expirationMonth=05&fields=bid%2CbidSize%2Cask%2CaskSize&onlyStrikes=1
Host: ondemand.websol.barchart.com

POST

POST https://ondemand.websol.barchart.com/getEquityOptionsIntraday.xml
Host: ondemand.websol.barchart.com
Content-Type: application/x-www-form-urlencoded
Content-Length: length

apikey=<YOUR API KEY>&underlying_symbols=AAPL&type=Call&expirationMonth=05&fields=bid%2CbidSize%2Cask%2CaskSize&onlyStrikes=1

Response


<?xml version="1.0" encoding="utf-8"?>
 <getEquityOptionsIntraday>
  <status>
   <code>204</code>
   <message>Success, but no content to return.</message>
  </status>
 </getEquityOptionsIntraday>

CSV

GET

GET https://ondemand.websol.barchart.com/getEquityOptionsIntraday.csv?apikey=<YOUR API KEY>&underlying_symbols=AAPL&type=Call&expirationMonth=05&fields=bid%2CbidSize%2Cask%2CaskSize&onlyStrikes=1
Host: ondemand.websol.barchart.com

POST

POST https://ondemand.websol.barchart.com/getEquityOptionsIntraday.csv
Host: ondemand.websol.barchart.com
Content-Type: application/x-www-form-urlencoded
Content-Length: length

apikey=<YOUR API KEY>&underlying_symbols=AAPL&type=Call&expirationMonth=05&fields=bid%2CbidSize%2Cask%2CaskSize&onlyStrikes=1

Response




PHP

<?php

$ondemand = new SoapClient('https://ondemand.websol.barchart.com/service?wsdl');

$params = [
    'underlying_symbols' => 'AAPL',
    'type' => 'Call',
    'expirationMonth' => '05',
    'fields' => 'bid,bidSize,ask,askSize',
    'onlyStrikes' => '1',
];

$result = $ondemand->getEquityOptionsIntraday($params);
var_dump($result);

Classic ASP

Dim ondemand
Dim result

Set ondemand = Server.CreateObject("MSSOAP.SoapClient30")
ondemand.ClientProperty("ServerHTTPRequest") = True
ondemand.MSSoapInit("https://ondemand.websol.barchart.com/service?wsdl")

Set result = ondemand.getEquityOptionsIntraday("AAPL", "Call", "05", "bid,bidSize,ask,askSize", "1")

Perl

use SOAP::Lite;
use SOAP::WSDL;

my $ondemand = SOAP::Lite
    -> service('https://ondemand.websol.barchart.com/service?wsdl');

my $result = $ondemand->getEquityOptionsIntraday('AAPL', 'Call', '05', 'bid,bidSize,ask,askSize', '1');

print $result;

Python

from suds.client import Client
ondemand = Client('https://ondemand.websol.barchart.com/service?wsdl')

result = client.service.getEquityOptionsIntraday('AAPL', 'Call', '05', 'bid,bidSize,ask,askSize', '1')

print result

Ruby

require 'savon'

ondemand = Savon.client(wsdl: 'https://ondemand.websol.barchart.com/service?wsdl')

response = ondemand.call(
    :getEquityOptionsIntraday,
    message: {
        underlying_symbols: 'AAPL',
        type: 'Call',
        expirationMonth: '05',
        fields: 'bid,bidSize,ask,askSize',
        onlyStrikes: '1',
    }
)

response.body