You’re a smart developer. You probably use Alamofire to abstract away access to URLSession and all those nasty details you don’t really care about. But then, like lots of smart developers, you write ad hoc network abstraction layers. They are probably called APIManager or NetworkModel, and they always end in tears. So the basic idea of Moya is that we want some network abstraction layer that sufficiently encapsulates actually calling Alamofire directly. It should be simple enough that common things are easy, but comprehensive enough that complicated things are also easy. If you use Alamofire to abstract away URLSession, why not use something to abstract away the nitty gritty of URLs, parameters, etc? After some setup, using Moya is really simple. Even cooler are the reactive extensions. Moya provides reactive extensions for ReactiveSwift and RxSwift.

Features

  • Compile-time checking for correct API endpoint accesses
  • Lets you define a clear usage of different endpoints with associated enum values
  • Treats test stubs as first-class citizens so unit testing is super-easy
  • In any file you’d like to use Moya in, don’t forget to import the framework with import Moya
  • Add Alamofire, Result & Moya as a git submodule
  • No more typos in URLs. No more missing parameter values. No more messing with parameter encoding

Project Samples

Project Activity

See All Activity >

License

MIT License

Follow Moya

Moya Web Site

Other Useful Business Software
$300 Free Credits for Your Google Cloud Projects Icon
$300 Free Credits for Your Google Cloud Projects

Start building on Google Cloud with $300 in free credits. No commitment, no credit card required until you're ready to scale.

Launch your next project with $300 in free Google Cloud credits—no strings attached. Test, build, and deploy without risk. Use your credits across the entire Google Cloud platform to find what works best for your needs. After your credits are used, continue with always-free tier services. Only pay when you're ready to scale. Sign up in minutes and start exploring.
Start Free Trial
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Moya!

Additional Project Details

Operating Systems

Apple iPhone, Mac

Programming Language

Swift

Related Categories

Swift Software Development Software, Swift Networking Software

Registered

2021-04-30