public function ServicesClientConnection::get in Services Client 7.2
Same name and namespace in other branches
- 7 services_client_connection/include/connection.inc \ServicesClientConnection::get()
Retrieve data from remote endpoint.
Parameters
string $resource: Resource type like 'node' or 'user'
int $id: Id of remote resource
mixed $data: Optionally additional data that should be added to query
Return value
Response from remote API
File
- services_client_connection/
include/ connection.inc, line 255 - Main services client connection class which exposes simple API
Class
- ServicesClientConnection
- @file Main services client connection class which exposes simple API
Code
public function get($resource, $id = NULL, $data = array()) {
$this->http_request = $this
->createRequest(array(
'resource' => $resource,
'id' => $id,
'data' => $data,
'action' => 'retrieve',
));
return $this
->processRequest()->data;
}