# Notification Recipient Rules

<p class="doc-lead">Recipient Rules define how the system finds who receives an outbound notification — customer mobile, customer email, employee, or a fixed contact — for use on Transaction Configs.</p>

<div class="doc-toc">
<p class="doc-toc-title">On this page</p>
<div class="doc-toc-section">
<div class="doc-toc-links">
<a href="#/settings/notification-recipient-rules?id=overview">Overview &amp; List View</a>
<a href="#/settings/notification-recipient-rules?id=fields">Fields</a>
<a href="#/settings/notification-recipient-rules?id=examples">Examples</a>
<a href="#/settings/notification-recipient-rules?id=actions">Actions</a>
<a href="#/settings/notification-recipient-rules?id=faq">FAQ</a>
<a href="#/settings/notification-recipient-rules?id=related">Related</a>
</div>
</div>
</div>

<hr class="doc-section-divider">

<h2 id="overview">Overview &amp; List View</h2>

Go to <b>Settings → Notification System → Recipient Rules</b>.

<!-- screenshot pending -->

<b>List columns</b>: Id, Name, Status.

<b>Quick filters</b>: Active (default).

<b>Filters</b>: Name, Status.

<b>List actions</b>: New, View, Edit, Delete (multi).

<hr class="doc-section-divider">

<h2 id="fields">Fields</h2>

<h3>General</h3>

| **Field** | **Description** |
|-----------|-----------------|
| Name * | Rule name referenced on Transaction Configs. |

<h3>Resolution Steps</h3>

Add one or more steps (processed in order):

| **Field** | **Description** |
|-----------|-----------------|
| Step Type * | <b>resolve</b> — look up contact from document. <b>manual</b> — use fixed contact if needed. |
| Recipient Type | Customer, Supplier, or Employee (when Step Type is resolve). |
| Recipient ID Field Path | Document field pointing to party ID (e.g. customerId) — when Step Type is resolve. |
| Manual Contact | Fixed phone or email — when Step Type is manual. |
| Order | Step sequence when multiple steps exist. |

<hr class="doc-section-divider">

<h2 id="examples">Examples</h2>

<h3>Example A — Customer mobile for WhatsApp on Sale Invoice</h3>

| Order | Step Type | Recipient Type | Recipient ID Field Path |
|-------|-----------|----------------|-------------------------|
| 1 | resolve | Customer | customerId |

Links to customer phone on master for WhatsApp automatic sends.

<h3>Example B — Fallback manual number</h3>

| Order | Step Type | Manual Contact |
|-------|-----------|----------------|
| 1 | resolve | *(customerId → customer phone)* |
| 2 | manual | +919876543210 |

If customer phone is missing, send to fixed backup number (use carefully — compliance).

<h3>Example C — Manual Send Email</h3>

<p>Recipient rules are <b>optional</b> when using <b>Send Email</b> on sale documents — the user sets <b>To</b> on the compose screen. Rules are <b>required</b> for automatic email and WhatsApp configs so the system can resolve the recipient on status change.</p>

<hr class="doc-section-divider">

<h2 id="actions">Actions</h2>

New, View, Edit, Delete.

<hr class="doc-section-divider">

<h2 id="faq">FAQ</h2>

<p><b>What can a recipient rule target?</b></p>
<p>Customer, supplier, or employee contacts resolved from document fields — typically phone for WhatsApp and email for Email channel.</p>

<p><b>Can one rule serve multiple transaction configs?</b></p>
<p>Yes. Reuse the same Recipient Rule when audience logic is identical.</p>

<p><b>Why did the customer not receive WhatsApp?</b></p>
<ul>
<li>Customer phone missing or wrong format on master.</li>
<li>Rule field path incorrect (e.g. customerId).</li>
<li>Check <a href="#/settings/notification-transaction-history">Transaction History</a> Failed status.</li>
</ul>

<p><b>Are recipient rules used for Send Email button?</b></p>
<p>Not required — user enters To on compose. Optional for default pre-fill. Required for automatic email configs.</p>

<p><b>Are recipient rules used for Send to Whatsapp on invoice?</b></p>
<p>No. That button uses customer phone on the invoice directly.</p>

<p><b>Can I send to multiple numbers?</b></p>
<p>Depends on rule design and channel — test with sample approved document and review History.</p>

<p><b>Do recipient rules apply to in-app notifications?</b></p>
<p>No. Only for Notification System outbound channels.</p>

<p><b>Can I delete a rule in use?</b></p>
<p>Deletion may be blocked when Transaction Configs reference the rule — reassign configs first.</p>

<hr class="doc-section-divider">

<h2 id="related">Related Topics</h2>

<ul>
<li><a href="#/features/email-notifications">Email Notifications</a></li>
<li><a href="#/features/whatsapp">WhatsApp Messaging</a></li>
<li><a href="#/settings/notification-transaction-configs">Transaction Configs</a></li>
<li><a href="#/settings/notification-templates">Templates</a></li>
</ul>
