Skip to content

Commit

Permalink
Add Support for partial updates more broadly
Browse files Browse the repository at this point in the history
  • Loading branch information
hexa2k9 committed Jun 2, 2022
1 parent 9a5bb01 commit 61163df
Show file tree
Hide file tree
Showing 30 changed files with 330 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/Api/Circuits/CircuitTerminations.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/circuits/circuit-terminations/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/circuits/circuit-terminations/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Circuits/CircuitTypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/circuits/circuit-types/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/circuits/circuit-types/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Circuits/Circuits.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/circuits/circuits/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/circuits/circuits/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Circuits/Providers.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/circuits/providers/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/circuits/providers/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Extras/ConfigContexts.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/extras/config-contexts/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/extras/config-contexts/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Extras/CustomFields.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/extras/custom-fields/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/extras/custom-fields/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Extras/ExportTemplates.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/extras/export-templates/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/extras/export-templates/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Extras/ImageAttachments.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/extras/image-attachments/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/extras/image-attachments/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Extras/Tags.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/extras/tags/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/extras/tags/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/Aggregates.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/aggregates/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/aggregates/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/IpAddresses.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/ip-addresses/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/ip-addresses/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/Rirs.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/rirs/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/rirs/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/Roles.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/roles/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/roles/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/RouteTargets.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/route-targets/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/route-targets/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/Services.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/services/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/services/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/VlanGroups.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/vlan-groups/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/vlan-groups/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/Vlans.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/vlans/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/vlans/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/IPAM/Vrfs.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/ipam/vrfs/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/ipam/vrfs/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Secrets/SecretRoles.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/secrets/secret-roles/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/secrets/secret-roles/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Secrets/Secrets.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/secrets/secrets/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/secrets/secrets/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Tenancy/TenantGroups.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/tenancy/tenant-groups/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/tenancy/tenant-groups/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
11 changes: 11 additions & 0 deletions src/Api/Tenancy/Tenants.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ public function edit(int $id, array $params = []): array
return $this->put("/tenancy/tenants/" . $id . "/", $params);
}

/**
* @param int $id
* @param array $params
* @return array
* @throws GuzzleException
*/
public function update(int $id, array $params = []): array
{
return $this->patch("/tenancy/tenants/" . $id . "/", $params);
}

/**
* @param array $params
* @return mixed
Expand Down
Loading

0 comments on commit 61163df

Please sign in to comment.