Option Trades By Contract

Option Trades By Contract Java API Documentation

Returns all trades for a contract between start time and end time, up to seven days ago for the specified source.

API Class:
OptionsApi
Instance Method:
getOptionTradesByContract()

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 = "AAPL__261218C00230000";
String source = null;
LocalDate startDate = null;
String startTime = null;
LocalDate endDate = null;
String endTime = null;
String timezone = "UTC";
Integer pageSize = 100;
Integer minSize = 100;
String nextPage = null;
OptionTradesResult result = optionsApi.getOptionTradesByContract(identifier, source, startDate, startTime, endDate, endTime, timezone, pageSize,
      minSize, nextPage);
System.out.println(result);
}
}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Parameters

NameTypeDescriptionNotes
identifierStringThe option contract for which trades are being requested. 
sourceStringThe specific source of the data being requested.[optional] [enum: realtime, delayed]  
startDateLocalDateThe start date for the data being requested.[optional]  
startTimeStringThe start time for the data being requested.[optional]  
endDateLocalDateThe end date for the data being requested.[optional]  
endTimeStringThe end time for the data being requested.[optional]  
timezoneStringThe timezone the start and end date/times use.[optional] [default to UTC] [enum: Africa/Algiers, Africa/Cairo, Africa/Casablanca, Africa/Harare, Africa/Johannesburg, Africa/Monrovia, Africa/Nairobi, America/Argentina/Buenos_Aires, America/Bogota, America/Caracas, America/Chicago, America/Chihuahua, America/Denver, America/Godthab, America/Guatemala, America/Guyana, America/Halifax, America/Indiana/Indianapolis, America/Juneau, America/La_Paz, America/Lima, America/Lima, America/Los_Angeles, America/Mazatlan, America/Mexico_City, America/Mexico_City, America/Monterrey, America/Montevideo, America/New_York, America/Phoenix, America/Regina, America/Santiago, America/Sao_Paulo, America/St_Johns, America/Tijuana, Asia/Almaty, Asia/Baghdad, Asia/Baku, Asia/Bangkok, Asia/Bangkok, Asia/Chongqing, Asia/Colombo, Asia/Dhaka, Asia/Dhaka, Asia/Hong_Kong, Asia/Irkutsk, Asia/Jakarta, Asia/Jerusalem, Asia/Kabul, Asia/Kamchatka, Asia/Karachi, Asia/Karachi, Asia/Kathmandu, Asia/Kolkata, Asia/Kolkata, Asia/Kolkata, Asia/Kolkata, Asia/Krasnoyarsk, Asia/Kuala_Lumpur, Asia/Kuwait, Asia/Magadan, Asia/Muscat, Asia/Muscat, Asia/Novosibirsk, Asia/Rangoon, Asia/Riyadh, Asia/Seoul, Asia/Shanghai, Asia/Singapore, Asia/Srednekolymsk, Asia/Taipei, Asia/Tashkent, Asia/Tbilisi, Asia/Tehran, Asia/Tokyo, Asia/Tokyo, Asia/Tokyo, Asia/Ulaanbaatar, Asia/Urumqi, Asia/Vladivostok, Asia/Yakutsk, Asia/Yekaterinburg, Asia/Yerevan, Atlantic/Azores, Atlantic/Cape_Verde, Atlantic/South_Georgia, Australia/Adelaide, Australia/Brisbane, Australia/Darwin, Australia/Hobart, Australia/Melbourne, Australia/Melbourne, Australia/Perth, Australia/Sydney, Etc/UTC, UTC, Europe/Amsterdam, Europe/Athens, Europe/Belgrade, Europe/Berlin, Europe/Berlin, Europe/Bratislava, Europe/Brussels, Europe/Bucharest, Europe/Budapest, Europe/Copenhagen, Europe/Dublin, Europe/Helsinki, Europe/Istanbul, Europe/Kaliningrad, Europe/Kiev, Europe/Lisbon, Europe/Ljubljana, Europe/London, Europe/London, Europe/Madrid, Europe/Minsk, Europe/Moscow, Europe/Moscow, Europe/Paris, Europe/Prague, Europe/Riga, Europe/Rome, Europe/Samara, Europe/Sarajevo, Europe/Skopje, Europe/Sofia, Europe/Stockholm, Europe/Tallinn, Europe/Vienna, Europe/Vilnius, Europe/Volgograd, Europe/Warsaw, Europe/Zagreb, Pacific/Apia, Pacific/Auckland, Pacific/Auckland, Pacific/Chatham, Pacific/Fakaofo, Pacific/Fiji, Pacific/Guadalcanal, Pacific/Guam, Pacific/Honolulu, Pacific/Majuro, Pacific/Midway, Pacific/Midway, Pacific/Noumea, Pacific/Pago_Pago, Pacific/Port_Moresby, Pacific/Tongatapu]  
pageSizeIntegerThe maximum number of results to return per page.[optional] [default to 100]  
minSizeIntegerTrades must be larger or equal to this size.[optional]  
nextPageStringGets the next page of data from a previous API call[optional]  


Return Type

object
OptionTradesResult

Properties

NameTypeDescription
nextPageStringThe token required to request the next page of the data. If null, no further results are available.  
sourceSourceEnumThe source of the trades.  
tradesListArray of all the trades in this page of the result.  
object
OptionTrades

Properties

NameTypeDescription
contractStringThe option contract  
underlyingSymbolStringThe ticker symbol  
timestampOffsetDateTimeThe UTC timestamp at the time of the trade.  
priceBigDecimalThe price of the trade.  
sizeBigDecimalThe size of the trade.  
totalVolumeBigDecimalThe total volume of the symbol for the day up to the timestamp point in time.  
askPriceAtExecutionBigDecimalThe price of ask quote at the time of the trade.  
bidPriceAtExecutionBigDecimalThe price of bid quote at the time of the trade.  
exchangeStringThe exchange for the trade.  
conditionsStringThe condition of the trade.  
sequenceIdBigDecimalThe sequential ID for the trade, ordered as temporally received from the exchange.