Letter records

A letter record stores information about a letter which was sent.

Fields

class LetterRecord
campaign: integer

The campaign the job belongs to.

error: integer

The letter record’s outcome.

  • 0 = succeeded

  • 1 = undeliverable

  • 2 = technical error

id: integer

The letter record’s unique ID.

job: integer

The job for which the letter was sent.

reference: string

Your reference for this job (e.g. customer ID), which must be unique within the campaign.

team: integer

The letter record’s team.

timestamp: datetime

The letter record’s date and time.

API

GET /j/letter_records

Retrieves the list of letter records.

You must specify a start date and an end date.

Request Headers:
Query Parameters:
  • end (datetime) – An end date and time.

  • modified_since (datetime) – An optional date and time in the past 48 hours. If specified, only items modified after this moment will be returned.

  • start (datetime) – A start date and time.

  • team (integer) – An optional team ID.

Response JSON Array of Objects:
  • campaign (integer) – The campaign the job belongs to.

  • error (integer) – The letter record’s outcome.

  • id (integer) – The letter record’s unique ID.

  • job (integer) – The job for which the letter was sent.

  • reference (string) – Your reference for this job (e.g. customer ID), which must be unique within the campaign.

  • team (integer) – The letter record’s team.

  • timestamp (datetime) – The letter record’s date and time.

Status Codes:
  • 200 OK – no error

  • 400 Bad Request – for instance a required field is missing

  • 403 Forbidden – you tried to access a forbidden resource, check you provided a valid OAuth token