func JSONToAmount(jsonAmount float64) (int64) {
var amount int64
tempVal := 1e8 * jsonAmount
if tempVal < 0 {
tempVal = tempVal - 0.5
}
if tempVal > 0 {
tempVal = tempVal + 0.5
}
// Then just rely on the integer truncating
amount = int64(tempVal)
return amount
}