The JSON digits are NSNumber , so you'll want to go through there.
import Foundation var json:AnyObject = NSNumber(longLong: 1234567890123456789) var num = json as? NSNumber var result = num?.longLongValue
Note that result is Int64? , since you do not know that this conversion will be successful.
Rob napier
source share