Используйте функцию curl
:
http://php.net/manual/en/book.curl.php
Предполагается, что вы используете GET-запрос для подключения к RESTful API:
$url = "http://the-api-you-want/?the-args=your-args&another-arg=another-arg";
$ch = curl_init(); // start CURL
curl_setopt($ch, CURLOPT_URL, $url); // set your URL
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); // get the response as a variable
$json = curl_exec($ch); // connect and get your JSON response
curl_close($ch);
Затем вы можете использовать PHP json_decode
в ответе, если это то, что вы хотите сделать.
Другим вариантом будет использование функции drupal_http_request
Друпала http://api.drupal.org/api/function/drupal_http_request/6