markAsReadWithHttpInfo method
Mark an email as read on unread
Marks an email as read or unread. Pass boolean read flag to set value. This is useful if you want to read an email but keep it as unread
Note: This method returns the HTTP Response
.
Parameters:
Implementation
Future<Response> markAsReadWithHttpInfo(String emailId, { bool? read, }) async {
// ignore: prefer_const_declarations
final path = r'/emails/{emailId}/read'
.replaceAll('{emailId}', emailId);
// ignore: prefer_final_locals
Object? postBody;
final queryParams = <QueryParam>[];
final headerParams = <String, String>{};
final formParams = <String, String>{};
if (read != null) {
queryParams.addAll(_queryParams('', 'read', read));
}
const contentTypes = <String>[];
return apiClient.invokeAPI(
path,
'PATCH',
queryParams,
postBody,
headerParams,
formParams,
contentTypes.isEmpty ? null : contentTypes.first,
);
}