rawFindMessagesByFromAddressWithHttpInfo method

Future<Response> rawFindMessagesByFromAddressWithHttpInfo({
  1. String? fromAddress,
  2. String? startKey,
  3. String? startDocumentId,
  4. int? limit,
  5. String? hcpId,
})

Get all messages (paginated) for current HC Party and provided from address

Note: This method returns the HTTP Response.

Parameters:

Implementation

Future<Response> rawFindMessagesByFromAddressWithHttpInfo({ String? fromAddress, String? startKey, String? startDocumentId, int? limit, String? hcpId, }) async {
  // ignore: prefer_const_declarations
  final path = r'/rest/v1/message/byFromAddress';

  // ignore: prefer_final_locals
  Object? postBody;

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

  if (fromAddress != null) {
    queryParams.addAll(_queryParams('', 'fromAddress', fromAddress));
  }
  if (startKey != null) {
    queryParams.addAll(_queryParams('', 'startKey', startKey));
  }
  if (startDocumentId != null) {
    queryParams.addAll(_queryParams('', 'startDocumentId', startDocumentId));
  }
  if (limit != null) {
    queryParams.addAll(_queryParams('', 'limit', limit));
  }
  if (hcpId != null) {
    queryParams.addAll(_queryParams('', 'hcpId', hcpId));
  }

  const authNames = <String>[r'basicSchema'];
  const contentTypes = <String>[];


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