How To Pass Cookies From Selenium WebDriver To Rest-Assured

How to pass cookies from Selenium WebDriver to Rest-Assured? When you do automated testing at API and UI layer, there could be situations where you are doing both and that you need to pass properties from your API test to you UI test or vice versa. This tutorial shows how to pass cookies from Selenium to Rest-Assured.