unsent
unsent.dev
API Reference

Activity

The Activity API allows you to retrieve a global activity feed of email events within your team.

Base URL

https://api.unsent.dev/v1/activity

Overview

The Activity API provides a centralized feed of all email-related events happening across your team. This is useful for building dashboards, audit logs, or debugging delivery issues in real-time.

Features

Activity Feed

View all email events in chronological order

Endpoints

Get Activity Feed

GET /v1/activity

Retrieve a paginated list of activity events (sent, delivered, bounced, etc.) with email details.

Query Parameters:

ParameterTypeRequiredDefaultDescription
pagenumberNo1Page number for pagination
limitnumberNo50Number of items per page (max 100)

Example Request:

curl -X GET "https://api.unsent.dev/v1/activity?page=1&limit=20" \
  -H "Authorization: Bearer your-api-key"

Response (200 OK):

{
  "activity": [
    {
      "id": "act_123",
      "emailId": "email_xyz",
      "status": "DELIVERED",
      "data": {
        "response": "250 CA OK"
      },
      "teamId": "team_abc",
      "createdAt": "2024-01-15T12:00:00Z",
      "email": {
        "id": "email_xyz",
        "to": "user@example.com",
        "subject": "Welcome!",
        "from": "sender@domain.com"
      }
    },
    {
      "id": "act_122",
      "emailId": "email_xyz",
      "status": "SENT",
      "data": {},
      "teamId": "team_abc",
      "createdAt": "2024-01-15T11:59:59Z",
      "email": {
        "id": "email_xyz",
        "to": "user@example.com",
        "subject": "Welcome!",
        "from": "sender@domain.com"
      }
    }
  ],
  "page": 1,
  "limit": 20
}

Error Responses:

  • 400 Bad Request - Invalid pagination parameters
  • 401 Unauthorized - API key is missing or invalid
  • 429 Too Many Requests - Rate limit exceeded
  • 500 Internal Server Error - Something went wrong on the server

OpenAPI Specification