Skip to content

Commit

Permalink
add support for TrackEvent, Experiment, Banners (#3)
Browse files Browse the repository at this point in the history
- new accountId param for QueryCollection and SendEvent requests
- bump package to v5.0.0
  • Loading branch information
jkaho authored Mar 10, 2022
1 parent a98b3f3 commit 77ffe1c
Show file tree
Hide file tree
Showing 134 changed files with 2,604 additions and 213 deletions.
30 changes: 24 additions & 6 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Gemfile
README.md
Rakefile
docs/ActivePromotion.md
docs/Banner.md
docs/BatchCreateSchemaFieldsRequest.md
docs/BatchCreateSchemaFieldsResponse.md
docs/BatchCreateSchemaFieldsResponseError.md
Expand All @@ -22,7 +23,11 @@ docs/Collection.md
docs/CollectionsApi.md
docs/DeleteRecordRequest.md
docs/Error.md
docs/Event.md
docs/EventsApi.md
docs/ExperimentRequest.md
docs/ExperimentRequestPipeline.md
docs/ExperimentResponse.md
docs/GeneratePipelinesRequest.md
docs/GeneratePipelinesResponse.md
docs/GetDefaultPipelineResponse.md
Expand All @@ -32,6 +37,7 @@ docs/GetRecordRequest.md
docs/ListCollectionsResponse.md
docs/ListPipelinesRequestView.md
docs/ListPipelinesResponse.md
docs/ListPromotionsRequestPromotionView.md
docs/ListPromotionsResponse.md
docs/ListRedirectsResponse.md
docs/ListSchemaFieldsResponse.md
Expand All @@ -47,6 +53,7 @@ docs/PromotionExclusion.md
docs/PromotionFilterBoost.md
docs/PromotionFilterCondition.md
docs/PromotionPin.md
docs/PromotionPinMode.md
docs/PromotionRangeBoost.md
docs/PromotionsApi.md
docs/ProtobufAny.md
Expand Down Expand Up @@ -83,6 +90,7 @@ docs/SendEventRequest.md
docs/SetDefaultPipelineRequest.md
docs/SetDefaultVersionRequest.md
docs/Status.md
docs/TextPosition.md
docs/UpdateRecordRequest.md
docs/UpsertRecordRequest.md
docs/UpsertRecordRequestPipeline.md
Expand All @@ -99,6 +107,7 @@ lib/sdk_ruby/api_client.rb
lib/sdk_ruby/api_error.rb
lib/sdk_ruby/configuration.rb
lib/sdk_ruby/models/active_promotion.rb
lib/sdk_ruby/models/banner.rb
lib/sdk_ruby/models/batch_create_schema_fields_request.rb
lib/sdk_ruby/models/batch_create_schema_fields_response.rb
lib/sdk_ruby/models/batch_create_schema_fields_response_error.rb
Expand All @@ -115,6 +124,10 @@ lib/sdk_ruby/models/batch_upsert_records_response_variables.rb
lib/sdk_ruby/models/collection.rb
lib/sdk_ruby/models/delete_record_request.rb
lib/sdk_ruby/models/error.rb
lib/sdk_ruby/models/event.rb
lib/sdk_ruby/models/experiment_request.rb
lib/sdk_ruby/models/experiment_request_pipeline.rb
lib/sdk_ruby/models/experiment_response.rb
lib/sdk_ruby/models/generate_pipelines_request.rb
lib/sdk_ruby/models/generate_pipelines_response.rb
lib/sdk_ruby/models/get_default_pipeline_response.rb
Expand All @@ -124,6 +137,7 @@ lib/sdk_ruby/models/get_record_request.rb
lib/sdk_ruby/models/list_collections_response.rb
lib/sdk_ruby/models/list_pipelines_request_view.rb
lib/sdk_ruby/models/list_pipelines_response.rb
lib/sdk_ruby/models/list_promotions_request_promotion_view.rb
lib/sdk_ruby/models/list_promotions_response.rb
lib/sdk_ruby/models/list_redirects_response.rb
lib/sdk_ruby/models/list_schema_fields_response.rb
Expand All @@ -138,6 +152,7 @@ lib/sdk_ruby/models/promotion_exclusion.rb
lib/sdk_ruby/models/promotion_filter_boost.rb
lib/sdk_ruby/models/promotion_filter_condition.rb
lib/sdk_ruby/models/promotion_pin.rb
lib/sdk_ruby/models/promotion_pin_mode.rb
lib/sdk_ruby/models/promotion_range_boost.rb
lib/sdk_ruby/models/protobuf_any.rb
lib/sdk_ruby/models/protobuf_field_mask.rb
Expand Down Expand Up @@ -170,6 +185,7 @@ lib/sdk_ruby/models/send_event_request.rb
lib/sdk_ruby/models/set_default_pipeline_request.rb
lib/sdk_ruby/models/set_default_version_request.rb
lib/sdk_ruby/models/status.rb
lib/sdk_ruby/models/text_position.rb
lib/sdk_ruby/models/update_record_request.rb
lib/sdk_ruby/models/upsert_record_request.rb
lib/sdk_ruby/models/upsert_record_request_pipeline.rb
Expand All @@ -178,10 +194,12 @@ lib/sdk_ruby/version.rb
sdk_ruby.gemspec
spec/api_client_spec.rb
spec/configuration_spec.rb
spec/models/batch_update_records_request_spec.rb
spec/models/batch_update_records_response_error_spec.rb
spec/models/batch_update_records_response_record_spec.rb
spec/models/batch_update_records_response_spec.rb
spec/models/promotion_category_spec.rb
spec/models/protobuf_field_mask_spec.rb
spec/models/banner_spec.rb
spec/models/event_spec.rb
spec/models/experiment_request_pipeline_spec.rb
spec/models/experiment_request_spec.rb
spec/models/experiment_response_spec.rb
spec/models/list_promotions_request_promotion_view_spec.rb
spec/models/promotion_pin_mode_spec.rb
spec/models/text_position_spec.rb
spec/spec_helper.rb
2 changes: 1 addition & 1 deletion .openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.3.1
5.4.0
18 changes: 14 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Search.io offers a search and discovery service with Neuralsearch®, the world's
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:

- API version: v4
- Package version: 4.3.0
- Package version: 5.0.0
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
For more information, please visit [https://www.search.io/company/contact](https://www.search.io/company/contact)

Expand All @@ -24,16 +24,16 @@ gem build sdk_ruby.gemspec
Then either install the gem locally:

```shell
gem install ./sdk_ruby-4.3.0.gem
gem install ./sdk_ruby-5.0.0.gem
```

(for development, run `gem install --dev ./sdk_ruby-4.3.0.gem` to install the development dependencies)
(for development, run `gem install --dev ./sdk_ruby-5.0.0.gem` to install the development dependencies)

or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).

Finally add this to the Gemfile:

gem 'sdk_ruby', '~> 4.3.0'
gem 'sdk_ruby', '~> 5.0.0'

### Install from Git

Expand Down Expand Up @@ -86,10 +86,12 @@ Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*SajariAPIClient::CollectionsApi* | [**create_collection**](docs/CollectionsApi.md#create_collection) | **POST** /v4/collections | Create collection
*SajariAPIClient::CollectionsApi* | [**delete_collection**](docs/CollectionsApi.md#delete_collection) | **DELETE** /v4/collections/{collection_id} | Delete collection
*SajariAPIClient::CollectionsApi* | [**experiment**](docs/CollectionsApi.md#experiment) | **POST** /v4/collections/{collection_id}:experiment | Experiment
*SajariAPIClient::CollectionsApi* | [**get_collection**](docs/CollectionsApi.md#get_collection) | **GET** /v4/collections/{collection_id} | Get collection
*SajariAPIClient::CollectionsApi* | [**list_collections**](docs/CollectionsApi.md#list_collections) | **GET** /v4/collections | List collections
*SajariAPIClient::CollectionsApi* | [**query_collection**](docs/CollectionsApi.md#query_collection) | **POST** /v4/collections/{collection_id}:query | Query collection
*SajariAPIClient::CollectionsApi* | [**query_collection2**](docs/CollectionsApi.md#query_collection2) | **POST** /v4/collections/{collection_id}:queryCollection | Query collection
*SajariAPIClient::CollectionsApi* | [**track_event**](docs/CollectionsApi.md#track_event) | **POST** /v4/collections/{collection_id}:trackEvent | Track event
*SajariAPIClient::CollectionsApi* | [**update_collection**](docs/CollectionsApi.md#update_collection) | **PATCH** /v4/collections/{collection_id} | Update collection
*SajariAPIClient::EventsApi* | [**send_event**](docs/EventsApi.md#send_event) | **POST** /v4/events:send | Send event
*SajariAPIClient::EventsApi* | [**send_event2**](docs/EventsApi.md#send_event2) | **POST** /v4/events:sendEvent | Send event
Expand Down Expand Up @@ -125,6 +127,7 @@ Class | Method | HTTP request | Description
## Documentation for Models

- [SajariAPIClient::ActivePromotion](docs/ActivePromotion.md)
- [SajariAPIClient::Banner](docs/Banner.md)
- [SajariAPIClient::BatchCreateSchemaFieldsRequest](docs/BatchCreateSchemaFieldsRequest.md)
- [SajariAPIClient::BatchCreateSchemaFieldsResponse](docs/BatchCreateSchemaFieldsResponse.md)
- [SajariAPIClient::BatchCreateSchemaFieldsResponseError](docs/BatchCreateSchemaFieldsResponseError.md)
Expand All @@ -141,6 +144,10 @@ Class | Method | HTTP request | Description
- [SajariAPIClient::Collection](docs/Collection.md)
- [SajariAPIClient::DeleteRecordRequest](docs/DeleteRecordRequest.md)
- [SajariAPIClient::Error](docs/Error.md)
- [SajariAPIClient::Event](docs/Event.md)
- [SajariAPIClient::ExperimentRequest](docs/ExperimentRequest.md)
- [SajariAPIClient::ExperimentRequestPipeline](docs/ExperimentRequestPipeline.md)
- [SajariAPIClient::ExperimentResponse](docs/ExperimentResponse.md)
- [SajariAPIClient::GeneratePipelinesRequest](docs/GeneratePipelinesRequest.md)
- [SajariAPIClient::GeneratePipelinesResponse](docs/GeneratePipelinesResponse.md)
- [SajariAPIClient::GetDefaultPipelineResponse](docs/GetDefaultPipelineResponse.md)
Expand All @@ -150,6 +157,7 @@ Class | Method | HTTP request | Description
- [SajariAPIClient::ListCollectionsResponse](docs/ListCollectionsResponse.md)
- [SajariAPIClient::ListPipelinesRequestView](docs/ListPipelinesRequestView.md)
- [SajariAPIClient::ListPipelinesResponse](docs/ListPipelinesResponse.md)
- [SajariAPIClient::ListPromotionsRequestPromotionView](docs/ListPromotionsRequestPromotionView.md)
- [SajariAPIClient::ListPromotionsResponse](docs/ListPromotionsResponse.md)
- [SajariAPIClient::ListRedirectsResponse](docs/ListRedirectsResponse.md)
- [SajariAPIClient::ListSchemaFieldsResponse](docs/ListSchemaFieldsResponse.md)
Expand All @@ -164,6 +172,7 @@ Class | Method | HTTP request | Description
- [SajariAPIClient::PromotionFilterBoost](docs/PromotionFilterBoost.md)
- [SajariAPIClient::PromotionFilterCondition](docs/PromotionFilterCondition.md)
- [SajariAPIClient::PromotionPin](docs/PromotionPin.md)
- [SajariAPIClient::PromotionPinMode](docs/PromotionPinMode.md)
- [SajariAPIClient::PromotionRangeBoost](docs/PromotionRangeBoost.md)
- [SajariAPIClient::ProtobufAny](docs/ProtobufAny.md)
- [SajariAPIClient::ProtobufFieldMask](docs/ProtobufFieldMask.md)
Expand Down Expand Up @@ -196,6 +205,7 @@ Class | Method | HTTP request | Description
- [SajariAPIClient::SetDefaultPipelineRequest](docs/SetDefaultPipelineRequest.md)
- [SajariAPIClient::SetDefaultVersionRequest](docs/SetDefaultVersionRequest.md)
- [SajariAPIClient::Status](docs/Status.md)
- [SajariAPIClient::TextPosition](docs/TextPosition.md)
- [SajariAPIClient::UpdateRecordRequest](docs/UpdateRecordRequest.md)
- [SajariAPIClient::UpsertRecordRequest](docs/UpsertRecordRequest.md)
- [SajariAPIClient::UpsertRecordRequestPipeline](docs/UpsertRecordRequestPipeline.md)
Expand Down
36 changes: 36 additions & 0 deletions docs/Banner.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# SajariAPIClient::Banner

## Properties

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **description** | **String** | The description of the banner, displayed in sub-head font. | [optional] |
| **height** | **Integer** | The height the banner occupies in grid cells. | [optional] |
| **id** | **String** | The ID of the banner, used to identify clicked banners. | [optional] |
| **image_url** | **String** | The URL of the image used for the banner. | [optional] |
| **position** | **Integer** | The 1-based index indicating where the banner appears in search results. | [optional] |
| **target_url** | **String** | The URL to redirect the user to when the banner is clicked. | [optional] |
| **text_color** | **String** | The color of the text as a hex code with a # prefix, e.g. #FFCC00 or #FC0. | [optional] |
| **text_position** | [**TextPosition**](TextPosition.md) | | [optional][default to 'TEXT_POSITION_UNSPECIFIED'] |
| **title** | **String** | The title of the banner, displayed in header font. | [optional] |
| **width** | **Integer** | The width the banner occupies in grid cells. | [optional] |

## Example

```ruby
require 'sdk_ruby'

instance = SajariAPIClient::Banner.new(
description: null,
height: null,
id: null,
image_url: null,
position: null,
target_url: null,
text_color: null,
text_position: null,
title: null,
width: null
)
```

2 changes: 1 addition & 1 deletion docs/Collection.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **account_id** | **String** | Output only. The ID of the account that owns this collection. | [optional][readonly] |
| **authorized_query_domains** | **Array<String>** | The list of authorized query domains for the collection. Client-side / browser requests to the [QueryCollection](/api#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] |
| **authorized_query_domains** | **Array<String>** | The list of authorized query domains for the collection. Client-side / browser requests to the [QueryCollection](/docs/api#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] |
| **create_time** | **Time** | Output only. Time the collection was created. | [optional][readonly] |
| **display_name** | **String** | The collection's display name. You can change this at any time. | |
| **id** | **String** | Output only. The collection's ID. | [optional][readonly] |
Expand Down
Loading

0 comments on commit 77ffe1c

Please sign in to comment.