Rasukarusan / shellnium

:dizzy: Selenium Webdriver for Bash (or Zsh).
https://shellnium-site.vercel.app
MIT License
173 stars 21 forks source link

How to set cookies? #14

Closed eomcb closed 2 years ago

eomcb commented 2 years ago

Hi, how can I set a cookie for a specific domain?

I'm trying to use the set_cookies() function from core.sh but I'm not sure, how the $1 has to be formatted.

Example Cookie domain: example.com name: myCookie value: 12345abcde

_BTW, I can't find the setcookies() function in the official documentation.

Thank you in advance for pointing me in the right direction, -eomcb

eomcb commented 2 years ago

Found out how to call the function with the correct parameter:

set_cookies '{"name":"myCookie", "value":"12345abcde"}'