Karta.Messaging.Message (Karta v1.0.0)

One item of a conversation, inbound or outbound; an outbound message is one attempt (attempt_no) of a send request on one connector.

state: queued (accepted), waiting (waiting for the connector), sending (handed to the plug or the agent), sent, delivered, read, received (inbound), failed, unknown (nobody can tell whether it went out: Karta never sends it again by itself). body is encrypted at rest (Karta.Encrypted.Binary); addresses, times and states are not, so that they can be searched.

Summary

Functions

True when no more state changes are expected.

The kinds of content.

Order of the states of an outbound message that goes forward (a later one never goes back).

The states a message can be in.

Types

t()

@type t() :: %Karta.Messaging.Message{
  __meta__: term(),
  attempt_no: term(),
  backfill: term(),
  body: term(),
  category: term(),
  command_id: term(),
  connector: term(),
  connector_id: term(),
  conversation: term(),
  conversation_id: term(),
  cost: term(),
  direction: term(),
  duplicate_possible: term(),
  ended_at: term(),
  error_class: term(),
  error_code: term(),
  error_detail: term(),
  fallback_from: term(),
  final: term(),
  id: term(),
  inserted_at: term(),
  kind: term(),
  media_id: term(),
  metadata: term(),
  occurred_at: term(),
  offline: term(),
  provider_id: term(),
  reference: term(),
  request: term(),
  request_id: term(),
  sender_address: term(),
  sender_name: term(),
  server: term(),
  server_id: term(),
  source: term(),
  started_at: term(),
  state: term(),
  updated_at: term()
}

Functions

final_state?(state)

True when no more state changes are expected.

kinds()

The kinds of content.

rank(arg1)

Order of the states of an outbound message that goes forward (a later one never goes back).

states()

The states a message can be in.