Scoop API

scoop:scoop.http:0.1.0

HttpCookie

class HttpCookie

source · line 45
public
public class HttpCookie internal constructor(
    /**
     * The cookie name/value pair.
     */
    public val pair: HttpCookiePair,
        /**
         * The resolved host or domain scope.
         */
        public val host: UrlHost,
        /**
         * Whether only the exact host matches, rather than its subdomains.
         */
        public val hostOnly: Boolean,
        /**
         * The cookie path bytes.
         */
        public val path: Array<Byte>,
    /**
     * The resolved absolute expiry, or None for a session cookie.
     */
    public val expiresAt: Instant?,
        /**
         * Whether transmission requires a secure scheme.
         */
        public val secure: Boolean,
        /**
         * Whether the cookie is marked inaccessible to non-HTTP scripting APIs.
         */
        public val httpOnly: Boolean,
        /**
         * The interpreted SameSite policy.
         */
        public val sameSite: HttpCookieSameSite
)

A resolved cookie with host/path scope, expiry, and flags. URL matching and SameSite decisions are separate operations.

property secure

source · line 69
public
public val secure: Boolean

get: public read-only

Whether transmission requires a secure scheme.

property host

source · line 53
public
public val host: UrlHost

get: public read-only

The resolved host or domain scope.

property expiresAt

source · line 65
public
public val expiresAt: Instant?

get: public read-only

The resolved absolute expiry, or None for a session cookie.

property hostOnly

source · line 57
public
public val hostOnly: Boolean

get: public read-only

Whether only the exact host matches, rather than its subdomains.

property httpOnly

source · line 73
public
public val httpOnly: Boolean

get: public read-only

Whether the cookie is marked inaccessible to non-HTTP scripting APIs.