Sendio.Util (sendio v1.2.0)
Module for utility functions.
Summary
Functions
Link to this function
compact(map)
Removes nil values from a map. Used to avoid sending null values to the API.
Link to this function
parse_iso8601(date_string)
@spec parse_iso8601(String.t() | nil) :: DateTime.t() | nil
Parses an API timestamp to a UTC DateTime. Returns nil if argument is nil.
The API sends RFC 3339, for example 2026-11-10T14:40:35.840078+00:00.
The Postgres text form older responses used
(2026-11-10 14:40:35.840078+00) is still accepted.