Wie übergebe ich den Parameter -WithNoStore? Es soll nach der Vorhersage das Bildmaterial nicht gespeichert werden.
$link = "https://xxx-prediction.cognitiveservices.azure.com/customvision/v3.0/Prediction/xxx/detect/iterations/Iterationx/url/";
$prediction = "xxx";
$ch = curl_init($link);
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
'Content-Type: application/json',
'Prediction-Key: ' . $prediction
));
$post_data = '{"Url": "' . $value . '"}';
curl_setopt($ch, CURLOPT_HEADEROPT, CURLHEADER_SEPARATE);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 40);
curl_setopt($ch, CURLOPT_TIMEOUT, 40);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $post_data);
$response = curl_exec($ch);
$json = json_decode($response, true);
curl_close($ch);