Most voted "alamofire" questions
An HTTP networking library written in Swift.
Learn more…18 questions
Sort by count of
-
6
votes2
answers204
viewsProject Alamofire conversion to Swift 3.0
I have the following code when I want to make a call to the server: let mutableURLRequest = NSMutableURLRequest(url: URL) mutableURLRequest.httpMethod = "POST" let parameters = ["SessionID":…
-
2
votes1
answer82
viewsUpload image to webservice
I am using the alamofire to post pro server, I wanted to know how to send an object that has an img inside it. I saw the following excerpt to upload the image let fileURL =…
-
1
votes1
answer611
viewsHow to load an Image into a Uitableview?
I performed a request that returned me some texts and urls with images, these images I need to load them along with the text in parallel in the table. I am using Alamofire + Alamofireimage to load…
-
1
votes1
answer456
viewsHow to pass to Array JSON information on Swift
When the result comes from the server I use the following code snippet to receive the result: if let JSON = response.result.value { print("JSON: \(JSON)") } And the result of the print is: [{ Nome =…
-
1
votes1
answer77
viewsAlamofire 3 how to pick up errors if they exist in the call to the service(Swift2)
I have the following code to call the server Alamofire.request(mutableURLRequest) .responseJSON{ request, response, result in response in if let value: AnyObject = response.result.value { let post =…
-
1
votes1
answer690
viewsPost request on webservice with Swift
I’m starting now to use the still, I managed to make requests . get but stopped in post request. I created a user class that has name, email and password, however I can’t post a user object let…
-
1
votes0
answers25
viewsChange the name of the downloaded file using Alamofire
I’m developing an iOS app where I update downloading the JSON file with the new data, this file generated by PHP let destination = DownloadRequest.suggestedDownloadDestination(for:…
-
1
votes1
answer238
viewsHow to pass a value from a dictionary (which is inside another dictionary) to a Label? Swift 3
I have a database something like this: { "status": "OK", "data": [ { "id": 1, "name": "Mike", "informations": [ { "id": 474, "text": "My son", "reference": "www.google.com", } ] } I’m looking for…
-
1
votes3
answers138
viewsHow to treat a reponse.result.value that returns as log optional([])?
I am in the following situation I have a request in the Alamofire that returns me a json that may or may not have data (usually has but may not). I want to treat when Response.result.value returns…
-
1
votes1
answer442
viewsHow to work with Alamofire Sponse on Swift 4?
I have the following request that returns me a json I cannot catch the live ulrs Alamofire.request(urlRequest).validate().responseJSON { response in print(response.data) do { if let data =…
-
0
votes1
answer146
viewsHow to call a web service in swift2 Xcode 7
I’ve tried 1000 and 1 thing and still can’t find a way to call my web service and get the desired results. Can anyone tell me the best way to connect to my web-service and call my methods in swift2…
-
0
votes1
answer130
viewsHow to do a requisicao using alamofire and make the following lines of code wait for the reply of the request?
class func findProfessions() -> [PhotoProfession] { var professions = [PhotoProfession]() let backendless = Backendless.sharedInstance() if let p =…
-
0
votes1
answer71
viewsError post in Swift with still
But I once came to you for help. I’m developing a Swift application using web service written in java hosted on Amazon AWS. When I try to register via post the registration is not carried out. The…
-
0
votes1
answer60
viewsProblems with Conversion of Array to Swift 3
With the swift3 update I’m having the following error "type 'Any' has on the Members subscriber", I’ve seen a lot of questions on the subject and tested most of them but without success. The code…
-
0
votes1
answer115
viewsSwift - Send json body through the still
I’m on my first project on Swift, and I need to send a RequestBody in the POST by Alamofire. This is an example of JSON I need to send: { "user":{ "email":"[email protected]" } } And I have my…
-
0
votes1
answer27
viewsMigration from Alamofire 2 to Alamofire 4. Extra Argument in call (Request)
When making requests to the server used the following code let URL = Foundation.URL(string: "http:....")! let mutableURLRequest = NSMutableURLRequest(url: URL) mutableURLRequest.httpMethod = "POST"…
-
0
votes1
answer48
viewsJSON Object with Array. Migration from Swift 2 to Swift 3
Previously in my app when I made a call to the server and if there was an error I would do the following: Alamofire.request(mutableURLRequest).responseJSON{ response in if let JSON =…
-
0
votes0
answers477
viewsExample Login with basic auth authentication using Alamofire?
I’m trying to make a login screen where I use Alamofire to make the request, but with the examples of the site Alamofire is not working. If anyone can help with an example code, I would really…