<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => “https://shopeeapi2.p.rapidapi.com/br/search?q=vestido”,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => “”,
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => “GET”,
CURLOPT_HTTPHEADER => [
“X-RapidAPI-Host: shopeeapi2.p.rapidapi.com”,
“X-RapidAPI-Key: xxxxx”
],
]);
curl);
curl);
curl_close($curl);
if ($err) {
echo “cURL Error #:” . $err;
} else {
echo $response;
}
Join in the discussion - add comment below: