emails

Operations about emails

Get metadata on all Emails

Paginate through all emails in Affinity. Returns basic information about the email interaction and its participants. Will only return emails or subject lines that the current authenticated user has permission to see.

You can filter emails using the filter query parameter. The filter parameter is a string that you can specify conditions based on the following properties.

Property Name Description Type Allowed Operators Examples
id Unique identifier for Emails int64 = id=1
sentAt When the Email was sent at datetime >, <, >=, <= sentAt>2025-01-01T01:00:00Z
createdAt When the Email was created in Affinity datetime >, <, >=, <= createdAt<2025-01-01T01:00:00Z
updatedAt When the Email was updated in Affinity datetime >, <, >=, <= updatedAt>=2025-01-01T01:00:00Z
SecuritybearerAuth
Request
query Parameters
cursor
string

Cursor for the next or previous page

Example: cursor=ICAgICAgYmVmb3JlOjo6Nw
limit
integer <int32> [ 1 .. 100 ]
Default: 100

Number of items to include in the page

Example: limit=100
filter
string

Filter options

Example: filter=id=1234
Responses
200

OK

Response Headers
X-Ratelimit-Limit-User
integer

Number of requests allowed per minute for the user

X-Ratelimit-Limit-User-Remaining
integer

Number of requests remaining for the user

X-Ratelimit-Limit-User-Reset
integer

Time in seconds before the limit resets for the user

X-Ratelimit-Limit-Org
integer

Number of requests allowed per month for the account

X-Ratelimit-Limit-Org-Remaining
integer

Number of requests remaining for the account

X-Ratelimit-Limit-Org-Reset
integer

Time in seconds before the limit resets for the account

Response Schema: application/json
required
Array of objects (interactions.Email) <= 100 items

A page of Email results

Array (<= 100 items)
id
required
integer <int64> [ 1 .. 9007199254740991 ]

The email's unique identifier

sentAt
required
string <date-time>

The timestamp of when the email was sent

loggingType
required
string

Indicates how the interaction was added to Affinity: either manually by a user ('manual') or automatically through Affinity's capture process ('automated'). Currently, emails can only be logged as 'automated'.

Value: "automated"
direction
required
string

The direction of the email: 'sent' if the email was sent by an internal user and 'received' if the email was sent to an internal user.

Enum: "sent" "received"
subject
required
string or null

The email's subject

createdAt
required
string <date-time>

The timestamp of when the email was created

updatedAt
required
string or null <date-time>

The timestamp of when the email was updated

required
object (Attendee)

The participant who sent the email

required
object (AttendeesPreview)

A preview of the participants in the 'To' field of the email

required
object (AttendeesPreview)

A preview of the participants who are cc'ed in the email

required
object (Pagination)
prevUrl
string or null <uri>

URL for the previous page

nextUrl
string or null <uri>

URL for the next page

400

Bad Request

default

Errors

get/v2/emails
Request samples
Response samples
application/json
{
  • "data": [
    ],
}