Skip to content

ElectronCookies

Unofficial

Queries and modifies a session’s cookies.

Import:

import type { ElectronCookies } from '@obsidian-typings/obsidian-public-latest';

Signature:

export interface ElectronCookies

Methods

MethodReturnsDescription
addListener(event, listener)thisRegisters a listener for the changed event, emitted when a cookie is added, edited, removed, or expired.
flushStore()Promise<void>Writes any unwritten cookies data to disk.
get(filter)Promise<ElectronCookie[]>Sends a request to get all cookies matching filter.
on('changed', listener)thisRegisters a listener for the changed event, emitted when a cookie is added, edited, removed, or expired.
once(event, listener)thisRegisters a one-time listener for the changed event.
remove(url, name)Promise<void>Removes the cookies matching url and name.
removeListener(event, listener)thisRemoves the changed event listener.
set(details)Promise<void>Sets a cookie with details.

Links to this page: