Skip to main content

Introduction

Last updated 3/03/2026

Overview (Five Development Environment)​

The Five object is the central API and primary access point for interacting with the Five runtime. It provides a unified interface to:

  • Frontend functionality - UI interaction, validation, navigation, user messaging
  • Backend functionality - database access, transactions, SQL execution, server functions
  • Application context - current user, action, stack, parameters, environment, variables

Whether your code runs client-side or server-side, the

Five
object exposes the tools required to control behavior, manage data, and drive application logic.

Core Concept​

At its core, the

Five
object acts as a central bridge connecting the user interface, the application runtime, the database layer, the Five server environment, and any external services or integrations. It brings all of these components together through a single global object, providing a unified and consistent way for developers to access context, execute logic, manage data, and control application behavior across both the frontend and the backend.

Five Object Structure​

The

Five
object is made up of:

  • Properties - access contextual data
  • Functions - perform actions and operations

Properties​

Properties provide read access to runtime state and values.

ParameterPurposeTypical Use
field
Access field values on the current formValidation, calculations
form
Access fields from other forms in the stackCross-form logic
headers
Access HTTP headersPublic URL handling
parameters
Access URL parametersPublic URL integrations
stack
Access primary keys in the action stackNavigation logic
variable
Access global variablesPersist runtime state

JavaScript
Example
const customerName = five.field.CustomerName;
const recordKey = five.stack.Customer.CustomerKey;

Functions​

The

Five
object supports both frontend and backend development, giving you flexibility to control users experience and server-side processing within the same API. While many functions are available in both environments, they serve different purposes depending on where they are executed.

Frontend functions in Five provide the essential bridge between users and the application by managing UI messaging and feedback, controlling navigation and actions, maintaining UI state and context, and handling user interaction and input in real time.

JavaScript
Example
if (!five.field.EmailAddress) {
five.showMessage("Please enter an email address before continuing");
}

Backend functions in Five power the application behind the scenes by handling business logic, managing database operations, enforcing security and validation rules, coordinating processes and workflows, and integrating with external services to ensure reliable, scalable, and secure application behavior.

JavaScript
Example
const result = five.executeQuery("INSERT INTO Customer (Name, Email) VALUES (?, ?)", 0, five.field.Name, five.field.Email);

if (!result.ok) {
five.log(result.message);
}

Summary​

The

Five
object is designed to:

  • Provide one consistent API
  • Allow low-code and full-code flexibility
  • Give developers direct database control when required
  • Keep UI and server logic unified
  • Expose runtime context cleanly