Network abstraction layer written in Swift