webhook icon indicating copy to clipboard operation
webhook copied to clipboard

Implement `method` function in `WebhookMessage` class

Open MammutAlex opened this issue 1 year ago • 0 comments
trafficstars

This pull request introduces a new method function in the WebhookMessage class. This function allows setting the HTTP method for the webhook request. The HTTP method can be any valid method such as 'GET', 'POST', 'PUT', 'DELETE', etc.

The method function enhances the flexibility of the WebhookMessage class by allowing the user to specify the HTTP method used when sending the webhook request. This is particularly useful when interacting with APIs that require specific HTTP methods for certain endpoints.

Here is a brief overview of the changes:

  • Added a new method function in the WebhookMessage class.
  • The method function accepts a string parameter representing the HTTP method.
  • The HTTP method is stored in the method property of the WebhookMessage class.

This change has been fully tested to ensure it works as expected and maintains the existing functionality of the WebhookMessage class. The corresponding unit tests have also been added to verify the correct behavior of the new function.

MammutAlex avatar Jun 28 '24 11:06 MammutAlex