# Workflow branch based on Webhook response

**URL:** <https://community.hubspot.com/t/workflow-branch-based-on-webhook-response/3915>\
**Category:** CMS Development\
**Created:** [November 15, 2017, 6:25pm UTC](https://community.hubspot.com/t/workflow-branch-based-on-webhook-response/3915 "2017-11-15T18:25:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![briandj](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/briandj/32/60590_2.png) [@briandj](https://community.hubspot.com/u/briandj)\
**Post date:** [November 15, 2017, 6:25pm UTC](https://community.hubspot.com/t/workflow-branch-based-on-webhook-response/3915/1 "2017-11-15T18:25:50Z")

</div>

I have a worflow that triggers a webhook. This issue is that it is basically fire and forget. However I would like to be able to branch my workflow based on the result or response of the webhook. If the webhook results with a status code of 200 I want to do one thing, but if the status code is received is 500 I would like handle it by doing something different. Alternatively if the response contains some JSON I would like to be able to parse and branch based on the result value.

Is there any way to do either of these?

Thanks

---

<div class="post-metadata">

**Author:** ![Jsum](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jsum/32/20405_2.png) [@Jsum](https://community.hubspot.com/u/Jsum)\
**Post date:** [November 16, 2017, 8:00am UTC](https://community.hubspot.com/t/workflow-branch-based-on-webhook-response/3915/2 "2017-11-16T08:00:29Z")

</div>

@briandj, use ajax and jquery. Hubspot uses sessions but I don’t really think you can tap into a session because you don’t have access to server code.
