Use this file to discover all available pages before exploring further.
The lettr.campaigns() service gives you read access to campaigns plus lifecycle actions — send now, schedule, and unschedule. Campaigns are authored in the Lettr app; the API does not expose create, update, or delete.Reads require an API key with the campaigns:read scope; actions require campaigns:write.
import com.lettr.Lettr;import com.lettr.services.campaigns.model.*;Lettr lettr = new Lettr("your-api-key");
get() returns CampaignDetail, which extends CampaignView and adds htmlContent. The action endpoints (send, schedule, unschedule) and list() return the base CampaignView, so they cannot accidentally expose HTML content.
Events use cursor-based pagination. Keep requesting with the returned cursor until it is null. A filtered page may come back with no events but a non-null cursor — that means more pages remain, so keep going.
// Immediately dispatches a draft; the campaign transitions to "preparing".CampaignView sending = lettr.campaigns().send(campaign.getId());// Schedule (or reschedule) for future delivery. Include a timezone offset.CampaignView scheduled = lettr.campaigns().schedule( campaign.getId(), ScheduleCampaignOptions.of("2026-06-01T09:00:00+00:00"));// Cancel a scheduled send, returning the campaign to "draft".CampaignView draft = lettr.campaigns().unschedule(campaign.getId());