Class CorporateActionsApi
java.lang.Object
net.jacobpeterson.alpaca.openapi.marketdata.api.CorporateActionsApi
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncorporateActions
(String symbols, String types, LocalDate start, LocalDate end, Long limit, String pageToken, Sort sort) Corporate actions This endpoint provides data about the corporate actions for each given symbol over a specified time period.protected okhttp3.Call
corporateActionsAsync
(String symbols, String types, LocalDate start, LocalDate end, Long limit, String pageToken, Sort sort, ApiCallback<CACorporateActionsResp> _callback) Corporate actions (asynchronously) This endpoint provides data about the corporate actions for each given symbol over a specified time period.protected okhttp3.Call
corporateActionsCall
(String symbols, String types, LocalDate start, LocalDate end, Long limit, String pageToken, Sort sort, ApiCallback _callback) Build call for corporateActionsprotected ApiResponse
<CACorporateActionsResp> corporateActionsWithHttpInfo
(String symbols, String types, LocalDate start, LocalDate end, Long limit, String pageToken, Sort sort) Corporate actions This endpoint provides data about the corporate actions for each given symbol over a specified time period.
-
Constructor Details
-
CorporateActionsApi
public CorporateActionsApi() -
CorporateActionsApi
-
-
Method Details
-
corporateActionsCall
protected okhttp3.Call corporateActionsCall(String symbols, String types, LocalDate start, LocalDate end, Long limit, String pageToken, Sort sort, ApiCallback _callback) throws ApiException Build call for corporateActions- Parameters:
symbols
- Comma separated list of symbols. (optional)types
- Comma separated list of types. If not provided, all The following types are supported: - reverse_split - forward_split - unit_split - cash_dividend - stock_dividend - spin_off - cash_merger - stock_merger - stock_and_cash_merger - redemption - name_change - worthless_removal (optional)start
- The inclusive start of the interval. Format: YYYY-MM-DD. If missing, the default value is the current day. (optional)end
- The inclusive end of the interval. Format: YYYY-MM-DD. If missing, the default value is the current day. (optional)limit
- The maximum number of data points to return in the response. 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)pageToken
- Pagination token to continue from. The value to pass here is returned in specific requests when more data is available than the request limit allows. (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
-
corporateActions
public CACorporateActionsResp corporateActions(String symbols, String types, LocalDate start, LocalDate end, Long limit, String pageToken, Sort sort) throws ApiException Corporate actions This endpoint provides data about the corporate actions for each given symbol over a specified time period.- Parameters:
symbols
- Comma separated list of symbols. (optional)types
- Comma separated list of types. If not provided, all The following types are supported: - reverse_split - forward_split - unit_split - cash_dividend - stock_dividend - spin_off - cash_merger - stock_merger - stock_and_cash_merger - redemption - name_change - worthless_removal (optional)start
- The inclusive start of the interval. Format: YYYY-MM-DD. If missing, the default value is the current day. (optional)end
- The inclusive end of the interval. Format: YYYY-MM-DD. If missing, the default value is the current day. (optional)limit
- The maximum number of data points to return in the response. 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)pageToken
- Pagination token to continue from. The value to pass here is returned in specific requests when more data is available than the request limit allows. (optional)sort
- Sort data in ascending or descending order. (optional, default to asc)- Returns:
- CACorporateActionsResp
- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body
-
corporateActionsWithHttpInfo
protected ApiResponse<CACorporateActionsResp> corporateActionsWithHttpInfo(String symbols, String types, LocalDate start, LocalDate end, Long limit, String pageToken, Sort sort) throws ApiException Corporate actions This endpoint provides data about the corporate actions for each given symbol over a specified time period.- Parameters:
symbols
- Comma separated list of symbols. (optional)types
- Comma separated list of types. If not provided, all The following types are supported: - reverse_split - forward_split - unit_split - cash_dividend - stock_dividend - spin_off - cash_merger - stock_merger - stock_and_cash_merger - redemption - name_change - worthless_removal (optional)start
- The inclusive start of the interval. Format: YYYY-MM-DD. If missing, the default value is the current day. (optional)end
- The inclusive end of the interval. Format: YYYY-MM-DD. If missing, the default value is the current day. (optional)limit
- The maximum number of data points to return in the response. 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)pageToken
- Pagination token to continue from. The value to pass here is returned in specific requests when more data is available than the request limit allows. (optional)sort
- Sort data in ascending or descending order. (optional, default to asc)- Returns:
- ApiResponse<CACorporateActionsResp>
- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body
-
corporateActionsAsync
protected okhttp3.Call corporateActionsAsync(String symbols, String types, LocalDate start, LocalDate end, Long limit, String pageToken, Sort sort, ApiCallback<CACorporateActionsResp> _callback) throws ApiException Corporate actions (asynchronously) This endpoint provides data about the corporate actions for each given symbol over a specified time period.- Parameters:
symbols
- Comma separated list of symbols. (optional)types
- Comma separated list of types. If not provided, all The following types are supported: - reverse_split - forward_split - unit_split - cash_dividend - stock_dividend - spin_off - cash_merger - stock_merger - stock_and_cash_merger - redemption - name_change - worthless_removal (optional)start
- The inclusive start of the interval. Format: YYYY-MM-DD. If missing, the default value is the current day. (optional)end
- The inclusive end of the interval. Format: YYYY-MM-DD. If missing, the default value is the current day. (optional)limit
- The maximum number of data points to return in the response. 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)pageToken
- Pagination token to continue from. The value to pass here is returned in specific requests when more data is available than the request limit allows. (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
-