Skip to content

Activity log

GET
/domains/{domain}/email-routing/activity
curl --request GET \
--url 'https://api.nsin.ir/domains/example.com/email-routing/activity?range=30m&status=forwarded&page=1&per_page=50' \
--header 'Authorization: Bearer <token>'

One row per message, newest first: envelope addresses, the authentication verdicts (SPF, DKIM, DMARC, ARC), what happened to it and why. subject is present only while subject logging is on for the platform. Kept 30 days. Requires domain.view.

domain
required
string

The domain name (for example example.com) — not a numeric id.

Example
example.com
range
string
default: 24h
Allowed values: 30m 24h 7d 30d custom

Time window, ending now. 30m buckets by minute, 24h by hour, 7d and 30d by day. custom takes RFC 3339 from and to (at most 31 days apart) and picks the bucket from the span.

from
string format: date-time

Start of a custom range, RFC 3339.

to
string format: date-time

End of a custom range, RFC 3339.

status
string
Allowed values: forwarded dropped rejected deferred bounce_dropped

Narrow to one status.

q
string

Case-insensitive match against sender, recipient, subject and Message-ID.

page
integer
default: 1 >= 1
per_page
integer
default: 50 >= 1 <= 200

A page of events.

Media type application/json
object
events
Array<object>

One recipient transaction on a mail host.

object
event_time
string format: date-time
node

The mail host.

string
session_id
string
txn_id
string
domain_id
integer
domain
string
rule_id

The rule that matched, 0 for none / catch-all.

integer
message_id
string
from_addr
string
from_domain
string
to_addr
string
destination

Where it was forwarded.

string
subject

Truncated to 128; absent while subject logging is off.

string
status
string
Allowed values: forwarded dropped rejected deferred bounce_dropped
action
string
Allowed values: forward drop catch_all srs_bounce none
reject_stage

connect | rbl | helo | mailfrom | rcpt | data | auth | loop | upstream | quota, or empty.

string
spf
string
dkim
string
dmarc
string
dmarc_policy
string
arc
string
error_code

The SMTP code returned to the sender.

string
error_detail

The receiving server’s text, when it refused.

string
client_ip
string
client_helo
string
client_ptr
string
rbl_zone
string
size
integer
spam_score
number
is_spam
integer
tls_in
string
tls_out
string
tls_out_verified
integer
upstream_mx
string
upstream_ip
string
egress_ip
string
duration_ms
integer
upstream_ms
integer
attempts
integer
page
integer
per_page
integer
total
integer
Example
{
"events": [
{
"status": "forwarded",
"action": "forward"
}
]
}

Bad range or custom bounds.

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Example
{
"error": "read-only API key"
}

Missing, malformed, revoked or expired API key — or the owning account is inactive.

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Examples
Example invalidKey
{
"error": "invalid API key"
}

No such domain, or it is not visible to this account. Domains you cannot access are reported as not found rather than forbidden.

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Example
{
"error": "read-only API key"
}

The key exceeded its request budget (300 requests per minute by default).

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Examples
Example limited
{
"error": "rate limit exceeded"
}

The activity log store is temporarily unreachable. Retry; no data is lost.

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Examples
Example unavailable
{
"error": "activity log temporarily unavailable"
}