Email address
An email address
Email address attributes are a string referencing an internet email address. For example, an email address might be "[email protected]"
. Like domain attributes, we do some parsing of the email domain part, as well as validating the general shape of an email address overall.
It isn't currently possible to create your own email address attributes. You'll find only the multiselect email_addresses
attribute on a person object, or the single attribute email_address
attribute on the user standard object.
Reading values
There are five properties available on this attribute:
email_address
- the normalized form of the email address, this is the one you are most likely to useoriginal_email_address
- the email as it was originally input to the system, without normalizationemail_domain
- the full domain part of the email addressemail_root_domain
- the root domain part of the email addressemail_local_specifier
- the local part of the email address
{
"active_from": "2023-04-03T15:21:06.447000000Z",
"active_until": null,
"created_by_actor": {...},
"attribute_type": "email-address",
"email_address": "[email protected]",
"original_email_address": "[email protected]",
"email_domain": "company.com",
"email_root_domain": "company.com",
"email_local_specifier": "person"
}
Writing values
Email address values can be written by passing in a string of the email you would like to write.
We also support passing values with a single key, email_address
.
We strictly validate that email addresses have valid domain and local part formats.
Attio will automatically infer the root domain, local specify and other properties available on read so there is no need to write them yourself.
If writing to a multi-select attribute, you must wrap your input values in an array.
{
"email_addresses": ["[email protected]", "[email protected]"]
}
{
"email_address": "[email protected]"
}
{
"email_addresses": [
{
"email_address": "[email protected]"
}
]
}
Filtering
Email attribute values can be filtered by the email_address
, email_domain
, email_root_domain
and email_local_specifier
properties, and support several operators:
$eq
for an exact match$contains
,$starts_with
and$ends_with
In implicit mode, the email_address
property is checked for equality, otherwise you can use the explicit syntax to combine the properties and operators above.
{
"filter": {
"email_addresses": "[email protected]"
}
}
{
"filter": {
"email_addresses": {
"email_domain": {
"$eq": "attio.com"
}
}
}
}
{
"filter": {
"email_addresses": {
"email_local_specifier": {
"$contains": "person"
}
}
}
Updated 9 months ago