reactFeedPostPublicWithHttpInfo method

Future<Response> reactFeedPostPublicWithHttpInfo(
  1. String tenantId,
  2. String postId,
  3. ReactBodyParams reactBodyParams, [
  4. ReactFeedPostPublicOptions? options,
])

Performs an HTTP 'POST /feed-posts/{tenantId}/react/{postId}' operation and returns the Response. Parameters:

Implementation

Future<Response> reactFeedPostPublicWithHttpInfo(String tenantId, String postId, ReactBodyParams reactBodyParams, [ ReactFeedPostPublicOptions? options ]) async {
  final isUndo = options?.isUndo;
  final broadcastId = options?.broadcastId;
  final sso = options?.sso;
  // ignore: prefer_const_declarations
  final path = r'/feed-posts/{tenantId}/react/{postId}'
    .replaceAll('{tenantId}', tenantId)
    .replaceAll('{postId}', postId);

  // ignore: prefer_final_locals
  Object? postBody = reactBodyParams;

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

  if (isUndo != null) {
    queryParams.addAll(_queryParams('', 'isUndo', isUndo));
  }
  if (broadcastId != null) {
    queryParams.addAll(_queryParams('', 'broadcastId', broadcastId));
  }
  if (sso != null) {
    queryParams.addAll(_queryParams('', 'sso', sso));
  }

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


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