title: HTTP Post Request API - Parsing JSON wrapped in Single Quotes
body: <p>My API accept only Single Quote wrapped JSON. Like:</p>
  
  <blockquote>
    <p>'{"api_key":"key_api1234","api_secret":"asdfg","uniqueid":"LDM23564GQQP","password":"test1","pin":"94729"}'</p>
  </blockquote>
  
  <p>I could find a definitive answer neither here nor on the internet.</p>
  
  <p>I Tried many syntax changes on JSON.</p>
  
  <pre><code>let parameters = ["api_key": "key_api1234",
                        "api_secret": "asdfg",
                        "uniqueid": "LDM23564GQQP",
                        "password": "test1",
                        "pin": "94729"]
  
      guard let url = URL(string: "https://dev-api.authenticateuser") else { return }
      var request = URLRequest(url: url)
      request.httpMethod = "POST"
      request.addValue("application/json", forHTTPHeaderField: "Content-Type")
      guard let httpBody = try? JSONSerialization.data(withJSONObject: parameters, options: []) else { return }
      request.httpBody = httpBody
  
      let session = URLSession.shared
      session.dataTask(with: request) { (data, response, error) in
          if let response = response {
              print(response)
          }
  
          if let data = data {
              do {
                  let json = try JSONSerialization.jsonObject(with: data, options: [])
                  print(json)
              } catch {
                  print(error)
              }
          }
  
          }.resume()
  </code></pre>
  
  <p>I am receiving a 500 Error</p>