> For the complete documentation index, see [llms.txt](https://doc.moost.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.moost.io/platform-manual/rules/rule-language/literals.md).

# Literals

## Value

A literal may consist of a fix value, such as a number, a text block, a boolean value, a time span or a time.

### Examples

```
1.5
"it is cold"
true
30min
now
```

## Variables

Literals starting with a `$` sign are variables. The refer the data set with the same name.

### Examples

```
$PowerConsumption
```

## Building

The building related to the event, so that building related data can be accessed via *Attribute Accessor*, see:[Attribute Accessor](/platform-manual/rules/rule-language/operations/attribute-accessor.md#accessor-on-building).

### Examples:

```java
Building::Id
Building::DeviceTypes
```

## DeliveredNotificationCounter

When the rule uses this literal then returns the number of notifications that have been delivered since the creation of the rule. It is of type [*Number*](#number).&#x20;

{% hint style="warning" %}
The DeliveredNotificationCounter does not count Test Notifications that were delivered through "Send Test Notification" Feature.
{% endhint %}

### Examples

```java
DeliveredNotificationCounter % 3
```

## DeliveredNotification

This liberal can be used only in "Goal-achieved condition". It refers to the notification which has been delivered, so that you may be able to check the time when the notification was created, or when the possible interaction happened.&#x20;

{% hint style="warning" %}
The DeliveredNotification can only be used in "Goal-achieved condition" (see [Goal-Achieved Condition](/platform-manual/rules/rule-configurator/streak-1.md)).
{% endhint %}

### Examples

```java
DeliveredNotificationCounter % 3
```

## StreakCounter

When the rule has the "Streak" feature enabled, then the literal "StreakCounter" returns the current streak of this rule. It is of type [*Number*](#number).

See [Streak](/platform-manual/rules/rule-configurator/streak.md)for more details about the *Streak* feature.

### Examples

```java
StreakCounter
```

## StreakHasBeenReset

When the rule has the "Streak" feature enabled, then the literal "StreakHasBeenReset" returns the current streak of this rule. It is of type [Data Types](/platform-manual/rules/rule-language/data-types.md#boolean)

See [Streak](/platform-manual/rules/rule-configurator/streak.md)for more details about the *Streak* feature.

### Examples

```java
StreakHasBeenReset
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://doc.moost.io/platform-manual/rules/rule-language/literals.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
