# Automation

Next, we need to give MsgFiler 4 permission to send Apple Events to Mail. If you have enabled the MsgFiler Filing Script, you will also give permission for MsgFiler 4 to communicate with the System Events application through the Filing Script.

<figure><img src="/files/m2FSX8uuWTREtaA8iCTb" alt="" width="563"><figcaption></figcaption></figure>

1. Click on the **Verify Mail** button. A prompt will appear from macOS asking you to grant MsgFiler 4 permission to communicate with the Mail app using AppleScript.
2. Click **Allow**.

<figure><img src="/files/QkGw0vnJdSFRZykTfd1R" alt="" width="563"><figcaption></figcaption></figure>

3. If you have enabled the use of the MsgFiler Filing Script, click **Verify System Events**. Another prompt will appear from macOS asking you to grant MsgFiler 4 permission to communicate with System Events.
4. Click **Allow**.

<figure><img src="/files/PJQ7PWXE3xPVj3GNm74b" alt="" width="563"><figcaption></figcaption></figure>

When both Mail and System Events have been verified, you will see this screen. You can then click **Next** to go to the next onboarding step.

<figure><img src="/files/OKCkpCYf2z65MJYCeG9k" alt="" width="563"><figcaption></figcaption></figure>


---

# 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.msgfiler.com/onboarding/automation.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.
