{
"request":{
"user":{
"user_token": "#user_token#"
}
}
}
$post_array['user_token']=$row['oneall_user_token'];
if ($oneall_curly->put (SITE_DOMAIN . "/identities/".$identity_token."/link.json",$post_array))
{
$result = $oneall_curly->get_result ();
print_r (json_decode ($result->body));
}
//Error
else
{
$result = $oneall_curly->get_result ();
echo "Error: " . $result->http_info . "\n";
}
stdClass Object (
[response] => stdClass Object (
[request] => stdClass Object (
[date] => Tue, 24 Feb 2015 00:31:22 +0100
[resource] => /identities/7f5b5f85-1c41-4b6d-b46d-36d68b3d4542/link.json
[status] => stdClass Object (
[flag] => error
[code] => 400
[info] => Syntax Error: please check the format of your request
)
)
)
)
$post_array['user_token']=$row['oneall_user_token'];
$post_array = array (
'request' => array (
'user' => array (
'user_token' => $row['oneall_user_token']
)
)
);
$post_array = json_encode ($post_array);
Please sign in to your OneAll account to ask a new question or to contribute to the discussions.
Please click on the link below to connect to the forum with your OneAll account.
Answers