wiremock / wiremock/WireMock.Net

WebHook Related Issues

Open
#1,259 3 comments 0 reactions 1 assignee View on GitHub

@StefH is already working on this.

Since Mar 7, 2025.

bug
Dominant language
C#
Stars
1.7k
Forks
240
Avg merge
5d 12h
Merged PRs (30d)
2

Description

Describe the bug
Bug 1 (WebHook does not support Local Requests)

When trying to use the WebHook functionality to initiate a webhook, for online webhook URLs it works but for local ones, the receiving service receives no request.

Expected behavior:

It should work the same both for online and local webhooks.

Test to reproduce
  • 1 Clone Both Repos this and this, and build both projects.
  • 2 Go to the Online WebHook Url
  • 3 Run the Dummy Api project followed by the "WireMockBug001" project. (In case you get an error the first time you run the Demo, close it and run again.).
  • 4 Notice that the Online WebHook URL received our WebHook payload, but our Dummy service did not receive any request.
Bug 2 (WebHook does not post request body when using Body instead of BodyAsJson)

When trying to use the WebHook functionality to initiate a webhook, BodyAsJson works but Body doesn't.

Expected behavior:

It should work the same both for Body and BodyAsJson.

Test to reproduce
  • 1 Clone Both Repos this and this, and build both projects.
  • 2 Go to the Online WebHook Url
  • 3 Go to post-transaction-online.json mapping and comment BodyAsJson and uncomment Body. do same for post-transaction-local.json
  • 4 Build and run the Dummy Api project followed by the "WireMockBug001" project. (In case you get an error the first time you run the Demo, close it and run again.).
  • 5 Notice that the Online WebHook URL received our WebHook, but the payload body is null, but our Dummy service did not receive any request.
Other related info

Docker is needed to run the Demo as it uses WireMock.NET Test Container.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.