> ## Documentation Index
> Fetch the complete documentation index at: https://docs.minimo.it/llms.txt
> Use this file to discover all available pages before exploring further.

# Contacts widget

> Each restaurant manages its own guests: search, add one or paste a list with consent, fix, remove, download as CSV

## What the restaurant sees

**My contacts**: the restaurant's own guests, 25 per page, with a search by name, email or phone and a filter (subscribed, unsubscribed, no consent, blocked). The restaurant can:

* **Add one contact** (email, first name, last name, phone) with a consent box and an optional "how they agreed".
* **Paste a list**: up to 200 lines, one contact per line as `email, first name, last name, phone` (comma, semicolon or tab). Each line gets an outcome (added, linked, already there, skipped with a reason). With the consent box, the restaurant must write how the consent was collected.
* **Fix** first name, last name and phone of its own contacts; the email only while no consent is on record (otherwise remove the contact and add the new address).
* **Remove** a contact from the restaurant and **download** its contacts as CSV.

## Mount it

Permission `contacts` (in the default). Mount `urls.contacts` from a [widget session](https://docs.minimo.it/guides/embedded-widgets.md):

```html theme={null}
<div id="minimo-contacts"></div>
<script src="https://api.minimo.it/public/v1/embed/widgets/widgets.js"></script>
<script>
  Minimo.mountWidget({ url: session.urls.contacts, container: '#minimo-contacts', minHeight: 700 });
</script>
```

## Events

| `widget` | `type` | `data` |
| - | - | - |
| `contacts` | `ready` | `count` |
| `contacts` | `contact.added` | `contactId`, `outcome` (`added` or `linked`), `consent`; for a pasted list `contactIds`, `count` |
| `contacts` | `contact.updated` | `contactId`, `changed` (fields) |
| `contacts` | `contact.removed` | `contactId` |
| `contacts` | `contacts.exported` | `count` |

## What stays as it is

* **Consent per restaurant** (see [consent](https://docs.minimo.it/guides/embedded-consent.md#consent-per-tenant)): the box records the restaurant's subscription with its evidence (session, IP, browser, the restaurant's text). A guest who unsubscribed is never subscribed again from the widget. In a workspace with consent per workspace the box is hidden: consent stays with your API.
* **Read only**: unsubscriptions (from the restaurant or from every email) and blocked addresses (bounce, spam complaint). "Receives campaigns" is the answer of the real campaign check.
* **Shared contacts**: an address another restaurant (or your workspace) already has is only linked, never modified, and shown by email only. Removing it unlinks this restaurant and withdraws its subscription; other restaurants keep theirs.
* Contacts created here do **not** start your workspace's own automations and do **not** get your workspace's marketing consent.
* A removed contact the restaurant created (and no other restaurant has) goes to the bin; its history stays.
* Limits per session: 30 changes per minute, 5 pasted lists and 10 exports every 10 minutes.
* **Clean lists**: an address that is not valid (including typos of big providers such as `gmial.com`), a throwaway mailbox or a generic one (`info@`, `noreply@`, `support@` and similar) is refused, when added one by one and on each pasted line (reasons `invalid_email`, `disposable_email`, `role_email`). See [clean lists](https://docs.minimo.it/guides/embedded-protections.md#clean-lists).
* Errors: `409 TENANT_CONTACT_SHARED`, `409 TENANT_CONTACT_EMAIL_LOCKED`, `409 TENANT_CONTACT_EMAIL_TAKEN`, `422 TENANT_CONTACT_PASTE_TOO_LARGE`, `422 TENANT_CONSENT_EVIDENCE_REQUIRED`, `422 INVALID_TENANT_CONTACT`, `422 TENANT_CONTACT_INVALID_EMAIL`, `422 TENANT_CONTACT_DISPOSABLE_EMAIL`, `422 TENANT_CONTACT_ROLE_EMAIL`, `429`. The page shows each one in the restaurant's language.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.