> For the complete documentation index, see [llms.txt](https://docs.appmixer.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.appmixer.com/connector-configuration/utils/filters/modulo.md).

# Modulo

### Overview

The **Modulo Filter Component** checks whether the remainder of a division operation between two numbers is zero. If the remainder is zero, the message is passed through the `modulo` port.

### Usage

This component is used to validate if a number is evenly divisible by another number, making it useful for workflows requiring modular arithmetic checks.

#### Properties

| Property     | Type     | Description                                                                   |
| ------------ | -------- | ----------------------------------------------------------------------------- |
| `sourceData` | `number` | The dividend (number to be divided).                                          |
| `value`      | `number` | The divisor. The component checks if `sourceData` is divisible by this value. |

#### Input Ports

| Port | Description                                                |
| ---- | ---------------------------------------------------------- |
| `in` | Accepts the dividend (`sourceData`) and divisor (`value`). |

#### Output Ports

| Port     | Description                                    |
| -------- | ---------------------------------------------- |
| `modulo` | Emits the remainder of the division operation. |

#### Processing Logic

1. **Receives Input Data**:
   * Accepts `sourceData` (dividend) and `value` (divisor).
2. **Performs Modulo Operation**:
   * Computes `sourceData % value` to find the remainder.
3. **Routes the Message**:
   * Outputs the remainder to the `modulo` port.

#### Output Data Schema

| Property     | Type     | Description                                |
| ------------ | -------- | ------------------------------------------ |
| `sourceData` | `number` | The dividend used in the modulo operation. |
| `value`      | `number` | The divisor used in the modulo operation.  |
| `result`     | `number` | The remainder of `sourceData % value`.     |

### Notes

* **Works with Numeric Inputs**: Only accepts numbers as input values.
* **Used for Modular Checks**: Determines whether a number is evenly divisible by another.
* **Ideal for Conditional Filtering**: Useful in workflows requiring periodic checks (e.g., every Nth event).

This component is essential for workflows that need to determine divisibility or process data based on modular arithmetic conditions.


---

# 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 dynamically by asking a question.

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

```
GET https://docs.appmixer.com/connector-configuration/utils/filters/modulo.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
