/** * Deletes a new webhook * More info: https://www.hipchat.com/docs/apiv2/method/delete_webhook * * @param string $roomId The id or name of the room * @param string $webhookId The id of the webhook to delete * * @return void */ public function deleteWebhook($roomId, $webhookId) { $this->client->delete(sprintf('/v2/room/%s/webhook/%s', $roomId, $webhookId)); }
function it_deletes_webhook(Client $client) { $client->delete('/v2/room/123456/webhook/112233')->shouldBeCalled(); $this->deleteWebhook('123456', '112233'); }
/** * Delete a user * * @param string $userId The id, email address, or mention name (beginning with an '@') of the user to delete. * * @return void */ public function deleteUser($userId) { $this->client->delete(sprintf('/v2/user/%s', $userId)); }
function it_deletes_user(Client $client) { $client->delete('/v2/user/test')->shouldBeCalled(); $this->deleteUser('test'); }