A queue of the http-delivery type hands a message not to a receiver or a program but to a network address: with a POST request of type application/json, one message per request. The body is a JSON object with the raw message and the envelope addresses.
Success is only a 2xx response. Everything else counts as a temporary failure: the message stays in the queue and is retried, and bounce-after decides when it bounces. This is the fundamental difference from the pipe type: there the handler’s unavailability is indistinguishable from its breakage, here it honestly turns into a queue.
What comes in the body. The email_rfc822 field is the message itself; msg_from and rcpt_to are the envelope addresses; headers is an array of headers as “name — value” pairs. If the message contains a character outside 7-bit ASCII, the whole message is encoded in base64, and email_rfc822_is_base64 with the value true appears next to it.
# complaints go to the handler, authorization comes from the headers file <domain feedback.example.com> type http-delivery http-delivery-url https://hub.example.com/api/v1/feedback http-delivery-extra-headers /etc/pmta/http-delivery-headers.txt </domain>
what people get wrong and how it ends3 mistakes▶
§ 8.5
§ 8.5
§ 8.5
4 relations
http-delivery-url<domain>The handler address: without it a queue of this type does not work. § 8.5.1
Handing a message to a program on the same nodeThe same thing over the network: the handler lives anywhere, and unavailability turns into a temporary failure and a retry. inferenceA file, a program or an endpoint — and a file under each of the threeThe same contract of retrying until a 2xx response, except that there it hands off messages and here accounting records. inferenceComplaintThe report can not only be written but also passed to your own service over HTTP. inferenceWhat to do with an accepted messageA related mechanism: they work together. inference
pmta show settings feedback.example.com/vmta1 | grep -E '^type|^http-delivery' pmta show queues | grep -i feedback.example.com
3 articles
◇Who is allowed to submit mail and for whom to accept itOut of the box, the node accepts submission only from the machine itself; two different questions — “who can send through us” and “for whose addresses we accept mail” — are answered by different directives.◇Two inbound report processors and what to do with themBounces by message and complaints are parsed by two identically structured blocks; each has its own address list and its own pair of decisions about the message’s fate.◇Address lists — named and unnamedA list of addresses, domains, patterns or hashes; a named one is attached by directives such as suppression, an unnamed one lives inside an inbound mail processor.