Understanding Active vs Anonymized Contacts in the Mautic Leads Table

Hello,

M7.0.1 - Test Instance)
M6.0.3 - Production Instance

While working with Mautic at the database level, I’ve been exploring how different contact states are represented in the leads table. One thing that stood out is the apparent absence of an explicit status flag indicating whether a contact is active, anonymized, or in any other lifecycle state.

From inspecting the table structure, there doesn’t seem to be a straightforward column with values like active, anonymized, etc. This suggests that contact status is likely inferred from a combination of existing fields rather than a single, clearly defined indicator which is a shame.

I can capture some of this behavior at the SQL level through observation, but it’s not immediately obvious what the definitive logic is—especially for anonymized contacts. For example:

  • Are anonymized contacts identified by specific fields being nulled out?

  • Is there a flag or timestamp that implies anonymization indirectly?

  • Are there multiple conditions that together define the state?

Given the lack of a detailed, official database schema document, I’d really appreciate some clarification from someone familiar with the internals of the database schema.

Ideally, it would be helpful to know:

  • How Mautic determines whether a contact is active vs anonymized

  • Which fields or combinations of fields are involved

  • Where in the codebase this logic is implemented (so I can trace it myself)

If there’s a specific part of the code or documentation that explains this, a pointer in the right direction would be greatly appreciated. I’m happy to dig into the implementation—just looking for a starting point.

Thanks in advance!