I tried typing document.cookie onto the console but it only displayed some of the cookies that were in use and not all of them (26 actually in use but only 7 displayed on console). I'd also like to get the cookies as an dictionary / json format if possible.
What is wrong here?
A cookie with the HttpOnly attribute is inaccessible to the JavaScript Document.cookie API; it's only sent to the server. For example, cookies that persist in server-side sessions don't need to be available to JavaScript and should have the HttpOnly attribute. This precaution helps mitigate cross-site scripting (XSS) attacks. Reference to https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies. You can get the cookies in JSON. Here are a few ways to do it: https://gist.github.com/rendro/525bbbf85e84fa9042c2