Interval Stock Prices for Security

Interval Stock Prices for Security Python API Documentation

Return open, close, high, low, volume, average price, and change ratio for a particular interval for the Security with the given `identifier`

API Class:
SecurityApi
Instance Method:
get_security_interval_prices()

Stock Price Code Example

Use my API Key
from __future__ import print_function
import time
import intrinio_sdk as intrinio
from intrinio_sdk.rest import ApiException
intrinio.ApiClient().set_api_key('YOUR_API_KEY')
intrinio.ApiClient().allow_retries(True)
identifier = 'AAPL'
interval_size = '15m'
source = ''
start_date = '2023-01-01'
start_time = '33300'
end_date = '2023-02-01'
end_time = '33300'
timezone = 'UTC'
page_size = 100
split_adjusted = False
include_quote_only_bars = False
next_page = ''
response = intrinio.SecurityApi().get_security_interval_prices(identifier, interval_size, source=source, start_date=start_date, start_time=start_time,
  end_date=end_date, end_time=end_time, timezone=timezone, page_size=page_size, split_adjusted=split_adjusted, include_quote_only_bars
  =include_quote_only_bars, next_page=next_page)
print(response)
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Parameters

NameTypeDescriptionNotes
identifierstrA Security identifier (Ticker, FIGI, ISIN, CUSIP, Intrinio ID) 
interval_sizestrThe interval for which to return stock prices[default to 15m]  
sourcestrReturn intervals from the specified data source[optional]  
start_datedateReturn intervals starting at the specified date[optional]  
start_timestrReturn intervals starting at the specified time on the `start_date` (24-hour in ‘hh:mm:ss' format)[optional]  
end_datedateReturn intervals stopping at the specified date[optional]  
end_timestrReturn intervals stopping at the specified time on the `end_date` (24-hour in ‘hh:mm:ss' format)[optional]  
timezonestrInterprets the input times in this time zone, as well as returns times in this timezone.[optional] [default to UTC]  
page_sizeintThe number of results to return[optional] [default to 100]  
split_adjustedboolWhether to return the values adjusted for splits or not. Default is False.[optional] [default to False]  
include_quote_only_barsboolIf True, also include bars where no trades occurred but quotes did.[optional] [default to False]  
next_pagestrGets the next page of data from a previous API call[optional]  


Return Type

object
ApiResponseSecurityIntervalPrices

Properties

NameTypeDescription
intervalslist[StockPriceInterval]Open, close, high, low, volume, average price, and change ratio for a particular interval  
securitySecuritySummaryThe Security resolved from the given identifier  
sourcestrThe source of the data  
next_pagestrThe token required to request the next page of the data. If null, no further results are available.  
object
StockPriceInterval

Properties

NameTypeDescription
timedatetimeThe timestamp that represents the start of the interval span.  
openfloatThe first traded price during the period  
closefloatThe last traded price during the period  
highfloatThe highest price over the span of the period  
lowfloatThe lowest price over the span of the period  
volumefloatThe number of shares exchanged during the period  
close_timedatetimeThe timestamp that represents the end of the interval span.  
intervalstrThe size of the interval.  
averagefloatThe average trade price of an individual stock during the interval.  
changefloatThe change ratio from open to close. ((Close - Open)/Open).  
bid_highfloatThe highest bid price from the interval.  
bid_lowfloatThe lowest bid price from the interval.  
bid_closefloatThe last bid price from the interval.  
bid_openfloatThe first bid price from the interval.  
bid_first_timedatetimeThe timestamp that represents the first bid time from the interval span.  
bid_last_timedatetimeThe timestamp that represents the last bid time from the interval span.  
bid_change_percentfloatThe ratio of the close to open bid difference, in percent.  
ask_highfloatThe highest ask price from the interval.  
ask_lowfloatThe lowest ask price from the interval.  
ask_closefloatThe last ask price from the interval.  
ask_openfloatThe first ask price from the interval.  
ask_first_timedatetimeThe timestamp that represents the first ask time from the interval span.  
ask_last_timedatetimeThe timestamp that represents the last ask time from the interval span.  
ask_change_percentfloatThe ratio of the close to open ask difference, in percent.  
trade_countfloatThe number of qualified trades executed during the period  
object
SecuritySummary

Properties

NameTypeDescription
idstrThe Intrinio ID for Security  
company_idstrThe Intrinio ID for the Company for which the Security is issued  
exchangestrThe exchange's MIC  
exchange_micstrThe security's exchange MIC  
stock_exchange_idstrThe exchange's Intrinio ID  
namestrThe name of the Security  
codestrA 2-3 digit code classifying the Security (reference)  
currencystrThe currency in which the Security is traded on the exchange  
tickerstrThe common/local ticker of the Security  
composite_tickerstrThe country-composite ticker of the Security  
figistrThe OpenFIGI identifier  
composite_figistrThe country-composite OpenFIGI identifier  
share_class_figistrThe global-composite OpenFIGI identifier  
primary_listingboolIf True, the Security is the primary issue for the company, otherwise it is a secondary issue on a secondary stock exchange