# Consent Processing Logic

The **Consent JavaScript SDK** plays a crucial role in controlling how and when tags are executed in **JENTIS Tag Manager**.\
When a vendor is set to **Consent Mode**, its tags will not execute until the user explicitly interacts with the **Consent Management Platform (CMP)**—either **granting** or **denying** consent.

If the user ignores the CMP banner, the associated tool will not process any data. This ensures that data collection always aligns with the user’s explicit consent status.

### Execution Timing

For vendors with the justification **Consent Mode**:

* Tags are executed **only after** an explicit user consent decision.
* If a visitor leaves before interacting with the CMP (a "bounce"), that visit is never recorded by tools requiring consent.

### Vendor Consent States

A vendor managed by the **Consent JavaScript SDK** can have one of the following states:

| State       | Meaning                                   |
| ----------- | ----------------------------------------- |
| `true`      | Consent explicitly given                  |
| `false`     | Consent explicitly denied                 |
| `ncm`       | No Consent – **Essential Mode** is active |
| `undefined` | No status known yet (awaiting decision)   |

> **Note:**
>
> * `ncm` and `false` are opposites.
> * If a vendor has **Essential Mode** enabled, the `false` status is not possible. The vendor will either be `true` (consent) or `ncm` (essential mode fallback).

### Non-Consent Justifications (Default)

If a tool’s justification is set to **No Consent Mode**:

* The internal system value defaults to `true` (treated as if explicit consent was given).
* This status will **not change** regardless of user interaction with the CMP.

### Data Processing Flow

Data processing in JENTIS follows two layers:

1. **Base Layer – Tag Manager Execution**
   * Commands such as `track:submit` initiate a **JENTIS Tag Manager State**.
   * Triggers are evaluated, and tags are activated according to their configurations.
2. **Consent JavaScript SDK Layer** *(default enabled)*
   * Even if triggers are ready to fire, tags will **only execute** if consent conditions are met.
   * Without consent, no tags run—ensuring compliance.


---

# 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://docs.jentis.com/developer-guide/consent-javascript-sdk/consent-processing-logic.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.
