Skip to content

Commit

Permalink
run codegen to include collection authorized query domains
Browse files Browse the repository at this point in the history
Also update to 3.0.2.
  • Loading branch information
jonathaningram committed Dec 15, 2020
1 parent c20ccd9 commit 6297861
Show file tree
Hide file tree
Showing 7 changed files with 53 additions and 10 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -198,5 +198,5 @@ [email protected]
This PHP package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:

- API version: `v4`
- Package version: `3.0.1`
- Package version: `3.0.2`
- Build package: `org.openapitools.codegen.languages.PhpClientCodegen`
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "sajari/sdk-php",
"version": "3.0.1",
"version": "3.0.2",
"description": "Sajari is a smart, highly-configurable, real-time search service that enables thousands of businesses worldwide to provide amazing search experiences on their websites, stores, and applications.",
"keywords": [
"sajari",
Expand Down
13 changes: 7 additions & 6 deletions docs/Model/Collection.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@

## Properties

| Name | Type | Description | Notes |
| ---------------- | ----------------------------- | ------------------------------------------------------------------- | --------------------- |
| **id** | **string** | Output only. The collection's ID. | [optional] [readonly] |
| **account_id** | **string** | Output only. The ID of the account that owns this collection. | [optional] [readonly] |
| **create_time** | [**\DateTime**](\DateTime.md) | Output only. Creation time of the collection. | [optional] [readonly] |
| **display_name** | **string** | The collection's display name. You can change this at any time. |
| Name | Type | Description | Notes |
| ---------------------------- | ----------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------- |
| **id** | **string** | Output only. The collection's ID. | [optional] [readonly] |
| **account_id** | **string** | Output only. The ID of the account that owns this collection. | [optional] [readonly] |
| **create_time** | [**\DateTime**](\DateTime.md) | Output only. Creation time of the collection. | [optional] [readonly] |
| **display_name** | **string** | The collection's display name. You can change this at any time. |
| **authorized_query_domains** | **string[]** | The list of authorized query domains for the collection. Client-side / browser requests to the [QueryCollection](/docs/api-reference#operation/QueryCollection) call can be made by any authorized query domain or any of its subdomains. This allows your interface to make search requests without having to provide an API key in the client-side request. | [optional] |

[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
2 changes: 1 addition & 1 deletion generate/generate.bash
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ if [ -z "$TEMPLATES_PATH" ]; then
die "TEMPLATES_PATH must be set, e.g. /path/to/sajari/sdk-php/generate/templates"
fi

VERSION=3.0.1
VERSION=3.0.2

docker-entrypoint.sh generate \
-i /openapi.json \
Expand Down
2 changes: 1 addition & 1 deletion lib/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,7 @@ public static function toDebugReport()
$report .= " OS: " . php_uname() . PHP_EOL;
$report .= " PHP Version: " . PHP_VERSION . PHP_EOL;
$report .= " The version of the OpenAPI document: v4" . PHP_EOL;
$report .= " SDK Package Version: 3.0.1" . PHP_EOL;
$report .= " SDK Package Version: 3.0.2" . PHP_EOL;
$report .=
" Temp Folder Path: " .
self::getDefaultConfiguration()->getTempFolderPath() .
Expand Down
33 changes: 33 additions & 0 deletions lib/Model/Collection.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ class Collection implements ModelInterface, ArrayAccess, \JsonSerializable
"account_id" => "string",
"create_time" => "\DateTime",
"display_name" => "string",
"authorized_query_domains" => "string[]",
];

/**
Expand All @@ -78,6 +79,7 @@ class Collection implements ModelInterface, ArrayAccess, \JsonSerializable
"account_id" => null,
"create_time" => "date-time",
"display_name" => null,
"authorized_query_domains" => null,
];

/**
Expand Down Expand Up @@ -111,6 +113,7 @@ public static function openAPIFormats()
"account_id" => "account_id",
"create_time" => "create_time",
"display_name" => "display_name",
"authorized_query_domains" => "authorized_query_domains",
];

/**
Expand All @@ -123,6 +126,7 @@ public static function openAPIFormats()
"account_id" => "setAccountId",
"create_time" => "setCreateTime",
"display_name" => "setDisplayName",
"authorized_query_domains" => "setAuthorizedQueryDomains",
];

/**
Expand All @@ -135,6 +139,7 @@ public static function openAPIFormats()
"account_id" => "getAccountId",
"create_time" => "getCreateTime",
"display_name" => "getDisplayName",
"authorized_query_domains" => "getAuthorizedQueryDomains",
];

/**
Expand Down Expand Up @@ -197,6 +202,8 @@ public function __construct(array $data = null)
$this->container["account_id"] = $data["account_id"] ?? null;
$this->container["create_time"] = $data["create_time"] ?? null;
$this->container["display_name"] = $data["display_name"] ?? null;
$this->container["authorized_query_domains"] =
$data["authorized_query_domains"] ?? null;
}

/**
Expand Down Expand Up @@ -320,6 +327,32 @@ public function setDisplayName($display_name)

return $this;
}

/**
* Gets authorized_query_domains
*
* @return string[]|null
*/
public function getAuthorizedQueryDomains()
{
return $this->container["authorized_query_domains"];
}

/**
* Sets authorized_query_domains
*
* @param string[]|null $authorized_query_domains The list of authorized query domains for the collection. Client-side / browser requests to the [QueryCollection](/docs/api-reference#operation/QueryCollection) call can be made by any authorized query domain or any of its subdomains. This allows your interface to make search requests without having to provide an API key in the client-side request.
*
* @return self
*/
public function setAuthorizedQueryDomains($authorized_query_domains)
{
$this->container[
"authorized_query_domains"
] = $authorized_query_domains;

return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
Expand Down
9 changes: 9 additions & 0 deletions test/Model/CollectionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,4 +114,13 @@ public function testPropertyDisplayName()
// TODO: implement
$this->markTestIncomplete("Not implemented");
}

/**
* Test attribute "authorized_query_domains"
*/
public function testPropertyAuthorizedQueryDomains()
{
// TODO: implement
$this->markTestIncomplete("Not implemented");
}
}

0 comments on commit 6297861

Please sign in to comment.