makeJsonRequest Missing Array Support

Former Member
Former Member
I ran into an issue when trying to make a json request. It seems that if the json object contains an array a -402 status is returned. I couldn't find any documentation on what a -402 status was supposed to indicate.

I confirmed that when I pass a single waypoint back in the response it works fine. (See example below)

{
"id": 0,
"latitude": 42.7161007,
"longitude": -73.1852766,
"elevation": 208.817611694336,
"extensionData": {
"PC:totalTime": 175.0148043873541,
"PC:totalDistance": 273.66332512195584,
"PC:splitDistance": 0.02660514958802196,
"PC:splitTime": 0.01330257479401098
}
}


However when I pass a set of waypoints the makeJsonRequest callback has a status code of -402 and the data object is null.

{
"waypoints": [
{
"id": 0,
"latitude": 45.002394,
"longitude": -72.465963,
"elevation": 412.649963378906,
"extensionData": {
"PC:totalTime": 0,
"PC:totalDistance": 0
}
},
{
"id": 0,
"latitude": 45.003599,
"longitude": -72.466189,
"elevation": 407.804565429688,
"extensionData": {
"PC:totalTime": 0.02814610368410342,
"PC:totalDistance": 0.05629220736820684,
"PC:splitDistance": 0.05629220736820684,
"PC:splitTime": 0.02814610368410342
}
}
]
}