You are here

public function ServicesClientConnection::delete in Services Client 7

Same name and namespace in other branches
  1. 7.2 services_client_connection/include/connection.inc \ServicesClientConnection::delete()

Delete data from remote endpoint.

Parameters

string $resource: Resource type like 'node' or 'user'

int $id: Id of remote resource

Return value

Response from remote API

File

services_client_connection/include/connection.inc, line 280
Main services client connection class which exposes simple API

Class

ServicesClientConnection
@file Main services client connection class which exposes simple API

Code

public function delete($resource, $id = NULL) {
  $this->http_request = $this
    ->createRequest(array(
    'resource' => $resource,
    'id' => $id,
    'action' => 'delete',
  ));
  return $this
    ->processRequest()->data;
}