patchChannelWithHttpInfo method
Future<Response>
patchChannelWithHttpInfo(
- String channelId,
- MmPatchChannelRequest mmPatchChannelRequest
Patch a channel
Partially update a channel by providing only the fields you want to update. Omitted fields will not be updated. The fields that can be updated are defined in the request body, all other provided fields will be ignored. ##### Permissions If updating a public channel, manage_public_channel_members
permission is required. If updating a private channel, manage_private_channel_members
permission is required.
Note: This method returns the HTTP Response
.
Parameters:
-
String channelId (required): Channel GUID
-
MmPatchChannelRequest mmPatchChannelRequest (required): Channel object to be updated
Implementation
Future<Response> patchChannelWithHttpInfo(
String channelId,
MmPatchChannelRequest mmPatchChannelRequest,
) async {
// ignore: prefer_const_declarations
final path = r'/channels/{channel_id}/patch'.replaceAll('{channel_id}', channelId);
// ignore: prefer_final_locals
Object? postBody = mmPatchChannelRequest;
final queryParams = <MmQueryParam>[];
final headerParams = <String, String>{};
final formParams = <String, String>{};
const contentTypes = <String>['application/json'];
return apiClient.invokeAPI(
path,
'PUT',
queryParams,
postBody,
headerParams,
formParams,
contentTypes.isEmpty ? null : contentTypes.first,
);
}