function restclient_delete in RESTClient 7.2
Make a DELETE request
Parameters
string resource_path: The path to the REST method.
You can include wildcards in the string which will be filled in by the $parameters array. Ex: /Courses/%session
array $variables: An array of variables with the following keys:
endpoint [optional] : URL or hostname to the REST root. Specify a value to override the default configuration
parameters [optional] : Key/value pairs of parameters to inject into the resource path to replace dynamic values Ex: array('%session' => 20111)
query [optional] : Key/value pairs of query string parameters Ex: array('personid' => 2896263)
headers [optional] : Key/value pairs of extra header data to include in the request
retry [optional] : Number of retries. Defaults to 3
timeout [optional] : Timeout in seconds. Defaults to 30
reset [optional] : Boolean flag to reset the cache. Defaults to FALSE.
authentication [optional] : Array ...
- oauth2_client: Authenticate using OAuth. Contains an array of values to pass through so oauth2_client creates the client. May contain just ['name'] to look up an existing client by name. See oauth2_client documentation.
- oauth_format [optional]: The format for the Authorization request header to accommodate different server implementations. The default format is 'Bearer :token' where :token is replaced with the OAuth token.
Return value
object Returns an object containing the response data, FALSE otherwise.
1 call to restclient_delete()
File
- ./
restclient.module, line 290 - Defines a standard REST interface to RESTful services
Code
function restclient_delete($resource_path, $variables = array()) {
return _restclient_request($resource_path, $variables, 'DELETE');
}