Disclaimer: I work at Mondo and am the one implementing the way we talk to our agency bank.
How it actually works is theres a Message Queue (IBM MQ) that is connected over dedicated lines (MPLS or point to point, but not over the internet).
Each side uses a couple of layers of Crypto, including using Hardware Security Modules (HSMs) to actually encrypt and sign the messages.
The crypto signatures also have legal standing in a sense, if the message is valid and signed then the counter party or agency bank is authorised to process it.