createAssetPriceHistoryWithHttpInfo method

Future<Response> createAssetPriceHistoryWithHttpInfo(
  1. String companyId,
  2. String assetId,
  3. AssetPriceHistoryInput assetPriceHistoryInput
)

Create a new price history record for an asset

Note: This method returns the HTTP Response.

Parameters:

  • String companyId (required): Unique identifier for the Company

  • String assetId (required): Unique identifier for the Asset

  • AssetPriceHistoryInput assetPriceHistoryInput (required):

Implementation

Future<Response> createAssetPriceHistoryWithHttpInfo(String companyId, String assetId, AssetPriceHistoryInput assetPriceHistoryInput,) async {
  // ignore: prefer_const_declarations
  final path = r'/companies/{company_id}/assets/{asset_id}/prices'
    .replaceAll('{company_id}', companyId)
    .replaceAll('{asset_id}', assetId);

  // ignore: prefer_final_locals
  Object? postBody = assetPriceHistoryInput;

  final queryParams = <QueryParam>[];
  final headerParams = <String, String>{};
  final formParams = <String, String>{};

  const contentTypes = <String>['application/json'];


  return apiClient.invokeAPI(
    path,
    'POST',
    queryParams,
    postBody,
    headerParams,
    formParams,
    contentTypes.isEmpty ? null : contentTypes.first,
  );
}