createNewInboxRulesetWithHttpInfo method
Future<Response>
createNewInboxRulesetWithHttpInfo(
- CreateInboxRulesetOptions createInboxRulesetOptions, {
- String? inboxId,
Create an inbox ruleset
Create a new inbox rule for forwarding, blocking, and allowing emails when sending and receiving
Note: This method returns the HTTP Response
.
Parameters:
-
CreateInboxRulesetOptions createInboxRulesetOptions (required):
-
String inboxId: Inbox id to attach ruleset to
Implementation
Future<Response> createNewInboxRulesetWithHttpInfo(CreateInboxRulesetOptions createInboxRulesetOptions, { String? inboxId, }) async {
// ignore: prefer_const_declarations
final path = r'/rulesets';
// ignore: prefer_final_locals
Object? postBody = createInboxRulesetOptions;
final queryParams = <QueryParam>[];
final headerParams = <String, String>{};
final formParams = <String, String>{};
if (inboxId != null) {
queryParams.addAll(_queryParams('', 'inboxId', inboxId));
}
const contentTypes = <String>['application/json'];
return apiClient.invokeAPI(
path,
'POST',
queryParams,
postBody,
headerParams,
formParams,
contentTypes.isEmpty ? null : contentTypes.first,
);
}