Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webhook logging #945

Closed
FKlintebackPure opened this issue May 28, 2023 · 1 comment
Closed

Webhook logging #945

FKlintebackPure opened this issue May 28, 2023 · 1 comment
Assignees
Labels

Comments

@FKlintebackPure
Copy link

I could not get my webhooks working, and troubleshooting was tricky since Wiremock not checks for error responses.

A simple warning log would be helpful.

Alternatively, all webhook calls and responses could be logged and retrievable via the admin api.

Suggested code (in WireMockMiddleware.SendToWebHooksAsync):

var result = await webhookSender.SendAsync(httpClientForWebhook, mapping, webhookRequest, request, response).ConfigureAwait(false);
if (result.IsSuccessStatusCode) return;
_options.Logger.Warn($"Sending message to Webhook [{webHookIndex}] from Mapping '{mapping.Guid}' failed. Response: {result}");
@StefH StefH self-assigned this May 28, 2023
@StefH
Copy link
Collaborator

StefH commented May 28, 2023

@FKlintebackPure
This will be added in next release.

#946

@StefH StefH closed this as completed May 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants