Gem alternatives and similar libraries
Based on the "Networking" category.
Alternatively, view Gem alternatives based on common mentions on social networks and blogs.
-
RealReachability
We need to observe the REAL reachability of network. That's what RealReachability do. -
Networking
DISCONTINUED. Easy HTTP Networking in Swift a NSURLSession wrapper with image caching support -
XMNetworking
A lightweight but powerful network library with simplified and expressive syntax based on AFNetworking. -
Digger
Digger is a lightweight download framework that requires only one line of code to complete the file download task -
SOAPEngine
This generic SOAP client allows you to access web services using a your iOS app, Mac OS X app and AppleTV app. -
TWRDownloadManager
A modern download manager based on NSURLSession to deal with asynchronous downloading, management and persistence of multiple files. -
ws โ๏ธ
โ ๏ธ Deprecated - (in favour of Networking) :cloud: Elegantly connect to a JSON api. (Alamofire + Promises + JSON Parsing) -
MultiPeer
๐ฑ๐ฒ A wrapper for the MultipeerConnectivity framework for automatic offline data transmission between devices -
AFNetworking+RetryPolicy
Nice category that adds the ability to set the retry interval, retry count and progressiveness.
CodeRabbit: AI Code Reviews for Developers

* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of Gem or a related project?
Popular Comparisons
README
Gem
A light weight network library with automated model parser for rapid development.
Managing all http request with automated model parser calls in app with closure
Requirements
- iOS 10.0+
- Swift 4.1+
- Xcode 9.2+
Installation
CocoaPods
Task is available through CocoaPods. To install it, simply add the following line to your Podfile:
use_frameworks!
pod "Gem"
or
use_frameworks!
pod 'Gem', git: 'https://github.com/Albinzr/Gem', :tag => '1.0.3'
Carthage
To integrate Task into your Xcode project using Carthage, specify it in your Cartfile:
github "Albinzr/Gem"
Usage & Requirement
- All model class should have Codable protocol
Naming for variable should be as follow
//json { name:"Albin CR", published_on:123455, Time:"23.10" } // model class class Details:Codable{ var name:String? // same variable as in json var publishedOn:Int? // incase of snake casing use camel casing of the same name var Time:String // same variable as in json }
Example
Get Request
//model
class User:Codable{
var id:Int?
var name:String?
var username:String?
var email:String?
var address:Address?
var phone:String?
var website:String?
var company:Company?
}
Gem.request(url: "https://jsonplaceholder.typicode.com/uses", method: Methods.get, model:User.self,
Success: { (data, response) in
// success block
print(data,response)
}) { (error, response) in
//error block
print(error,response)
}
response - contain all details related to network call like status code etc..
Post Request
class User:Codable{
var id:Int?
var name:String?
var username:String?
var email:String?
var address:Address?
var phone:String?
var website:String?
var company:Company?
}
let param: [String : Any] = [
"id":12324,
"name":"Albin CR",
"username":"Albi",
"email":"[email protected]",
"phone":"8907575123",
"website":"www.albin.in",
"company":[
"name":"Quin",
"catchPhrase":"Time to change",
"bs":"Pika",
]
]
Gem.request(url: "https://jsonplaceholder.typicode.com/posts", method: Methods.post,parameter:param,header:nil, model:User.self, Success: { (data, response) in
print(data,response ?? "")
print("success")
}) { (error, response) in
print(error ?? "",response!.statusCode)
}
ImageUpload
class ImageUpload:Codable{
var link:String?
var width:Float?
var height:Float?
var id:String?
}
let image:UIImage = UIImage(named: "scan") // or image url
let imageData:Data = UIImagePNGRepresentation(image)!
let base64Data = imageData.base64EncodedString()
let param:[String:Any] = [
"image":base64Data
]
let header:[String:String] = [
"Authorization":"Client-ID {{your client key}}",//replace your client key
"Content-type":"multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW'"
]
Gem.request(url: "https://api.imgur.com/3/image", method: Methods.post,parameter:param,header:header, model:ImageUpload.self, Success: { (data, response) in
print(data,response ?? "")
print("success")
}) { (error, response) in
print(error ?? "",response!.statusCode)
}
PR/request/suggestions are always welcome
*Note that all licence references and agreements mentioned in the Gem README section above
are relevant to that project's source code only.