A cookie is a small value the browser sends along with a request. Sites use cookies for preferences, analytics and session identifiers. cookie inspects the cookie names visible to the current PHP request; it cannot list every cookie stored in your browser, including cookies for other paths, domains or sites.
Use cookie for Browser cookies. Common operations stay short; specialized forms add detail only when needed, so repeated work remains easy to understand, repeat and place in lil-terminal scripts.
How to use this safely
Use cookie to list names without revealing values. cookie-a shows the values of cookies whose names are not recognized as sensitive; cookie theme -a checks a single preference. The command also works as coo. To inspect data stored on the server, use ses instead. An export writes selected non-sensitive cookies as JSON. Import accepts a JSON object of cookie names and scalar values, with -r allowing conflicting names to be overwritten. New cookies are sent as HTTP headers: test the result in the next browser request, not only in the current terminal output. The PHP session cookie is not exposed or deleted by this module. Sensitive-looking names are masked and cannot be imported, but this name-based filter is not a guarantee that every private value will be recognized. Exported cookies can still identify a user or reveal preferences: do not publish the JSON file.
Syntax
lil-terminal
cookie [name|export|import] [options]
Reference
cookie
list visible cookie names
cookie -a
show non-sensitive values
cookie <name> [-a]
inspect one cookie
cookie <name> -d
delete one cookie
cookie -c
clear visible cookies without closing the session
cookie export [-o <file>]
export non-sensitive cookies to JSON
cookie import <file> [-r]
import safe cookies; -r overwrites conflicts
coo
short alias for cookie
Practical use and safety
Use cookie to list names without revealing values. cookie-a shows the values of cookies whose names are not recognized as sensitive; cookie theme -a checks a single preference. The command also works as coo. To inspect data stored on the server, use ses instead.
An export writes selected non-sensitive cookies as JSON. Import accepts a JSON object of cookie names and scalar values, with -r allowing conflicting names to be overwritten. New cookies are sent as HTTP headers: test the result in the next browser request, not only in the current terminal output.
The PHP session cookie is not exposed or deleted by this module. Sensitive-looking names are masked and cannot be imported, but this name-based filter is not a guarantee that every private value will be recognized. Exported cookies can still identify a user or reveal preferences: do not publish the JSON file.
In Minimum, cookie, cookie-a and reading one name work. Deletion, clearing, export and import require Base.
Interactive sandbox preview
Run the prepared examples directly on the page. Their results are prebuilt and shown in the browser; no terminal command is executed on the server.
List visible cookie names
Install and manage
Install the current compatible version. Choose Base for the complete feature set or Minimum for the reduced package; use upgrade to update a module that is already installed.
Base and Minimum are two packages of the same current module release, not separate command versions.
Base package
Install the complete package with local command reference and every published mode.
install cookie
Minimum package
Install the reduced package. Local reference is omitted; help<cmd>-i opens the current server reference.
install cookie -m
Exact public version
Install exactly this published version.
install cookie -v 1.1.2
Check or update
Ask upgrade to check compatibility and replace the installed block only when needed.
upgrade cookie
Remove module
Remove the extension block while leaving the core and unrelated modules intact.
install cookie -u
Examples
Examples are copyable command lines, not actions executed by this website. Review paths, permissions and destructive flags before running them on a real project.
Allow optional usage analytics for pages, downloads and documentation interactions. Passwords, feedback text and terminal data are never collected by this layer. Privacy