deleteWebhook method

Future<DeleteWebhookResult> deleteWebhook({
  1. required String webhookId,
})

Deletes a webhook.

May throw BadRequestException. May throw UnauthorizedException. May throw InternalFailureException. May throw NotFoundException. May throw LimitExceededException.

Parameter webhookId : The unique ID for a webhook.

Implementation

Future<DeleteWebhookResult> deleteWebhook({
  required String webhookId,
}) async {
  ArgumentError.checkNotNull(webhookId, 'webhookId');
  _s.validateStringLength(
    'webhookId',
    webhookId,
    0,
    255,
    isRequired: true,
  );
  final response = await _protocol.send(
    payload: null,
    method: 'DELETE',
    requestUri: '/webhooks/${Uri.encodeComponent(webhookId)}',
    exceptionFnMap: _exceptionFns,
  );
  return DeleteWebhookResult.fromJson(response);
}