createFeedPostWithHttpInfo method

Future<Response> createFeedPostWithHttpInfo(
  1. String tenantId,
  2. CreateFeedPostParams createFeedPostParams, {
  3. String? broadcastId,
  4. bool? isLive,
  5. bool? doSpamCheck,
  6. bool? skipDupCheck,
})

Performs an HTTP 'POST /api/v1/feed-posts' operation and returns the Response. Parameters:

Implementation

Future<Response> createFeedPostWithHttpInfo(String tenantId, CreateFeedPostParams createFeedPostParams, { String? broadcastId, bool? isLive, bool? doSpamCheck, bool? skipDupCheck, }) async {
  // ignore: prefer_const_declarations
  final path = r'/api/v1/feed-posts';

  // ignore: prefer_final_locals
  Object? postBody = createFeedPostParams;

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

    queryParams.addAll(_queryParams('', 'tenantId', tenantId));
  if (broadcastId != null) {
    queryParams.addAll(_queryParams('', 'broadcastId', broadcastId));
  }
  if (isLive != null) {
    queryParams.addAll(_queryParams('', 'isLive', isLive));
  }
  if (doSpamCheck != null) {
    queryParams.addAll(_queryParams('', 'doSpamCheck', doSpamCheck));
  }
  if (skipDupCheck != null) {
    queryParams.addAll(_queryParams('', 'skipDupCheck', skipDupCheck));
  }

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


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