Error while parsing API response string to JSON. Below is my JSON response 

> 
> "\t\n{\"status\":0,\"msg\":\"success\",\"data\":{\"numberOfOrder\":3256,\"title\_name\":\"URIBA DEALS\",\"title\_desc\":\"Deal & Discount from your nearly shops & services\",\"deals\":[{\"DealID\":\"200\",\"BusinessID\":\"279\",\"DealType\":\"specialoffer\",\"business\_type\":\"vegetables\",\"ImageURL\":\"\",\"CategoryID\":\"1111\",\"categoryType\":\"\",\"ProductID\":\"0\",\"Priority\":\"-48\",\"Status\":\"1\",\"CreatedAt\":\"2019-11-19 07:57:32\",\"PromoCode\":\"\",\"Offer\":\"0\",\"OfferType\":\"0\",\"Branch\":\"Kharadi(EON)\",\"NewLogo\":\"http:\/\/aiotechnology.in\/AmanoraKatta\/AdminPanel\/deals\_new\_img\/1574148777.jpg\",\"userAcquisitionStatus\":\"0\",\"maxOrder\":\"0\",\"minOrder\":\"0\",\"userAcquisitionDiscount\":\"0\",\"dealFrom\":\"0000-00-00 00:00:00\",\"dealTo\":\"0000-00-00 00:00:00\",\"deal\_description\":\"Onion @ Rs 17 half kg (Pick Onion From Amanora Office) ( limit 1 kg per person )\",\"from\_time\":\"00:00:00\",\"to\_time\":\"00:00:00\",\"from\_date\":\"0000-00-00\",\"to\_date\":\"0000-00-00\",\"deal\_delivery\_charges\":\"9\",\"app\_Version\":\"0\",\"walletAmount\":\"0\",\"name\":\"UriBA Vegetables Kharadi\",\"delivery\_status\_flag\":\"0\",\"delivery\_days\_after\":\"1\",\"business\_address\":\"Kharadi, Pune\",\"min\_order\_amt\":\"12\",\"latitude\":\"18.5578469\",\"longitude\":\"73.9449945\",\"delivery\_timings\":\"9 AM to 9 PM\",\"CST\":\"0\",\"GST\":\"0\",\"DELI\_CHRGS\":\"0\",\"PACK\_CHRGS\":\"2\",\"displayimage\":\"1571221633.jpg\",\"logo\_icon\":\"\",\"business\_margin\":\"0\",\"business\_margin\_flag\":\"0\"}}]}}
> 
> 
> 

Below is my Code

```
Alamofire.request(url).responseString { response in
        guard response.result.isSuccess,

        let data = response.result.value else
        {
            print("Error while fetching tags: \(String(describing: response.result.error))")
            completion(nil)
            return
        }

    completion(data)

```

Below is My Model Class:

```
class DealModelRootClass : NSObject, NSCoding{

var data : DealDataModelRootClass!
var msg : String!
var status : Int!

init(fromJson json: JSON!){
    if json.isEmpty{
        return
    }
    let dataJson = json["data"]
    if !dataJson.isEmpty{
        data = DealDataModelRootClass(fromJson: dataJson)
    }
    msg = json["msg"].stringValue
    status = json["status"].intValue
}

func toDictionary() -> [String:Any]
{
    var dictionary = [String:Any]()
    if data != nil{
        dictionary["data"] = data.toDictionary()
    }
    if msg != nil{
        dictionary["msg"] = msg
    }
    if status != nil{
        dictionary["status"] = status
    }
    return dictionary
}

@objc required init(coder aDecoder: NSCoder)
{
    data = aDecoder.decodeObject(forKey: "data") as? DealDataModelRootClass
    msg = aDecoder.decodeObject(forKey: "msg") as? String
    status = aDecoder.decodeObject(forKey: "status") as? Int
}

func encode(with aCoder: NSCoder)
{
    if data != nil{
        aCoder.encode(data, forKey: "data")
    }
    if msg != nil{
        aCoder.encode(msg, forKey: "msg")
    }
    if status != nil{
        aCoder.encode(status, forKey: "status")
    }

}
}

```

I have read a lot of blogs yet not able to fix this.
I am new to swift iOS.