# 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: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

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

The question should be specific, self-contained, and written in natural language.
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.
