Skip to main content
GET
/
api
/
campaigns
/
{id}
/
generate-messages
List Generated Emails
curl --request GET \
  --url https://app.puffle.ai/api/campaigns/{id}/generate-messages \
  --header 'Authorization: Bearer <token>'
{
  "messages": [
    {
      "id": "<string>",
      "campaign_id": "<string>",
      "prospect_id": "<string>",
      "node_id": "<string>",
      "subject": "<string>",
      "body_text": "<string>",
      "manually_edited": true,
      "created_at": "2023-11-07T05:31:56Z",
      "body_html": "<string>"
    }
  ]
}
CLI:
puffle campaign generate-message list --id <id>
puffle campaign generate-message list --id <id> --status <status> --prospect-id <prospect-id>

Overview

Fetches generated campaign messages for one campaign. By default the endpoint returns draft messages; pass status=all, status=pending, or status=sent when reviewing another part of the message lifecycle. Pass prospect_id to focus on one lead. In that mode, inbound conversation replies are merged into the response so the UI can show the lead’s full thread context.

AI agent notes

Use this before editing generated copy or showing a human the messages that will be sent. This endpoint does not send or regenerate messages. Only call Edit generated email for draft messages the human wants to change.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

Campaign UUID

Query Parameters

status
enum<string>
default:draft

Message status filter. Defaults to draft; all disables the status filter.

Available options:
draft,
pending,
sent,
all
prospect_id
string

Optional lead filter to fetch messages for one lead.

Response

Generated messages fetched successfully.

messages
object[]
required