<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"><channel><category>pcsoft.us.windev</category><copyright>Copyright 2026, PC SOFT</copyright><lastBuildDate>17 Feb 2016 07:45:00 Z</lastBuildDate><pubDate>17 Feb 2016 07:45:00 Z</pubDate><description>Hello,&#13;
&#13;
I have a PHP script example to handle api calls to a webserver, but i didn't fix it to translate this to windev httprequest commands can somebody help me ??&#13;
&#13;
&lt;?php&#13;
&#13;
// or live API: https://plazaapi.bol.com&#13;
$url = 'https://test-plazaapi.bol.com';&#13;
$uri = '/services/rest/orders/v1/open';&#13;
&#13;
// your public key&#13;
$public_key = 'public_key';&#13;
&#13;
//your private key&#13;
$private_key = 'private_key';&#13;
&#13;
$port = 443;&#13;
$contenttype = 'application/xml';&#13;
$date = gmdate('D, d M Y H:i:s T');&#13;
$httpmethod = 'GET';&#13;
&#13;
$signature_string = $httpmethod . "\ \ ";&#13;
$signature_string .= $contenttype . "\ ";&#13;
$signature_string .= $date."\ ";&#13;
$signature_string .= "x-bol-date:" . $date . "\ ";&#13;
$signature_string .= $uri;&#13;
$signature = $public_key.':'.base64_encode(hash_hmac('SHA256', $signature_string, $private_key, true));&#13;
&#13;
// Setup CURL (One can also opt to use sockets or http libraries, but CURL is a versatile, widespread solution)&#13;
$ch = curl_init();&#13;
curl_setopt($ch, CURLOPT_HTTPHEADER, array("Content-type: ".$contenttype, "X-BOL-Date:".$date, "X-BOL-Authorization: ".$signature));&#13;
curl_setopt($ch, CURLOPT_URL, $url.$uri);&#13;
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);&#13;
curl_setopt($ch, CURLOPT_PORT, $port);&#13;
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);&#13;
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);&#13;
&#13;
$result = curl_exec($ch);&#13;
&#13;
// Check if there were any errors.&#13;
if(curl_errno($ch)) {&#13;
print_r(curl_errno($ch), true);&#13;
}&#13;
&#13;
// Clean up after ourselves&#13;
curl_close($ch);&#13;
?&gt;</description><ttl>30</ttl><generator>WEBDEV</generator><language>en_US</language><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/56460-translate-php-script-windev-httprequest-calls/read.awp</link><title>Translate a PHP script to windev httprequest calls</title><managingEditor>moderateur@pcsoft.fr (El moderador)</managingEditor><webMaster>webmaster@pcsoft.fr (El webmaster)</webMaster></channel></rss>
