Insites Docs Developers liquid Objects: platformOS

Objects: platformOS

Last updated on October 21, 2025

context

The object is a global object encountered and used across platformOS. Its scope is universal, making it accessible in every Liquid component, including pages, partials, and layouts, and Email, SMS, and API Call Notifications. Crucially, is the only pre-defined object available, as the platform is designed to allow you to build and define all other custom objects required by your application.

This section discusses the following topics:

  • context.authenticity_token
  • context.constants
  • context.cookies
  • context.current_user
  • context.device
  • context.environment
  • context.flash
  • context.headers
  • context.is_xhr
  • context.language
  • context.location
  • context.modules
  • context.page
  • context.params
  • context.session
  • context.useragent
  • context.visitor

context.authenticity_token

is populated by the server and automatically included in every form generated by the tag. It is used to mitigate Cross Site Request Forgery attacks, and must be added to the payload in all server requests other than .

context.constants

context.cookies

context.current_user

context.device

context.environment

context.flash

context.headers

context.is_xhr

context.language

context.location

context.modules

context.page

context.params

context.session

context.useragent

context.visitor

Exposing a local variable within the context object

Have a suggestion for this page?

Didn't quite find what you are looking for or have feedback on how we can make the content better then we would love to hear from you. Please provide us feedback and we will get back to you shortly.