type.inbound
and length(body.current_thread.links) == 2
and length(filter(html.xpath(body.html, "//a").nodes,
.display_text == "h"
and any(.links, .href_url.scheme in ("http", "https"))
)) == 1
and length(filter(html.xpath(body.html, "//a").nodes,
(
strings.starts_with(.display_text, "ttp://")
or strings.starts_with(.display_text, "ttps://")
)
and any(.links, .href_url.scheme in ("http", "https"))
)) == 1
Playground
Test against your own EMLs or sample data.