updateIncomingWebhookWithHttpInfo method
Future<Response>
updateIncomingWebhookWithHttpInfo(
- String hookId,
- MmUpdateIncomingWebhookRequest mmUpdateIncomingWebhookRequest
Update an incoming webhook
Update an incoming webhook given the hook id. ##### Permissions manage_webhooks
for system or manage_webhooks
for the specific team or manage_webhooks
for the channel.
Note: This method returns the HTTP Response
.
Parameters:
-
String hookId (required): Incoming Webhook GUID
-
MmUpdateIncomingWebhookRequest mmUpdateIncomingWebhookRequest (required): Incoming webhook to be updated
Implementation
Future<Response> updateIncomingWebhookWithHttpInfo(
String hookId,
MmUpdateIncomingWebhookRequest mmUpdateIncomingWebhookRequest,
) async {
// ignore: prefer_const_declarations
final path = r'/hooks/incoming/{hook_id}'.replaceAll('{hook_id}', hookId);
// ignore: prefer_final_locals
Object? postBody = mmUpdateIncomingWebhookRequest;
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,
);
}