Skip to content

SetCookie

Miriam McMahon edited this page Apr 27, 2023 · 6 revisions

Description

Add or update a cookie in cookie storage.

Parameters

Parameter Name Description Type Resolved Type Required
Name The name of the required cookie Value String Yes
Domain The domain of the required cookie Value String Yes
Path The path of the required cookie; defaults to / Value String No
Value The value to assign the cookie Value String Yes
Secure A boolean flag to indicate whether the cookie should be flagged secure. A cookie that is flagged secure will only be transmitted to the remote HTTP server over a secure link, using HTTPS. default= false Value Boolean No

Compatibility

This command was introduced in Safeguard 2.8

Examples

{
    "SetCookie": {
        "Name": "session_cookie",
        "Domain": "example.com",
        "Path": "/api",
        "Value": "43BE3ED9-8C6D-4388-A985-DBD35AE5DF93",
        "Secure": true
    }
}