XD-479 Add inbound and outbound conversion

TODO: tap

TODO: (see TODOs in code)