Skip to content

Commit

Permalink
fix(specs): ingestion destinations and transformations (generated)
Browse files Browse the repository at this point in the history
algolia/api-clients-automation#3477

Co-authored-by: algolia-bot <accounts+algolia-api-client-bot@algolia.com>
Co-authored-by: Clément Vannicatte <vannicattec@gmail.com>
  • Loading branch information
algolia-bot and shortcuts committed Aug 5, 2024
1 parent 7ebbfe0 commit b5ffec9
Show file tree
Hide file tree
Showing 4 changed files with 120 additions and 1 deletion.
25 changes: 24 additions & 1 deletion lib/Api/IngestionClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ public function createAuthentication($authenticationCreate, $requestOptions = []
* - $destinationCreate['name'] => (string) Descriptive name for the resource. (required)
* - $destinationCreate['input'] => (array) (required)
* - $destinationCreate['authenticationID'] => (string) Universally unique identifier (UUID) of an authentication resource.
* - $destinationCreate['transformationIDs'] => (array)
*
* @see DestinationCreate
*
Expand Down Expand Up @@ -1750,19 +1751,40 @@ public function listTasksV1($itemsPerPage = null, $page = null, $action = null,
* - deleteIndex
* - editSettings
*
* @param int $itemsPerPage Number of items per page. (optional, default to 10)
* @param int $page Page number of the paginated API response. (optional)
* @param array $sort Property by which to sort the list. (optional)
* @param array $order Sort order of the response, ascending or descending. (optional)
* @param array $requestOptions the requestOptions to send along with the query, they will be merged with the transporter requestOptions
*
* @return \Algolia\AlgoliaSearch\Model\Ingestion\ListTransformationsResponse|array<string, mixed>
*/
public function listTransformations($sort = null, $order = null, $requestOptions = [])
public function listTransformations($itemsPerPage = null, $page = null, $sort = null, $order = null, $requestOptions = [])
{
if (null !== $itemsPerPage && $itemsPerPage > 100) {
throw new \InvalidArgumentException('invalid value for "$itemsPerPage" when calling IngestionClient.listTransformations, must be smaller than or equal to 100.');
}
if (null !== $itemsPerPage && $itemsPerPage < 1) {
throw new \InvalidArgumentException('invalid value for "$itemsPerPage" when calling IngestionClient.listTransformations, must be bigger than or equal to 1.');
}

if (null !== $page && $page < 1) {
throw new \InvalidArgumentException('invalid value for "$page" when calling IngestionClient.listTransformations, must be bigger than or equal to 1.');
}

$resourcePath = '/1/transformations';
$queryParameters = [];
$headers = [];
$httpBody = null;

if (null !== $itemsPerPage) {
$queryParameters['itemsPerPage'] = $itemsPerPage;
}

if (null !== $page) {
$queryParameters['page'] = $page;
}

if (null !== $sort) {
$queryParameters['sort'] = $sort;
}
Expand Down Expand Up @@ -2294,6 +2316,7 @@ public function updateAuthentication($authenticationID, $authenticationUpdate, $
* - $destinationUpdate['name'] => (string) Descriptive name for the resource.
* - $destinationUpdate['input'] => (array)
* - $destinationUpdate['authenticationID'] => (string) Universally unique identifier (UUID) of an authentication resource.
* - $destinationUpdate['transformationIDs'] => (array)
*
* @see DestinationUpdate
*
Expand Down
32 changes: 32 additions & 0 deletions lib/Model/Ingestion/Destination.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ class Destination extends AbstractModel implements ModelInterface, \ArrayAccess,
'createdAt' => 'string',
'updatedAt' => 'string',
'authenticationID' => 'string',
'transformationIDs' => 'string[]',
];

/**
Expand All @@ -43,6 +44,7 @@ class Destination extends AbstractModel implements ModelInterface, \ArrayAccess,
'createdAt' => null,
'updatedAt' => null,
'authenticationID' => null,
'transformationIDs' => null,
];

/**
Expand All @@ -59,6 +61,7 @@ class Destination extends AbstractModel implements ModelInterface, \ArrayAccess,
'createdAt' => 'createdAt',
'updatedAt' => 'updatedAt',
'authenticationID' => 'authenticationID',
'transformationIDs' => 'transformationIDs',
];

/**
Expand All @@ -74,6 +77,7 @@ class Destination extends AbstractModel implements ModelInterface, \ArrayAccess,
'createdAt' => 'setCreatedAt',
'updatedAt' => 'setUpdatedAt',
'authenticationID' => 'setAuthenticationID',
'transformationIDs' => 'setTransformationIDs',
];

/**
Expand All @@ -89,6 +93,7 @@ class Destination extends AbstractModel implements ModelInterface, \ArrayAccess,
'createdAt' => 'getCreatedAt',
'updatedAt' => 'getUpdatedAt',
'authenticationID' => 'getAuthenticationID',
'transformationIDs' => 'getTransformationIDs',
];

/**
Expand Down Expand Up @@ -126,6 +131,9 @@ public function __construct(?array $data = null)
if (isset($data['authenticationID'])) {
$this->container['authenticationID'] = $data['authenticationID'];
}
if (isset($data['transformationIDs'])) {
$this->container['transformationIDs'] = $data['transformationIDs'];
}
}

/**
Expand Down Expand Up @@ -386,6 +394,30 @@ public function setAuthenticationID($authenticationID)
return $this;
}

/**
* Gets transformationIDs.
*
* @return null|string[]
*/
public function getTransformationIDs()
{
return $this->container['transformationIDs'] ?? null;
}

/**
* Sets transformationIDs.
*
* @param null|string[] $transformationIDs transformationIDs
*
* @return self
*/
public function setTransformationIDs($transformationIDs)
{
$this->container['transformationIDs'] = $transformationIDs;

return $this;
}

/**
* Returns true if offset exists. False otherwise.
*
Expand Down
32 changes: 32 additions & 0 deletions lib/Model/Ingestion/DestinationCreate.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ class DestinationCreate extends AbstractModel implements ModelInterface, \ArrayA
'name' => 'string',
'input' => '\Algolia\AlgoliaSearch\Model\Ingestion\DestinationInput',
'authenticationID' => 'string',
'transformationIDs' => 'string[]',
];

/**
Expand All @@ -37,6 +38,7 @@ class DestinationCreate extends AbstractModel implements ModelInterface, \ArrayA
'name' => null,
'input' => null,
'authenticationID' => null,
'transformationIDs' => null,
];

/**
Expand All @@ -50,6 +52,7 @@ class DestinationCreate extends AbstractModel implements ModelInterface, \ArrayA
'name' => 'name',
'input' => 'input',
'authenticationID' => 'authenticationID',
'transformationIDs' => 'transformationIDs',
];

/**
Expand All @@ -62,6 +65,7 @@ class DestinationCreate extends AbstractModel implements ModelInterface, \ArrayA
'name' => 'setName',
'input' => 'setInput',
'authenticationID' => 'setAuthenticationID',
'transformationIDs' => 'setTransformationIDs',
];

/**
Expand All @@ -74,6 +78,7 @@ class DestinationCreate extends AbstractModel implements ModelInterface, \ArrayA
'name' => 'getName',
'input' => 'getInput',
'authenticationID' => 'getAuthenticationID',
'transformationIDs' => 'getTransformationIDs',
];

/**
Expand Down Expand Up @@ -102,6 +107,9 @@ public function __construct(?array $data = null)
if (isset($data['authenticationID'])) {
$this->container['authenticationID'] = $data['authenticationID'];
}
if (isset($data['transformationIDs'])) {
$this->container['transformationIDs'] = $data['transformationIDs'];
}
}

/**
Expand Down Expand Up @@ -284,6 +292,30 @@ public function setAuthenticationID($authenticationID)
return $this;
}

/**
* Gets transformationIDs.
*
* @return null|string[]
*/
public function getTransformationIDs()
{
return $this->container['transformationIDs'] ?? null;
}

/**
* Sets transformationIDs.
*
* @param null|string[] $transformationIDs transformationIDs
*
* @return self
*/
public function setTransformationIDs($transformationIDs)
{
$this->container['transformationIDs'] = $transformationIDs;

return $this;
}

/**
* Returns true if offset exists. False otherwise.
*
Expand Down
32 changes: 32 additions & 0 deletions lib/Model/Ingestion/DestinationUpdate.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ class DestinationUpdate extends AbstractModel implements ModelInterface, \ArrayA
'name' => 'string',
'input' => '\Algolia\AlgoliaSearch\Model\Ingestion\DestinationInput',
'authenticationID' => 'string',
'transformationIDs' => 'string[]',
];

/**
Expand All @@ -37,6 +38,7 @@ class DestinationUpdate extends AbstractModel implements ModelInterface, \ArrayA
'name' => null,
'input' => null,
'authenticationID' => null,
'transformationIDs' => null,
];

/**
Expand All @@ -50,6 +52,7 @@ class DestinationUpdate extends AbstractModel implements ModelInterface, \ArrayA
'name' => 'name',
'input' => 'input',
'authenticationID' => 'authenticationID',
'transformationIDs' => 'transformationIDs',
];

/**
Expand All @@ -62,6 +65,7 @@ class DestinationUpdate extends AbstractModel implements ModelInterface, \ArrayA
'name' => 'setName',
'input' => 'setInput',
'authenticationID' => 'setAuthenticationID',
'transformationIDs' => 'setTransformationIDs',
];

/**
Expand All @@ -74,6 +78,7 @@ class DestinationUpdate extends AbstractModel implements ModelInterface, \ArrayA
'name' => 'getName',
'input' => 'getInput',
'authenticationID' => 'getAuthenticationID',
'transformationIDs' => 'getTransformationIDs',
];

/**
Expand Down Expand Up @@ -102,6 +107,9 @@ public function __construct(?array $data = null)
if (isset($data['authenticationID'])) {
$this->container['authenticationID'] = $data['authenticationID'];
}
if (isset($data['transformationIDs'])) {
$this->container['transformationIDs'] = $data['transformationIDs'];
}
}

/**
Expand Down Expand Up @@ -272,6 +280,30 @@ public function setAuthenticationID($authenticationID)
return $this;
}

/**
* Gets transformationIDs.
*
* @return null|string[]
*/
public function getTransformationIDs()
{
return $this->container['transformationIDs'] ?? null;
}

/**
* Sets transformationIDs.
*
* @param null|string[] $transformationIDs transformationIDs
*
* @return self
*/
public function setTransformationIDs($transformationIDs)
{
$this->container['transformationIDs'] = $transformationIDs;

return $this;
}

/**
* Returns true if offset exists. False otherwise.
*
Expand Down

0 comments on commit b5ffec9

Please sign in to comment.