Nostr.Publisher (nostr_access v0.3.3)

View Source

Manages publishing a single Nostr event across multiple relays and collecting OK acks.

Summary

Functions

Returns a specification to start this module under a supervisor.

Types

publish_result()

@type publish_result() :: %{
  event_id: String.t() | nil,
  ok: non_neg_integer(),
  total: non_neg_integer(),
  statuses: %{
    optional(String.t()) => :pending | {:ok, String.t()} | {:error, String.t()}
  }
}

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

start_link(arg)

@spec start_link({[String.t()], map(), pid(), Keyword.t()}) ::
  {:ok, pid()} | {:error, term()}