AlamoFire What I need is a Dictionary not a Array of Dictionary

I am lost on how to save my JSON as a Dictionary not as (Array of Dictionary)

I got this working perfectly as a Array of Dictionaries with this URL ( http://api.androidhive.info/contacts/ )
How can I capture as a pure dictionary ??

override func viewDidLoad() {
super.viewDidLoad()

    Alamofire.request(.GET, "http://logger.lumberjacksystem.com/index.php/api/list_stories/74/74/").responseJSON { (responseData) -> Void in
        let swiftyJsonVar = JSON(responseData.result.value!)
        
        if let resData = swiftyJsonVar["contacts"].arrayObject {
            self.arrayOfDictionary = resData as! [[String:AnyObject]]
        }
       
        if self.arrayOfDictionary.count > 0 {
            self.tblJSON.reloadData()
        }
    }
}

Which part of the data structure are you trying to save?

Your swiftyJsonVar is a JSON dictionary with one entry, which is an array of dictionaries. Are you trying to capture the root dictionary, or one of those in the array?

Thank you for your reply. Click on the URL below please

URL ( http://api.androidhive.info/contacts/1 )

You will see that the Array of Dictionary is based on “Contacts”

And the URL below is a pure Dictionary not an Array of Dictionary

http://logger.lumberjacksystem.com/index.php/api/list_stories/74/74/

I am able to to extract the Dictionary from Contacts no problem. But I do not understand how to extract a Dictionary from the JSON.

(Dropbox - File Deleted)
This will help you to see what I am trying to accomplish.

A post was split to a new topic: Cocoapods for contacts problem