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

# Inbox lookup

> Resolve real-time CRM customer context from chat messages using phone numbers.

The Inbox lookup capability bridges the gap between omnichannel messaging conversations (such as WhatsApp, SMS, or live chat) and your CRM database. When a message arrives from a customer phone number, the CRM performs automated normalization and returns the complete customer record, active leads, and upcoming follow-ups.

## How it works

1. **Incoming conversation**: A chat message arrives with a phone number (such as `+1 (555) 123-4567` or `919876543210`).
2. **Phone normalization**: The API parses country codes and national digit strings, handling spaces, punctuation, leading plus signs, and leading zeroes.
3. **Context resolution**: The endpoint returns:
   * `contact`: The matched customer profile, tags, and custom fields.
   * `leads`: Any active or closed deals associated with the customer.
   * `recent_followups`: Scheduled reminders and follow-up history.
   * `matched`: Boolean flag indicating whether an existing record was identified.

## Integration workflow

Support and sales teams in the **Team Inbox** can view a contextual CRM side drawer automatically populated by this endpoint, allowing agents to see previous purchases, deal stage, and notes without switching tabs.

![CRM contextual customer drawer showing lead information, deal stage, and integrated conversation history](https://mintcdn.com/automatebusiness/OFwTsewf58VxBW78/images/automate-crm/crm-inbox-drawer.png?fit=max\&auto=format\&n=OFwTsewf58VxBW78\&q=85\&s=494ee830abe94c7d7778e0154b7be387)

## Related API operations

* [Lookup context by phone](https://docs.automatebusiness.com/automate-crm/api-reference/inbox-lookup/lookup-by-phone.md): Execute phone normalization and context retrieval.
* [Create or upsert contact](https://docs.automatebusiness.com/automate-crm/api-reference/contacts/create-contact.md): Create a contact record if the phone number is unmatched.


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