Lettermint.Types.ListMessagesQuery (Lettermint v2.1.0)

Copy Markdown View Source

Query parameters of GET /messages (listMessages).

Pass them as a map with nested maps for bracketed names: %{page: %{size: 10}} is sent as page[size]=10. Lists of values are joined with commas, lists of maps are indexed and booleans are sent as 1 or 0.

Parameters

  • sort (optional)
  • filter[search] (optional): Search in sender, recipients, and subject. A complete email address matches the sender, To, CC or BCC address exactly and does not search the subject.
  • filter[tags][0][name] (optional): Exact tag name. Add more numbered pairs to match all pairs.
  • filter[tags][0][value] (optional): Exact tag value.
  • filter[from_email] (optional): Search by sender email (partial match)
  • filter[subject] (optional): Search by subject (partial match)
  • page[size] (optional): Number of results per page
  • page[cursor] (optional): Cursor for the next or previous page
  • filter (optional)
  • filter[tags] (optional)
  • filter[overdue] (optional)
  • filter[project] (optional): Filter by project ID
  • filter[type] (optional)
  • filter[status] (optional)
  • filter[delivery_mode] (optional)
  • filter[route_id] (optional): Filter by route ID
  • filter[domain_id] (optional): Filter by domain ID
  • filter[tag] (optional): Filter by tag name
  • filter[from_date] (optional): Filter messages created on or after this date
  • filter[to_date] (optional): Filter messages created on or before this date

Summary

Functions

The wire names of the parameters with their decode specs.

Types

t()

@type t() :: %{
  optional(:sort) => [Lettermint.Types.ListMessagesQuerySortItem.t()],
  optional(:filter) => %{
    optional(:search) => String.t(),
    optional(:from_email) => String.t(),
    optional(:subject) => String.t(),
    optional(:tags) =>
      String.t() | [Lettermint.Types.ListMessagesQueryFilterTagsItem.t()],
    optional(:overdue) => String.t(),
    optional(:project) => String.t(),
    optional(:type) => Lettermint.Types.MessageType.t(),
    optional(:status) => Lettermint.Types.MessageStatus.t(),
    optional(:delivery_mode) => Lettermint.Types.DeliveryMode.t(),
    optional(:route_id) => String.t(),
    optional(:domain_id) => String.t(),
    optional(:tag) => String.t(),
    optional(:from_date) => String.t(),
    optional(:to_date) => String.t()
  },
  optional(:page) => %{
    optional(:size) => integer(),
    optional(:cursor) => String.t()
  }
}

Functions

__params__()

The wire names of the parameters with their decode specs.