58 lines
1.3 KiB
PHP
58 lines
1.3 KiB
PHP
<?php
|
|
|
|
namespace wickedsoft\NetBox\Api\Extras;
|
|
|
|
use wickedsoft\NetBox\Api\AbstractApi;
|
|
|
|
class ConfigContexts extends AbstractApi
|
|
{
|
|
/**
|
|
* @param $params
|
|
* @return mixed
|
|
* @throws \GuzzleHttp\Exception\GuzzleException
|
|
*/
|
|
public function add($params=[])
|
|
{
|
|
return $this->post("/extras/config-contexts/", $params);
|
|
}
|
|
|
|
/**
|
|
* @param $params
|
|
* @return mixed
|
|
* @throws \GuzzleHttp\Exception\GuzzleException
|
|
*/
|
|
public function remove($id, $params=[])
|
|
{
|
|
return $this->delete("/extras/config-contexts/".$id."/", $params);
|
|
}
|
|
|
|
/**
|
|
* @param $params
|
|
* @return mixed
|
|
* @throws \GuzzleHttp\Exception\GuzzleException
|
|
*/
|
|
public function edit($id, $params=[])
|
|
{
|
|
return $this->put("/extras/config-contexts/".$id."/", $params);
|
|
}
|
|
|
|
/**
|
|
* @param $params
|
|
* @return mixed
|
|
* @throws \GuzzleHttp\Exception\GuzzleException
|
|
*/
|
|
public function list($params=[])
|
|
{
|
|
return $this->get("/extras/config-contexts/", $params);
|
|
}
|
|
|
|
/**
|
|
* @param $params
|
|
* @return mixed
|
|
* @throws \GuzzleHttp\Exception\GuzzleException
|
|
*/
|
|
public function show($id, $params=[])
|
|
{
|
|
return $this->get("/extras/config-contexts/".$id."/", $params);
|
|
}
|
|
}
|