Top "Swifty-json" questions

SwiftyJSON is a tool to simplify handling JSON data in Swift.

How to convert a string into JSON using SwiftyJSON

The string to convert: [{"description": "Hi","id":2,"img":"hi.png"},{"description": "pet","id":10,"img":"pet.png"},{"description": "Hello! :D","id":12,"…

ios json swift swifty-json
Best practice to find out if SwiftyJSON dictionary has key

I'm trying to find a way to get the value of a key in a SwiftyJSON dictionary and return a …

swift swifty-json
Converting JSON from AlamoFire/SwiftyJSON to Dictionary in Swift/Xcode

My head is going to explode :) - I've been trying to get a JSON String from my server to a …

xcode swift alamofire swifty-json
How to create objects from SwiftyJSON

I have a code, that parses JSON's list of questions and I can get every property. How can I iterate …

swift swifty-json
JSON encoding with backslashes

I m using Alamofire and SwiftyJSOn to parse JSON output. It works very well however some sites give json with …

swift alamofire swifty-json
swiftyjson - Call can throw, but it is marked with 'try' and the error is not handled

I am trying to use swiftyjson and I am getting an Error: Call can throw, but it is marked with …

swift swifty-json
Creating JSON Array in Swift

My backend is expecting the following JSON body: [ { "number":"561310" }, { "number":"132333" }, { "number":"561310" } ] It works very nicely in Postman when I enter …

json swift swifty-json
How can I save and then load a JSON in NSUserDefaults with SwiftyJSON?

in my iOS project I need to save an entire JSON as user data and then reload it on next …

ios json swift nsuserdefaults swifty-json
SwiftyJSON looping through an array of JSON objects

[ { "cont": 9714494770, "id": "1", "name": "Kakkad" }, { "cont": 9714494770, "id": "2", "name": "Ashish" } ] The one above is a json array filled with JSON objects. I …

json swift swifty-json
How to check if key exists in swiftyJSON when json contain array with no keys

I know about swiftyJSON method exists() but it does not seem to work always as they say. How can I …

ios json swift swifty-json