Skip to content

Commit

Permalink
fix(ruby): add helper to add segment to user agent (#3972) (generated…
Browse files Browse the repository at this point in the history
…) [skip ci]

Co-authored-by: Pierre Millot <pierre.millot@algolia.com>
  • Loading branch information
algolia-bot committed Oct 15, 2024
1 parent 9e73e97 commit 3899bf3
Show file tree
Hide file tree
Showing 9 changed files with 72 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# Creates a new A/B test.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# This method allow you to send requests to the Algolia REST API.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# Creates a new authentication resource.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# This method allow you to send requests to the Algolia REST API.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# This method allow you to send requests to the Algolia REST API.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# This method allow you to send requests to the Algolia REST API.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# Creates a new Query Suggestions configuration. You can have up to 100 configurations per Algolia application.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# Create or update a batch of Recommend Rules Each Recommend Rule is created or updated, depending on whether a Recommend Rule with the same &#x60;objectID&#x60; already exists. You may also specify &#x60;true&#x60; for &#x60;clearExistingRules&#x60;, in which case the batch will atomically replace all the existing Recommend Rules. Recommend Rules are similar to Search Rules, except that the conditions and consequences apply to a [source item](/doc/guides/algolia-recommend/overview/#recommend-models) instead of a query. The main differences are the following: - Conditions &#x60;pattern&#x60; and &#x60;anchoring&#x60; are unavailable. - Condition &#x60;filters&#x60; triggers if the source item matches the specified filters. - Condition &#x60;filters&#x60; accepts numeric filters. - Consequence &#x60;params&#x60; only covers filtering parameters. - Consequence &#x60;automaticFacetFilters&#x60; doesn&#39;t require a facet value placeholder (it tries to match the data source item&#39;s attributes instead).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,14 @@ def self.create_with_config(config)
# @return [void]
def set_client_api_key(api_key)
@api_client.set_client_api_key(api_key)

self
end

def add_user_agent_segment(segment, version = nil)
@api_client.config.add_user_agent_segment(segment, version)

self
end

# Creates a new API key with specific permissions and restrictions.
Expand Down

0 comments on commit 3899bf3

Please sign in to comment.