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

Getting all webhooks fails if any webhook is in "Error" state #75

Open
kardoaw opened this issue Mar 10, 2021 · 0 comments
Open

Getting all webhooks fails if any webhook is in "Error" state #75

kardoaw opened this issue Mar 10, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@kardoaw
Copy link

kardoaw commented Mar 10, 2021

Problem description
Trying to use IWebhooksClient.GetAll() while there is a webhook in "Error" state throws the following exception:

Newtonsoft.Json.JsonReaderException: Could not convert string to integer: Error. Path 'data[0].last_http_status', ...

Webhook's LastHttpStatus is not always an integer value, as described here: https://pipedrive.readme.io/docs/guide-for-webhooks#section-status-codes-for-webhooks.

Steps to reproduce

  1. Create an endpoint for your new webhook which takes more than ten seconds to execute.
  2. Register a new webhook in Pipedrive using your webhook address.
  3. Trigger a request to your webhook and wait for the response.
  4. Inspect that the webhook is now in "Error" state ("last_http_status":"Error").
  5. Try to use webhooks client's GetAll() to get all the webhooks.

Expected behavior
All webhooks are returned.

@DavidRouyer DavidRouyer added the bug Something isn't working label May 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants