Class StockApi

java.lang.Object
markets.alpaca.client.openapi.data.api.StockApi

public class StockApi extends Object
Generated client for StockApi operations.

This class is generated from the configured OpenAPI spec. Operation method Javadocs include OAS summaries, descriptions, parameters, return types, response details, and external documentation links when present in the spec.

Operations

  • stockAuctionSingle: Historical auctions (single)
  • stockAuctions: Historical auctions
  • stockBarSingle: Historical bars (single symbol)
  • stockBars: Historical bars
  • stockLatestBarSingle: Latest bar (single symbol)
  • stockLatestBars: Latest bars
  • stockLatestQuoteSingle: Latest quote (single symbol)
  • stockLatestQuotes: Latest quotes
  • stockLatestTradeSingle: Latest trade (single symbol)
  • stockLatestTrades: Latest trades
  • stockMetaConditions: Condition codes
  • stockMetaExchanges: Exchange codes
  • stockQuoteSingle: Historical quotes (single symbol)
  • stockQuotes: Historical quotes
  • stockSnapshotSingle: Snapshot (single symbol)
  • stockSnapshots: Snapshots
  • stockTradeSingle: Historical trades (single symbol)
  • stockTrades: Historical trades
  • Constructor Details

    • StockApi

      public StockApi()
    • StockApi

      public StockApi(ApiClient apiClient)
  • Method Details

    • getApiClient

      public ApiClient getApiClient()
    • setApiClient

      public void setApiClient(ApiClient apiClient)
    • getHostIndex

      public int getHostIndex()
    • setHostIndex

      public void setHostIndex(int hostIndex)
    • getCustomBaseUrl

      public String getCustomBaseUrl()
    • setCustomBaseUrl

      public void setCustomBaseUrl(String customBaseUrl)
    • stockAuctionSingleCall

      public okhttp3.Call stockAuctionSingleCall(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable String feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback _callback) throws ApiException
      Build call for stockAuctionSingle
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - Only `sip` is valid for auctions. (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockAuctionSingle

      public StockAuctionsRespSingle stockAuctionSingle(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable String feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical auctions (single) The historical auctions endpoint provides auction prices for the given stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - Only `sip` is valid for auctions. (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      StockAuctionsRespSingle
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockAuctionSingleWithHttpInfo

      public ApiResponse<StockAuctionsRespSingle> stockAuctionSingleWithHttpInfo(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable String feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical auctions (single) The historical auctions endpoint provides auction prices for the given stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - Only `sip` is valid for auctions. (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      ApiResponse<StockAuctionsRespSingle>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockAuctionSingleAsync

      public okhttp3.Call stockAuctionSingleAsync(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable String feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback<StockAuctionsRespSingle> _callback) throws ApiException
      Historical auctions (single) (asynchronously) The historical auctions endpoint provides auction prices for the given stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - Only `sip` is valid for auctions. (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockAuctionsCall

      public okhttp3.Call stockAuctionsCall(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable String feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback _callback) throws ApiException
      Build call for stockAuctions
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - Only `sip` is valid for auctions. (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockAuctions

      public StockAuctionsResp stockAuctions(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable String feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical auctions The historical auctions endpoint provides auction prices for a list of stock symbols between the specified dates.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - Only `sip` is valid for auctions. (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      StockAuctionsResp
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockAuctionsWithHttpInfo

      public ApiResponse<StockAuctionsResp> stockAuctionsWithHttpInfo(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable String feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical auctions The historical auctions endpoint provides auction prices for a list of stock symbols between the specified dates.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - Only `sip` is valid for auctions. (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      ApiResponse<StockAuctionsResp>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockAuctionsAsync

      public okhttp3.Call stockAuctionsAsync(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable String feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback<StockAuctionsResp> _callback) throws ApiException
      Historical auctions (asynchronously) The historical auctions endpoint provides auction prices for a list of stock symbols between the specified dates.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - Only `sip` is valid for auctions. (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockBarSingleCall

      public okhttp3.Call stockBarSingleCall(@Nonnull String symbol, @Nonnull String timeframe, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String adjustment, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback _callback) throws ApiException
      Build call for stockBarSingle
      Parameters:
      symbol - The symbol to query. (required)
      timeframe - The timeframe represented by each bar in aggregation. You can use any of the following values: - `[1-59]Min` or `[1-59]T`, e.g. `5Min` or `5T` creates 5-minute aggregations - `[1-23]Hour` or `[1-23]H`, e.g. `12Hour` or `12H` creates 12-hour aggregations - `1Day` or `1D` creates 1-day aggregations - `1Week` or `1W` creates 1-week aggregations - `[1,2,3,4,6,12]Month` or `[1,2,3,4,6,12]M`, e.g. `3Month` or `3M` creates 3-month aggregations (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      adjustment - Specifies the adjustments for the bars. - `raw`: no adjustments - `split`: adjust price and volume for forward and reverse stock splits - `dividend`: adjust price for cash dividends - `spin-off`: adjust price for spin-offs - `all`: apply all above adjustments You can combine multiple adjustments by separating them with a comma, e.g. `split,spin-off`. (optional, default to raw)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockBarSingle

      public StockBarsRespSingle stockBarSingle(@Nonnull String symbol, @Nonnull String timeframe, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String adjustment, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical bars (single symbol) The historical stock bars API provides aggregates for the stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      timeframe - The timeframe represented by each bar in aggregation. You can use any of the following values: - `[1-59]Min` or `[1-59]T`, e.g. `5Min` or `5T` creates 5-minute aggregations - `[1-23]Hour` or `[1-23]H`, e.g. `12Hour` or `12H` creates 12-hour aggregations - `1Day` or `1D` creates 1-day aggregations - `1Week` or `1W` creates 1-week aggregations - `[1,2,3,4,6,12]Month` or `[1,2,3,4,6,12]M`, e.g. `3Month` or `3M` creates 3-month aggregations (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      adjustment - Specifies the adjustments for the bars. - `raw`: no adjustments - `split`: adjust price and volume for forward and reverse stock splits - `dividend`: adjust price for cash dividends - `spin-off`: adjust price for spin-offs - `all`: apply all above adjustments You can combine multiple adjustments by separating them with a comma, e.g. `split,spin-off`. (optional, default to raw)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      StockBarsRespSingle
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockBarSingleWithHttpInfo

      public ApiResponse<StockBarsRespSingle> stockBarSingleWithHttpInfo(@Nonnull String symbol, @Nonnull String timeframe, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String adjustment, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical bars (single symbol) The historical stock bars API provides aggregates for the stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      timeframe - The timeframe represented by each bar in aggregation. You can use any of the following values: - `[1-59]Min` or `[1-59]T`, e.g. `5Min` or `5T` creates 5-minute aggregations - `[1-23]Hour` or `[1-23]H`, e.g. `12Hour` or `12H` creates 12-hour aggregations - `1Day` or `1D` creates 1-day aggregations - `1Week` or `1W` creates 1-week aggregations - `[1,2,3,4,6,12]Month` or `[1,2,3,4,6,12]M`, e.g. `3Month` or `3M` creates 3-month aggregations (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      adjustment - Specifies the adjustments for the bars. - `raw`: no adjustments - `split`: adjust price and volume for forward and reverse stock splits - `dividend`: adjust price for cash dividends - `spin-off`: adjust price for spin-offs - `all`: apply all above adjustments You can combine multiple adjustments by separating them with a comma, e.g. `split,spin-off`. (optional, default to raw)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      ApiResponse<StockBarsRespSingle>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockBarSingleAsync

      public okhttp3.Call stockBarSingleAsync(@Nonnull String symbol, @Nonnull String timeframe, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String adjustment, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback<StockBarsRespSingle> _callback) throws ApiException
      Historical bars (single symbol) (asynchronously) The historical stock bars API provides aggregates for the stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      timeframe - The timeframe represented by each bar in aggregation. You can use any of the following values: - `[1-59]Min` or `[1-59]T`, e.g. `5Min` or `5T` creates 5-minute aggregations - `[1-23]Hour` or `[1-23]H`, e.g. `12Hour` or `12H` creates 12-hour aggregations - `1Day` or `1D` creates 1-day aggregations - `1Week` or `1W` creates 1-week aggregations - `[1,2,3,4,6,12]Month` or `[1,2,3,4,6,12]M`, e.g. `3Month` or `3M` creates 3-month aggregations (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      adjustment - Specifies the adjustments for the bars. - `raw`: no adjustments - `split`: adjust price and volume for forward and reverse stock splits - `dividend`: adjust price for cash dividends - `spin-off`: adjust price for spin-offs - `all`: apply all above adjustments You can combine multiple adjustments by separating them with a comma, e.g. `split,spin-off`. (optional, default to raw)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockBarsCall

      public okhttp3.Call stockBarsCall(@Nonnull String symbols, @Nonnull String timeframe, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String adjustment, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback _callback) throws ApiException
      Build call for stockBars
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      timeframe - The timeframe represented by each bar in aggregation. You can use any of the following values: - `[1-59]Min` or `[1-59]T`, e.g. `5Min` or `5T` creates 5-minute aggregations - `[1-23]Hour` or `[1-23]H`, e.g. `12Hour` or `12H` creates 12-hour aggregations - `1Day` or `1D` creates 1-day aggregations - `1Week` or `1W` creates 1-week aggregations - `[1,2,3,4,6,12]Month` or `[1,2,3,4,6,12]M`, e.g. `3Month` or `3M` creates 3-month aggregations (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      adjustment - Specifies the adjustments for the bars. - `raw`: no adjustments - `split`: adjust price and volume for forward and reverse stock splits - `dividend`: adjust price for cash dividends - `spin-off`: adjust price for spin-offs - `all`: apply all above adjustments You can combine multiple adjustments by separating them with a comma, e.g. `split,spin-off`. (optional, default to raw)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockBars

      public StockBarsResp stockBars(@Nonnull String symbols, @Nonnull String timeframe, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String adjustment, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical bars The historical stock bars API provides aggregates for a list of stock symbols between the specified dates. The returned results are sorted by symbol first, then by bar timestamp. This means that you are likely to see only one symbol in your first response if there are enough bars for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any bars were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      timeframe - The timeframe represented by each bar in aggregation. You can use any of the following values: - `[1-59]Min` or `[1-59]T`, e.g. `5Min` or `5T` creates 5-minute aggregations - `[1-23]Hour` or `[1-23]H`, e.g. `12Hour` or `12H` creates 12-hour aggregations - `1Day` or `1D` creates 1-day aggregations - `1Week` or `1W` creates 1-week aggregations - `[1,2,3,4,6,12]Month` or `[1,2,3,4,6,12]M`, e.g. `3Month` or `3M` creates 3-month aggregations (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      adjustment - Specifies the adjustments for the bars. - `raw`: no adjustments - `split`: adjust price and volume for forward and reverse stock splits - `dividend`: adjust price for cash dividends - `spin-off`: adjust price for spin-offs - `all`: apply all above adjustments You can combine multiple adjustments by separating them with a comma, e.g. `split,spin-off`. (optional, default to raw)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      StockBarsResp
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockBarsWithHttpInfo

      public ApiResponse<StockBarsResp> stockBarsWithHttpInfo(@Nonnull String symbols, @Nonnull String timeframe, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String adjustment, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical bars The historical stock bars API provides aggregates for a list of stock symbols between the specified dates. The returned results are sorted by symbol first, then by bar timestamp. This means that you are likely to see only one symbol in your first response if there are enough bars for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any bars were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      timeframe - The timeframe represented by each bar in aggregation. You can use any of the following values: - `[1-59]Min` or `[1-59]T`, e.g. `5Min` or `5T` creates 5-minute aggregations - `[1-23]Hour` or `[1-23]H`, e.g. `12Hour` or `12H` creates 12-hour aggregations - `1Day` or `1D` creates 1-day aggregations - `1Week` or `1W` creates 1-week aggregations - `[1,2,3,4,6,12]Month` or `[1,2,3,4,6,12]M`, e.g. `3Month` or `3M` creates 3-month aggregations (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      adjustment - Specifies the adjustments for the bars. - `raw`: no adjustments - `split`: adjust price and volume for forward and reverse stock splits - `dividend`: adjust price for cash dividends - `spin-off`: adjust price for spin-offs - `all`: apply all above adjustments You can combine multiple adjustments by separating them with a comma, e.g. `split,spin-off`. (optional, default to raw)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      ApiResponse<StockBarsResp>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockBarsAsync

      public okhttp3.Call stockBarsAsync(@Nonnull String symbols, @Nonnull String timeframe, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String adjustment, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback<StockBarsResp> _callback) throws ApiException
      Historical bars (asynchronously) The historical stock bars API provides aggregates for a list of stock symbols between the specified dates. The returned results are sorted by symbol first, then by bar timestamp. This means that you are likely to see only one symbol in your first response if there are enough bars for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any bars were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      timeframe - The timeframe represented by each bar in aggregation. You can use any of the following values: - `[1-59]Min` or `[1-59]T`, e.g. `5Min` or `5T` creates 5-minute aggregations - `[1-23]Hour` or `[1-23]H`, e.g. `12Hour` or `12H` creates 12-hour aggregations - `1Day` or `1D` creates 1-day aggregations - `1Week` or `1W` creates 1-week aggregations - `[1,2,3,4,6,12]Month` or `[1,2,3,4,6,12]M`, e.g. `3Month` or `3M` creates 3-month aggregations (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      adjustment - Specifies the adjustments for the bars. - `raw`: no adjustments - `split`: adjust price and volume for forward and reverse stock splits - `dividend`: adjust price for cash dividends - `spin-off`: adjust price for spin-offs - `all`: apply all above adjustments You can combine multiple adjustments by separating them with a comma, e.g. `split,spin-off`. (optional, default to raw)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestBarSingleCall

      public okhttp3.Call stockLatestBarSingleCall(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback _callback) throws ApiException
      Build call for stockLatestBarSingle
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestBarSingle

      public StockLatestBarsRespSingle stockLatestBarSingle(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest bar (single symbol) The latest bar endpoint returns the latest minute bar for the given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      StockLatestBarsRespSingle
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestBarSingleWithHttpInfo

      public ApiResponse<StockLatestBarsRespSingle> stockLatestBarSingleWithHttpInfo(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest bar (single symbol) The latest bar endpoint returns the latest minute bar for the given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      ApiResponse<StockLatestBarsRespSingle>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestBarSingleAsync

      public okhttp3.Call stockLatestBarSingleAsync(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback<StockLatestBarsRespSingle> _callback) throws ApiException
      Latest bar (single symbol) (asynchronously) The latest bar endpoint returns the latest minute bar for the given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestBarsCall

      public okhttp3.Call stockLatestBarsCall(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback _callback) throws ApiException
      Build call for stockLatestBars
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestBars

      public StockLatestBarsResp stockLatestBars(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest bars The latest bars endpoint provides the latest minute bar for the given ticker symbols.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      StockLatestBarsResp
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestBarsWithHttpInfo

      public ApiResponse<StockLatestBarsResp> stockLatestBarsWithHttpInfo(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest bars The latest bars endpoint provides the latest minute bar for the given ticker symbols.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      ApiResponse<StockLatestBarsResp>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestBarsAsync

      public okhttp3.Call stockLatestBarsAsync(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback<StockLatestBarsResp> _callback) throws ApiException
      Latest bars (asynchronously) The latest bars endpoint provides the latest minute bar for the given ticker symbols.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestQuoteSingleCall

      public okhttp3.Call stockLatestQuoteSingleCall(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback _callback) throws ApiException
      Build call for stockLatestQuoteSingle
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestQuoteSingle

      public StockLatestQuotesRespSingle stockLatestQuoteSingle(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest quote (single symbol) The latest quote endpoint provides the latest best bid and ask prices for a given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      StockLatestQuotesRespSingle
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestQuoteSingleWithHttpInfo

      public ApiResponse<StockLatestQuotesRespSingle> stockLatestQuoteSingleWithHttpInfo(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest quote (single symbol) The latest quote endpoint provides the latest best bid and ask prices for a given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      ApiResponse<StockLatestQuotesRespSingle>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestQuoteSingleAsync

      public okhttp3.Call stockLatestQuoteSingleAsync(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback<StockLatestQuotesRespSingle> _callback) throws ApiException
      Latest quote (single symbol) (asynchronously) The latest quote endpoint provides the latest best bid and ask prices for a given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestQuotesCall

      public okhttp3.Call stockLatestQuotesCall(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback _callback) throws ApiException
      Build call for stockLatestQuotes
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestQuotes

      public StockLatestQuotesResp stockLatestQuotes(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest quotes The latest quotes endpoint provides the latest best bid and ask prices for the given ticker symbols.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      StockLatestQuotesResp
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestQuotesWithHttpInfo

      public ApiResponse<StockLatestQuotesResp> stockLatestQuotesWithHttpInfo(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest quotes The latest quotes endpoint provides the latest best bid and ask prices for the given ticker symbols.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      ApiResponse<StockLatestQuotesResp>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestQuotesAsync

      public okhttp3.Call stockLatestQuotesAsync(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback<StockLatestQuotesResp> _callback) throws ApiException
      Latest quotes (asynchronously) The latest quotes endpoint provides the latest best bid and ask prices for the given ticker symbols.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestTradeSingleCall

      public okhttp3.Call stockLatestTradeSingleCall(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback _callback) throws ApiException
      Build call for stockLatestTradeSingle
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestTradeSingle

      public StockLatestTradesRespSingle stockLatestTradeSingle(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest trade (single symbol) The latest trade endpoint provides the latest trade for the given ticker symbol. Trades with any conditions that causes them to not update the bar price are excluded. For example a trade with condition `I` (odd lot) will never appear on this endpoint. You can find the complete list of excluded conditions in [this FAQ](https://docs.alpaca.markets/docs/market-data-faq#how-are-bars-aggregated).
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      StockLatestTradesRespSingle
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestTradeSingleWithHttpInfo

      public ApiResponse<StockLatestTradesRespSingle> stockLatestTradeSingleWithHttpInfo(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest trade (single symbol) The latest trade endpoint provides the latest trade for the given ticker symbol. Trades with any conditions that causes them to not update the bar price are excluded. For example a trade with condition `I` (odd lot) will never appear on this endpoint. You can find the complete list of excluded conditions in [this FAQ](https://docs.alpaca.markets/docs/market-data-faq#how-are-bars-aggregated).
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      ApiResponse<StockLatestTradesRespSingle>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestTradeSingleAsync

      public okhttp3.Call stockLatestTradeSingleAsync(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback<StockLatestTradesRespSingle> _callback) throws ApiException
      Latest trade (single symbol) (asynchronously) The latest trade endpoint provides the latest trade for the given ticker symbol. Trades with any conditions that causes them to not update the bar price are excluded. For example a trade with condition `I` (odd lot) will never appear on this endpoint. You can find the complete list of excluded conditions in [this FAQ](https://docs.alpaca.markets/docs/market-data-faq#how-are-bars-aggregated).
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestTradesCall

      public okhttp3.Call stockLatestTradesCall(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback _callback) throws ApiException
      Build call for stockLatestTrades
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestTrades

      public StockLatestTradesResp stockLatestTrades(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest trades The latest trades endpoint provides the latest trades for the given ticker symbols. Trades with any conditions that causes them to not update the bar price are excluded. For example a trade with condition `I` (odd lot) will never appear on this endpoint. You can find the complete list of excluded conditions in [this FAQ](https://docs.alpaca.markets/docs/market-data-faq#how-are-bars-aggregated).
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      StockLatestTradesResp
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestTradesWithHttpInfo

      public ApiResponse<StockLatestTradesResp> stockLatestTradesWithHttpInfo(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Latest trades The latest trades endpoint provides the latest trades for the given ticker symbols. Trades with any conditions that causes them to not update the bar price are excluded. For example a trade with condition `I` (odd lot) will never appear on this endpoint. You can find the complete list of excluded conditions in [this FAQ](https://docs.alpaca.markets/docs/market-data-faq#how-are-bars-aggregated).
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      ApiResponse<StockLatestTradesResp>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockLatestTradesAsync

      public okhttp3.Call stockLatestTradesAsync(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback<StockLatestTradesResp> _callback) throws ApiException
      Latest trades (asynchronously) The latest trades endpoint provides the latest trades for the given ticker symbols. Trades with any conditions that causes them to not update the bar price are excluded. For example a trade with condition `I` (odd lot) will never appear on this endpoint. You can find the complete list of excluded conditions in [this FAQ](https://docs.alpaca.markets/docs/market-data-faq#how-are-bars-aggregated).
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockMetaConditionsCall

      public okhttp3.Call stockMetaConditionsCall(@Nonnull String ticktype, @Nonnull String tape, ApiCallback _callback) throws ApiException
      Build call for stockMetaConditions
      Parameters:
      ticktype - The type of ticks. (required)
      tape - The one character name of the tape. (required)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockMetaConditions

      public Map<String,String> stockMetaConditions(@Nonnull String ticktype, @Nonnull String tape) throws ApiException
      Condition codes Returns the mapping between the condition codes and names.
      Parameters:
      ticktype - The type of ticks. (required)
      tape - The one character name of the tape. (required)
      Returns:
      Map<String, String>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockMetaConditionsWithHttpInfo

      public ApiResponse<Map<String,String>> stockMetaConditionsWithHttpInfo(@Nonnull String ticktype, @Nonnull String tape) throws ApiException
      Condition codes Returns the mapping between the condition codes and names.
      Parameters:
      ticktype - The type of ticks. (required)
      tape - The one character name of the tape. (required)
      Returns:
      ApiResponse<Map<String, String>>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockMetaConditionsAsync

      public okhttp3.Call stockMetaConditionsAsync(@Nonnull String ticktype, @Nonnull String tape, ApiCallback<Map<String,String>> _callback) throws ApiException
      Condition codes (asynchronously) Returns the mapping between the condition codes and names.
      Parameters:
      ticktype - The type of ticks. (required)
      tape - The one character name of the tape. (required)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockMetaExchangesCall

      public okhttp3.Call stockMetaExchangesCall(ApiCallback _callback) throws ApiException
      Build call for stockMetaExchanges
      Parameters:
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockMetaExchanges

      public Map<String,String> stockMetaExchanges() throws ApiException
      Exchange codes Returns the mapping between the stock exchange codes and the corresponding exchange names.
      Returns:
      Map<String, String>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockMetaExchangesWithHttpInfo

      public ApiResponse<Map<String,String>> stockMetaExchangesWithHttpInfo() throws ApiException
      Exchange codes Returns the mapping between the stock exchange codes and the corresponding exchange names.
      Returns:
      ApiResponse<Map<String, String>>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockMetaExchangesAsync

      public okhttp3.Call stockMetaExchangesAsync(ApiCallback<Map<String,String>> _callback) throws ApiException
      Exchange codes (asynchronously) Returns the mapping between the stock exchange codes and the corresponding exchange names.
      Parameters:
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockQuoteSingleCall

      public okhttp3.Call stockQuoteSingleCall(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback _callback) throws ApiException
      Build call for stockQuoteSingle
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockQuoteSingle

      public StockQuotesRespSingle stockQuoteSingle(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical quotes (single symbol) The historical stock quotes API provides quote data for a stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      StockQuotesRespSingle
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockQuoteSingleWithHttpInfo

      public ApiResponse<StockQuotesRespSingle> stockQuoteSingleWithHttpInfo(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical quotes (single symbol) The historical stock quotes API provides quote data for a stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      ApiResponse<StockQuotesRespSingle>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockQuoteSingleAsync

      public okhttp3.Call stockQuoteSingleAsync(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback<StockQuotesRespSingle> _callback) throws ApiException
      Historical quotes (single symbol) (asynchronously) The historical stock quotes API provides quote data for a stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockQuotesCall

      public okhttp3.Call stockQuotesCall(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback _callback) throws ApiException
      Build call for stockQuotes
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockQuotes

      public StockQuotesResp stockQuotes(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical quotes The historical stock quotes API provides quote data for a list of stock symbols between the specified dates. The returned results are sorted by symbol first, then by the quote timestamp. This means that you are likely to see only one symbol in your first response if there are enough quotes for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any quotes were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      StockQuotesResp
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockQuotesWithHttpInfo

      public ApiResponse<StockQuotesResp> stockQuotesWithHttpInfo(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical quotes The historical stock quotes API provides quote data for a list of stock symbols between the specified dates. The returned results are sorted by symbol first, then by the quote timestamp. This means that you are likely to see only one symbol in your first response if there are enough quotes for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any quotes were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      ApiResponse<StockQuotesResp>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockQuotesAsync

      public okhttp3.Call stockQuotesAsync(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback<StockQuotesResp> _callback) throws ApiException
      Historical quotes (asynchronously) The historical stock quotes API provides quote data for a list of stock symbols between the specified dates. The returned results are sorted by symbol first, then by the quote timestamp. This means that you are likely to see only one symbol in your first response if there are enough quotes for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any quotes were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockSnapshotSingleCall

      public okhttp3.Call stockSnapshotSingleCall(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback _callback) throws ApiException
      Build call for stockSnapshotSingle
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockSnapshotSingle

      public StockSnapshotsRespSingle stockSnapshotSingle(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Snapshot (single symbol) The snapshot endpoint provides the latest trade, latest quote, minute bar, daily bar, and previous daily bar data for a given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      StockSnapshotsRespSingle
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockSnapshotSingleWithHttpInfo

      public ApiResponse<StockSnapshotsRespSingle> stockSnapshotSingleWithHttpInfo(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Snapshot (single symbol) The snapshot endpoint provides the latest trade, latest quote, minute bar, daily bar, and previous daily bar data for a given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      ApiResponse<StockSnapshotsRespSingle>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockSnapshotSingleAsync

      public okhttp3.Call stockSnapshotSingleAsync(@Nonnull String symbol, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback<StockSnapshotsRespSingle> _callback) throws ApiException
      Snapshot (single symbol) (asynchronously) The snapshot endpoint provides the latest trade, latest quote, minute bar, daily bar, and previous daily bar data for a given ticker symbol.
      Parameters:
      symbol - The symbol to query. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockSnapshotsCall

      public okhttp3.Call stockSnapshotsCall(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback _callback) throws ApiException
      Build call for stockSnapshots
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockSnapshots

      public Map<String,StockSnapshot> stockSnapshots(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Snapshots The snapshot endpoint for multiple tickers provides the latest trade, latest quote, minute bar, daily bar, and previous daily bar data for each given ticker symbol.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      Map<String, StockSnapshot>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockSnapshotsWithHttpInfo

      public ApiResponse<Map<String,StockSnapshot>> stockSnapshotsWithHttpInfo(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency) throws ApiException
      Snapshots The snapshot endpoint for multiple tickers provides the latest trade, latest quote, minute bar, daily bar, and previous daily bar data for each given ticker symbol.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      Returns:
      ApiResponse<Map<String, StockSnapshot>>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockSnapshotsAsync

      public okhttp3.Call stockSnapshotsAsync(@Nonnull String symbols, @Nullable StockLatestFeed feed, @Nullable String currency, ApiCallback<Map<String,StockSnapshot>> _callback) throws ApiException
      Snapshots (asynchronously) The snapshot endpoint for multiple tickers provides the latest trade, latest quote, minute bar, daily bar, and previous daily bar data for each given ticker symbol.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `delayed_sip`: SIP with a 15 minute delay - `boats`: Blue Ocean, overnight US trading data - `overnight`: derived overnight US trading data - `otc`: over-the-counter exchanges Default: `sip` if the user has the unlimited subscription, otherwise `iex`. (optional)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockTradeSingleCall

      public okhttp3.Call stockTradeSingleCall(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback _callback) throws ApiException
      Build call for stockTradeSingle
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockTradeSingle

      public StockTradesRespSingle stockTradeSingle(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical trades (single symbol) The historical stock trades API provides trade data for a stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      StockTradesRespSingle
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockTradeSingleWithHttpInfo

      public ApiResponse<StockTradesRespSingle> stockTradeSingleWithHttpInfo(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical trades (single symbol) The historical stock trades API provides trade data for a stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      ApiResponse<StockTradesRespSingle>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockTradeSingleAsync

      public okhttp3.Call stockTradeSingleAsync(@Nonnull String symbol, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback<StockTradesRespSingle> _callback) throws ApiException
      Historical trades (single symbol) (asynchronously) The historical stock trades API provides trade data for a stock symbol between the specified dates.
      Parameters:
      symbol - The symbol to query. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockTradesCall

      public okhttp3.Call stockTradesCall(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback _callback) throws ApiException
      Build call for stockTrades
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockTrades

      public StockTradesResp stockTrades(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical trades The historical stock trades API provides trade data for a list of stock symbols between the specified dates. The returned results are sorted by symbol first then by trade timestamp. This means that you are likely to see only one symbol in your first response if there are enough trades for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any trades were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      StockTradesResp
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockTradesWithHttpInfo

      public ApiResponse<StockTradesResp> stockTradesWithHttpInfo(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort) throws ApiException
      Historical trades The historical stock trades API provides trade data for a list of stock symbols between the specified dates. The returned results are sorted by symbol first then by trade timestamp. This means that you are likely to see only one symbol in your first response if there are enough trades for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any trades were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      Returns:
      ApiResponse<StockTradesResp>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -
    • stockTradesAsync

      public okhttp3.Call stockTradesAsync(@Nonnull String symbols, @Nullable OffsetDateTime start, @Nullable OffsetDateTime end, @Nullable Integer limit, @Nullable String asof, @Nullable StockHistoricalFeed feed, @Nullable String currency, @Nullable String pageToken, @Nullable Sort sort, ApiCallback<StockTradesResp> _callback) throws ApiException
      Historical trades (asynchronously) The historical stock trades API provides trade data for a list of stock symbols between the specified dates. The returned results are sorted by symbol first then by trade timestamp. This means that you are likely to see only one symbol in your first response if there are enough trades for that symbol to hit the limit you requested. In these situations, if you keep requesting again with the `next_page_token` from the previous response, you will eventually reach the other symbols if any trades were found for them.
      Parameters:
      symbols - A comma-separated list of stock symbols. (required)
      start - The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed. (optional)
      end - The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time. (optional)
      limit - The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the `next_page_token` for more pages. The limit applies to the total number of data points, not per symbol! (optional, default to 1000)
      asof - The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day. This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change. The special value of \"-\" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given `asof` date. Example: FB was renamed to META in 2022-06-09. Querying META with an `asof` date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an `asof` date after 2022-06-09 will only return data with the FB ticker, not with META. But with an `asof` date before 2022-06-09, META will also be returned (as FB). (optional)
      feed - The source feed of the data. - `sip`: all US exchanges - `iex`: Investors EXchange - `boats`: Blue Ocean ATS, overnight US trading data - `otc`: over-the-counter exchanges (optional, default to sip)
      currency - The currency of all prices in ISO 4217 format. Default: USD. (optional)
      pageToken - The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit. (optional)
      sort - Sort data in ascending or descending order. (optional, default to asc)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      HTTP Response Details:
      Response Details
      Status Code Description Response Headers
      200 OK * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      400 One of the request parameters is invalid. See the returned message for details. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      401 Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key. -
      403 The requested resource is forbidden. -
      429 Too many requests. You hit the rate limit. Use the X-RateLimit-... response headers to make sure you're under the rate limit. * X-RateLimit-Limit -
      * X-RateLimit-Remaining -
      * X-RateLimit-Reset -
      500 Internal server error. We recommend retrying these later. If the issue persists, please contact us on [Slack](https://alpaca.markets/slack) or on the [Community Forum](https://forum.alpaca.markets/). -