# Cookie Policy The `cookie_policy` object describes the cookie policy for the current session, including user consent and allowed cookie types. ## Usage Example ```liquid {%- comment -%} Show cookie policy status {%- endcomment -%} {% if cookie_policy.value == 'all' %}

All cookies are allowed.

{% elsif cookie_policy.value == 'required' %}

Only required cookies are allowed.

{% elsif cookie_policy.value == 'custom' %}

Custom cookie policy. Consents: {{ cookie_policy.consents | join: ', ' }}

{% else %}

Cookie policy not set. Please ask the user for consent.

{% endif %} ``` ## Properties ### consents Returns the user's consent choices for the cookie policy. If the policy is set to custom, this returns the user's consents. ### value Returns the cookie policy for the session. Possible values: - `null`: Should be asked from the user - `required`: Only required cookies allowed - `all`: All cookies are allowed - `custom`: Custom cookie policy (see `consents` for details)