Engagement (report)

GET/api/v1/reports/engagement
Requires anorganization API keywith the scopereports:read

Request

GET/api/v1/reports/engagement
curl -X GET 'https://app.mailyte.com/api/v1/reports/engagement' \
  -H 'Authorization: Bearer mk_live_YOUR_API_KEY'
The key names its own organization, so no X-Organization-ID header is needed.

Response

Success.

  • dataobject
    • objectstringengagement_report
    • generated_atstring

      When this response was computed, ISO 8601 UTC. Every report answers it, so "is this figure stale?" never depends on which report you asked.

    • periodobject

      The period this report covers. A date_range other than day, week, month or quarter falls back to month, and this shows it. Null for a report read from /reports/history.

      • start_atstring
      • end_atstring
      • granularitystringday

        The width of one series bucket. Always day: the granularity query parameter is accepted and ignored.

    • totalsobject

      Engagement counts. Divide by delivered for rates.

      • deliveredinteger

        Messages a receiving server accepted. Divide engagement counts by this for rates. Null means unavailable, not 0.

      • openedinteger

        Opens. Each open counts, so one person opening twice counts twice. Null means unavailable, not 0.

      • clickedinteger

        Clicks. Each click counts. Null means unavailable, not 0.

      • unsubscribedinteger

        Unsubscribes. Null means unavailable, not 0.

    • seriesarray<object>

      The same counts bucketed over the period, oldest first. Rows are SPARSE: a bucket in which nothing happened has no row at all, rather than a row of zeros, so do not index this array by day offset.

      • start_atstring

        When this time bucket starts: midnight UTC.

      • deliveredinteger

        Messages a receiving server accepted. Divide engagement counts by this for rates. Null means unavailable, not 0.

      • openedinteger

        Opens. Each open counts, so one person opening twice counts twice. Null means unavailable, not 0.

      • clickedinteger

        Clicks. Each click counts. Null means unavailable, not 0.

      • unsubscribedinteger

        Unsubscribes. Null means unavailable, not 0.

Returned inside the standard envelope.

Errors

StatusWhen
401The API key is missing, unknown, revoked or expired. All four answer identically, on purpose: distinguishing them would confirm which keys exist.
403The key is valid but may not do this: it lacks the required scope, its IP allowlist does not include you, or this endpoint does not accept API keys.
404No such resource in this organization.
422The request was understood but the values were not acceptable.
429Too many requests, or the organization has spent its sending allowance. `Retry-After` says how long to wait.

Every status, with what causes it and what to do, is on the error reference.