Not able to pass Response Header (Set-Cookie value) to another request Body in order to place a reservation.

To place a reservation i need to get HoldReservation cookie from Reservedate API but when getting all cookies in Beanshell postprosessor and sending it to Beanshell preprosessor is not helping.

I have Cookie Manager at Thread level but that is not getting this cookie that is generated in the middle of the execution.

I want to get just the HoldReservation and expires from the below Cookie: Set-Cookie: HoldReservation=; expires=Thu, 15-Apr-2021 17:40:20 GMT; path=/; secure

1 Answer 1


The easiest way is just adding the next line to the user.properties file:


and on next JMeter restart you will be able to access the cookie as `${COOKIE_HoldReservation} where required. More information: HTTP Cookie Manager Advanced Usage - A Guide

If you still want to do this using regular expressions here is an example setup:

enter image description here

textual representation of the regular expression:

  • I tried both ways and one with regex is showing up in request headers(HTTP format) with HoldReservation and Expiry details but it doesn't show in cookies(Raw format) and the request still failing to get the response. Could you please tell me how to show HoldReservation in Cookies
    – Swetha C
    Apr 19, 2021 at 16:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.