Options Intervals By Contract

Options Intervals By Contract Java API Documentation

Returns a list of interval data points for a contract.

API Class:
OptionsApi
Instance Method:
getOptionsIntervalByContract()

Stock Price Code Example

Use my API Key
import com.intrinio.api.*;
import com.intrinio.models.*;
import com.intrinio.invoker.*;
import com.intrinio.invoker.auth.*;
import org.threeten.bp.*;
import java.math.BigDecimal;
import java.util.*;
public class Main {
public static void main(String[] args) throws Exception {
ApiClient defaultClient = Configuration.getDefaultApiClient();
ApiKeyAuth auth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
auth.setApiKey("YOUR_API_KEY");
defaultClient.setAllowRetries(true);
OptionsApi optionsApi = new OptionsApi();
String identifier = "SPY___230103P00380000";
String intervalSize = "5m";
String source = null;
Integer pageSize = 100;
OffsetDateTime endTime = OffsetDateTime.now();
OptionIntervalsResult result = optionsApi.getOptionsIntervalByContract(identifier, intervalSize, source, pageSize, endTime);
System.out.println(result);
}
}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Parameters

NameTypeDescriptionNotes
identifierStringThe Intrinio ID or code of the options contract to request intervals for. 
intervalSizeStringThe time length of the interval.[enum: SixtyMinute, 60m, 1h, ThirtyMinute, 30m, FifteenMinute, 15m, TenMinute, 10m, FiveMinute, 5m, OneMinute, 1m]  
sourceStringRealtime or 15-minute delayed contracts.[optional] [enum: realtime, delayed]  
pageSizeIntegerThe number of results to return[optional] [default to 100]  
endTimeOffsetDateTimeThe inclusive UTC date and time the intervals end at.[optional]  


Return Type

object
OptionIntervalsResult

Properties

NameTypeDescription
intervalsListArray of all the intervals in the result.  
contractStringThe option contract for the intervals  
sizeSizeEnumThe size of the time span for the interval.  
object
OptionInterval

Properties

NameTypeDescription
openTimeOffsetDateTimeThe UTC timestamp for the time this interval opened.  
closeTimeOffsetDateTimeThe UTC timestamp for the time this interval closed.  
openBigDecimalThe first traded contract price in this interval.  
highBigDecimalThe highest traded contract price in this interval.  
lowBigDecimalThe lowest traded contract price in this interval.  
closeBigDecimalThe last traded contract price in this interval.  
volumeBigDecimalThe volume of contracts traded in this interval.  
averageBigDecimalThe volume weighted average price of contract trades in this interval.  
changeBigDecimalThe ratio of Close minus Open to Open.  
tradeCountBigDecimalThe number of qualified trades executed during the period