> For the complete documentation index, see [llms.txt](https://missiveapp.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://missiveapp.com/docs/advanced-features/rules/templates/auto-label-issued-refunds.md).

# Auto-label issued refunds

Template: Label conversations when refunds are issued.

**Auto-Label Issued Refunds** is a Missive rule template designed for those in e-commerce and retail who have to process and keep track of refunds.

#### When enabled:

* The rule allows you to **automatically tag an email with a refund label** when you’ve sent out an email notifying the customer of their refund.

#### Here’s how it works:

* You need to determine a default sender of your refund emails.
* You need a consistent variable in your “refund issued” emails
* You need to check for attachments
* You need to create a **refunds** label

***

### Outgoing email rule: Auto-label issued refunds

This rule is meant to help you organize your e-commerce inbox a little more, without any extra manual steps.

<a href="https://mail.missiveapp.com/?importRule=auto-label-emails-for-issued-refunds_outgoing-message" class="button primary" data-icon="plus">Add to Missive</a>

#### There are three conditions and one action to make this rule work.

{% stepper %}
{% step %}
Each time an **email is sent from** your sales@ team, where it **contains a specific subject line** (Your refund has been approved), and there is **an attachment present**…
{% endstep %}

{% step %}
it will automatically **add the label** Refunds.
{% endstep %}
{% endstepper %}

<div data-with-frame="true"><figure><img src="https://3242897856-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1If7JwIQhfz5wGM9LiIU%2Fuploads%2FuDW01iIEKnL1iEfckdSZ%2Fautolabel-01.png?alt=media&amp;token=d03c530d-5d7e-4fc5-b9f9-3c9021af3e17" alt=""><figcaption></figcaption></figure></div>

<table><thead><tr><th width="220.484375">Component</th><th>Value</th></tr></thead><tbody><tr><td>Condition 1</td><td><strong>From is</strong> → {...}</td></tr><tr><td>Condition 2</td><td><strong>Subject contains</strong> → Your refund has been approved</td></tr><tr><td>Condition 3</td><td><strong>Attachments name is</strong> → present</td></tr><tr><td>Action 1</td><td><strong>Add label(s)</strong> → Refunds</td></tr></tbody></table>


---

# 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://missiveapp.com/docs/advanced-features/rules/templates/auto-label-issued-refunds.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.
