trieve_ruby_client 0.6.9 → 0.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +7 -7
- data/docs/ChunkData.md +0 -2
- data/docs/ClientDatasetConfiguration.md +2 -0
- data/docs/CreateTopicData.md +3 -1
- data/docs/FileApi.md +4 -6
- data/docs/GetEventsData.md +1 -1
- data/docs/Topic.md +3 -3
- data/docs/TopicApi.md +17 -17
- data/docs/UpdateUserOrgRoleData.md +22 -0
- data/docs/UserApi.md +9 -10
- data/lib/trieve_ruby_client/api/auth_api.rb +1 -1
- data/lib/trieve_ruby_client/api/chunk_api.rb +1 -1
- data/lib/trieve_ruby_client/api/chunk_group_api.rb +1 -1
- data/lib/trieve_ruby_client/api/dataset_api.rb +1 -1
- data/lib/trieve_ruby_client/api/events_api.rb +1 -1
- data/lib/trieve_ruby_client/api/file_api.rb +4 -11
- data/lib/trieve_ruby_client/api/health_api.rb +1 -1
- data/lib/trieve_ruby_client/api/invitation_api.rb +1 -1
- data/lib/trieve_ruby_client/api/message_api.rb +1 -1
- data/lib/trieve_ruby_client/api/organization_api.rb +1 -1
- data/lib/trieve_ruby_client/api/stripe_api.rb +1 -1
- data/lib/trieve_ruby_client/api/topic_api.rb +20 -20
- data/lib/trieve_ruby_client/api/user_api.rb +14 -14
- data/lib/trieve_ruby_client/api_client.rb +1 -1
- data/lib/trieve_ruby_client/api_error.rb +1 -1
- data/lib/trieve_ruby_client/configuration.rb +1 -1
- data/lib/trieve_ruby_client/models/add_chunk_to_group_data.rb +1 -1
- data/lib/trieve_ruby_client/models/api_key_dto.rb +1 -1
- data/lib/trieve_ruby_client/models/auth_query.rb +1 -1
- data/lib/trieve_ruby_client/models/batch_queued_chunk_response.rb +1 -1
- data/lib/trieve_ruby_client/models/bookmark_data.rb +1 -1
- data/lib/trieve_ruby_client/models/bookmark_group_result.rb +1 -1
- data/lib/trieve_ruby_client/models/chat_message_proxy.rb +1 -1
- data/lib/trieve_ruby_client/models/chunk_data.rb +2 -13
- data/lib/trieve_ruby_client/models/chunk_filter.rb +1 -1
- data/lib/trieve_ruby_client/models/chunk_group.rb +1 -1
- data/lib/trieve_ruby_client/models/chunk_group_and_file.rb +1 -1
- data/lib/trieve_ruby_client/models/chunk_metadata.rb +1 -1
- data/lib/trieve_ruby_client/models/chunk_metadata_with_score.rb +1 -1
- data/lib/trieve_ruby_client/models/client_dataset_configuration.rb +18 -2
- data/lib/trieve_ruby_client/models/create_chunk_data.rb +1 -1
- data/lib/trieve_ruby_client/models/create_chunk_group_data.rb +1 -1
- data/lib/trieve_ruby_client/models/create_dataset_request.rb +1 -1
- data/lib/trieve_ruby_client/models/create_message_data.rb +1 -1
- data/lib/trieve_ruby_client/models/create_organization_data.rb +1 -1
- data/lib/trieve_ruby_client/models/create_topic_data.rb +23 -6
- data/lib/trieve_ruby_client/models/dataset.rb +1 -1
- data/lib/trieve_ruby_client/models/dataset_and_usage.rb +1 -1
- data/lib/trieve_ruby_client/models/dataset_dto.rb +1 -1
- data/lib/trieve_ruby_client/models/dataset_usage_count.rb +1 -1
- data/lib/trieve_ruby_client/models/delete_topic_data.rb +1 -1
- data/lib/trieve_ruby_client/models/delete_user_api_key_request.rb +1 -1
- data/lib/trieve_ruby_client/models/edit_message_data.rb +1 -1
- data/lib/trieve_ruby_client/models/error_response_body.rb +1 -1
- data/lib/trieve_ruby_client/models/event.rb +1 -1
- data/lib/trieve_ruby_client/models/event_return.rb +1 -1
- data/lib/trieve_ruby_client/models/field_condition.rb +1 -1
- data/lib/trieve_ruby_client/models/file.rb +1 -1
- data/lib/trieve_ruby_client/models/file_dto.rb +1 -1
- data/lib/trieve_ruby_client/models/generate_chunks_request.rb +1 -1
- data/lib/trieve_ruby_client/models/get_events_data.rb +2 -2
- data/lib/trieve_ruby_client/models/get_groups_for_chunks_data.rb +1 -1
- data/lib/trieve_ruby_client/models/group_data.rb +1 -1
- data/lib/trieve_ruby_client/models/group_score_chunk.rb +1 -1
- data/lib/trieve_ruby_client/models/group_score_slim_chunks.rb +1 -1
- data/lib/trieve_ruby_client/models/invitation_data.rb +1 -1
- data/lib/trieve_ruby_client/models/match_condition.rb +1 -1
- data/lib/trieve_ruby_client/models/message.rb +1 -1
- data/lib/trieve_ruby_client/models/organization.rb +1 -1
- data/lib/trieve_ruby_client/models/organization_usage_count.rb +1 -1
- data/lib/trieve_ruby_client/models/range.rb +1 -1
- data/lib/trieve_ruby_client/models/range_condition.rb +1 -1
- data/lib/trieve_ruby_client/models/recommend_chunks_request.rb +1 -1
- data/lib/trieve_ruby_client/models/recommend_group_chunks_request.rb +1 -1
- data/lib/trieve_ruby_client/models/regenerate_message_data.rb +1 -1
- data/lib/trieve_ruby_client/models/return_queued_chunk.rb +1 -1
- data/lib/trieve_ruby_client/models/score_chunk_dto.rb +1 -1
- data/lib/trieve_ruby_client/models/score_slim_chunks.rb +1 -1
- data/lib/trieve_ruby_client/models/search_chunk_data.rb +1 -1
- data/lib/trieve_ruby_client/models/search_chunk_query_response_body.rb +1 -1
- data/lib/trieve_ruby_client/models/search_over_groups_data.rb +1 -1
- data/lib/trieve_ruby_client/models/search_over_groups_results.rb +1 -1
- data/lib/trieve_ruby_client/models/search_over_groups_slim_results.rb +1 -1
- data/lib/trieve_ruby_client/models/search_slim_chunk_query_response_body.rb +1 -1
- data/lib/trieve_ruby_client/models/search_within_group_data.rb +1 -1
- data/lib/trieve_ruby_client/models/search_within_group_results.rb +1 -1
- data/lib/trieve_ruby_client/models/search_within_group_slim_results.rb +1 -1
- data/lib/trieve_ruby_client/models/set_user_api_key_request.rb +1 -1
- data/lib/trieve_ruby_client/models/set_user_api_key_response.rb +1 -1
- data/lib/trieve_ruby_client/models/single_queued_chunk_response.rb +1 -1
- data/lib/trieve_ruby_client/models/slim_chunk_metadata.rb +1 -1
- data/lib/trieve_ruby_client/models/slim_chunk_metadata_with_score.rb +1 -1
- data/lib/trieve_ruby_client/models/slim_group.rb +1 -1
- data/lib/trieve_ruby_client/models/slim_user.rb +1 -1
- data/lib/trieve_ruby_client/models/stripe_plan.rb +1 -1
- data/lib/trieve_ruby_client/models/suggested_queries_request.rb +1 -1
- data/lib/trieve_ruby_client/models/suggested_queries_response.rb +1 -1
- data/lib/trieve_ruby_client/models/topic.rb +21 -21
- data/lib/trieve_ruby_client/models/update_chunk_by_tracking_id_data.rb +1 -1
- data/lib/trieve_ruby_client/models/update_chunk_data.rb +1 -1
- data/lib/trieve_ruby_client/models/update_chunk_group_data.rb +1 -1
- data/lib/trieve_ruby_client/models/update_dataset_request.rb +1 -1
- data/lib/trieve_ruby_client/models/update_group_by_tracking_id_data.rb +1 -1
- data/lib/trieve_ruby_client/models/update_organization_data.rb +1 -1
- data/lib/trieve_ruby_client/models/update_topic_data.rb +1 -1
- data/lib/trieve_ruby_client/models/update_user_org_role_data.rb +250 -0
- data/lib/trieve_ruby_client/models/upload_file_data.rb +1 -1
- data/lib/trieve_ruby_client/models/upload_file_result.rb +1 -1
- data/lib/trieve_ruby_client/models/user_organization.rb +1 -1
- data/lib/trieve_ruby_client/version.rb +2 -2
- data/lib/trieve_ruby_client.rb +2 -2
- data/openapi-generator.yaml +1 -1
- data/openapi.json +39 -56
- data/spec/models/update_user_org_role_data_spec.rb +48 -0
- data/spec/spec_helper.rb +1 -1
- data/trieve_ruby_client-0.6.9.gem +0 -0
- data/trieve_ruby_client.gemspec +1 -1
- metadata +7 -2
@@ -0,0 +1,250 @@
|
|
1
|
+
=begin
|
2
|
+
#Trieve API
|
3
|
+
|
4
|
+
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 0.7.2
|
7
|
+
Contact: developers@trieve.ai
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.4.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module TrieveRubyClient
|
17
|
+
class UpdateUserOrgRoleData
|
18
|
+
# The id of the organization to update the user for.
|
19
|
+
attr_accessor :organization_id
|
20
|
+
|
21
|
+
# Either 0 (user), 1 (admin), or 2 (owner). If not provided, the current role will be used. The auth'ed user must have a role greater than or equal to the role being assigned.
|
22
|
+
attr_accessor :role
|
23
|
+
|
24
|
+
# The id of the user to update, if not provided, the auth'ed user will be updated. If provided, the auth'ed user must be an admin (1) or owner (2) of the organization.
|
25
|
+
attr_accessor :user_id
|
26
|
+
|
27
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
28
|
+
def self.attribute_map
|
29
|
+
{
|
30
|
+
:'organization_id' => :'organization_id',
|
31
|
+
:'role' => :'role',
|
32
|
+
:'user_id' => :'user_id'
|
33
|
+
}
|
34
|
+
end
|
35
|
+
|
36
|
+
# Returns all the JSON keys this model knows about
|
37
|
+
def self.acceptable_attributes
|
38
|
+
attribute_map.values
|
39
|
+
end
|
40
|
+
|
41
|
+
# Attribute type mapping.
|
42
|
+
def self.openapi_types
|
43
|
+
{
|
44
|
+
:'organization_id' => :'String',
|
45
|
+
:'role' => :'Integer',
|
46
|
+
:'user_id' => :'String'
|
47
|
+
}
|
48
|
+
end
|
49
|
+
|
50
|
+
# List of attributes with nullable: true
|
51
|
+
def self.openapi_nullable
|
52
|
+
Set.new([
|
53
|
+
:'user_id'
|
54
|
+
])
|
55
|
+
end
|
56
|
+
|
57
|
+
# Initializes the object
|
58
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
59
|
+
def initialize(attributes = {})
|
60
|
+
if (!attributes.is_a?(Hash))
|
61
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `TrieveRubyClient::UpdateUserOrgRoleData` initialize method"
|
62
|
+
end
|
63
|
+
|
64
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
65
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
66
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
67
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `TrieveRubyClient::UpdateUserOrgRoleData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
68
|
+
end
|
69
|
+
h[k.to_sym] = v
|
70
|
+
}
|
71
|
+
|
72
|
+
if attributes.key?(:'organization_id')
|
73
|
+
self.organization_id = attributes[:'organization_id']
|
74
|
+
else
|
75
|
+
self.organization_id = nil
|
76
|
+
end
|
77
|
+
|
78
|
+
if attributes.key?(:'role')
|
79
|
+
self.role = attributes[:'role']
|
80
|
+
else
|
81
|
+
self.role = nil
|
82
|
+
end
|
83
|
+
|
84
|
+
if attributes.key?(:'user_id')
|
85
|
+
self.user_id = attributes[:'user_id']
|
86
|
+
end
|
87
|
+
end
|
88
|
+
|
89
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
90
|
+
# @return Array for valid properties with the reasons
|
91
|
+
def list_invalid_properties
|
92
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
93
|
+
invalid_properties = Array.new
|
94
|
+
if @organization_id.nil?
|
95
|
+
invalid_properties.push('invalid value for "organization_id", organization_id cannot be nil.')
|
96
|
+
end
|
97
|
+
|
98
|
+
if @role.nil?
|
99
|
+
invalid_properties.push('invalid value for "role", role cannot be nil.')
|
100
|
+
end
|
101
|
+
|
102
|
+
invalid_properties
|
103
|
+
end
|
104
|
+
|
105
|
+
# Check to see if the all the properties in the model are valid
|
106
|
+
# @return true if the model is valid
|
107
|
+
def valid?
|
108
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
109
|
+
return false if @organization_id.nil?
|
110
|
+
return false if @role.nil?
|
111
|
+
true
|
112
|
+
end
|
113
|
+
|
114
|
+
# Checks equality by comparing each attribute.
|
115
|
+
# @param [Object] Object to be compared
|
116
|
+
def ==(o)
|
117
|
+
return true if self.equal?(o)
|
118
|
+
self.class == o.class &&
|
119
|
+
organization_id == o.organization_id &&
|
120
|
+
role == o.role &&
|
121
|
+
user_id == o.user_id
|
122
|
+
end
|
123
|
+
|
124
|
+
# @see the `==` method
|
125
|
+
# @param [Object] Object to be compared
|
126
|
+
def eql?(o)
|
127
|
+
self == o
|
128
|
+
end
|
129
|
+
|
130
|
+
# Calculates hash code according to all attributes.
|
131
|
+
# @return [Integer] Hash code
|
132
|
+
def hash
|
133
|
+
[organization_id, role, user_id].hash
|
134
|
+
end
|
135
|
+
|
136
|
+
# Builds the object from hash
|
137
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
138
|
+
# @return [Object] Returns the model itself
|
139
|
+
def self.build_from_hash(attributes)
|
140
|
+
return nil unless attributes.is_a?(Hash)
|
141
|
+
attributes = attributes.transform_keys(&:to_sym)
|
142
|
+
transformed_hash = {}
|
143
|
+
openapi_types.each_pair do |key, type|
|
144
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
145
|
+
transformed_hash["#{key}"] = nil
|
146
|
+
elsif type =~ /\AArray<(.*)>/i
|
147
|
+
# check to ensure the input is an array given that the attribute
|
148
|
+
# is documented as an array but the input is not
|
149
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
150
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
151
|
+
end
|
152
|
+
elsif !attributes[attribute_map[key]].nil?
|
153
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
154
|
+
end
|
155
|
+
end
|
156
|
+
new(transformed_hash)
|
157
|
+
end
|
158
|
+
|
159
|
+
# Deserializes the data based on type
|
160
|
+
# @param string type Data type
|
161
|
+
# @param string value Value to be deserialized
|
162
|
+
# @return [Object] Deserialized data
|
163
|
+
def self._deserialize(type, value)
|
164
|
+
case type.to_sym
|
165
|
+
when :Time
|
166
|
+
Time.parse(value)
|
167
|
+
when :Date
|
168
|
+
Date.parse(value)
|
169
|
+
when :String
|
170
|
+
value.to_s
|
171
|
+
when :Integer
|
172
|
+
value.to_i
|
173
|
+
when :Float
|
174
|
+
value.to_f
|
175
|
+
when :Boolean
|
176
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
177
|
+
true
|
178
|
+
else
|
179
|
+
false
|
180
|
+
end
|
181
|
+
when :Object
|
182
|
+
# generic object (usually a Hash), return directly
|
183
|
+
value
|
184
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
185
|
+
inner_type = Regexp.last_match[:inner_type]
|
186
|
+
value.map { |v| _deserialize(inner_type, v) }
|
187
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
188
|
+
k_type = Regexp.last_match[:k_type]
|
189
|
+
v_type = Regexp.last_match[:v_type]
|
190
|
+
{}.tap do |hash|
|
191
|
+
value.each do |k, v|
|
192
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
193
|
+
end
|
194
|
+
end
|
195
|
+
else # model
|
196
|
+
# models (e.g. Pet) or oneOf
|
197
|
+
klass = TrieveRubyClient.const_get(type)
|
198
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
199
|
+
end
|
200
|
+
end
|
201
|
+
|
202
|
+
# Returns the string representation of the object
|
203
|
+
# @return [String] String presentation of the object
|
204
|
+
def to_s
|
205
|
+
to_hash.to_s
|
206
|
+
end
|
207
|
+
|
208
|
+
# to_body is an alias to to_hash (backward compatibility)
|
209
|
+
# @return [Hash] Returns the object in the form of hash
|
210
|
+
def to_body
|
211
|
+
to_hash
|
212
|
+
end
|
213
|
+
|
214
|
+
# Returns the object in the form of hash
|
215
|
+
# @return [Hash] Returns the object in the form of hash
|
216
|
+
def to_hash
|
217
|
+
hash = {}
|
218
|
+
self.class.attribute_map.each_pair do |attr, param|
|
219
|
+
value = self.send(attr)
|
220
|
+
if value.nil?
|
221
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
222
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
223
|
+
end
|
224
|
+
|
225
|
+
hash[param] = _to_hash(value)
|
226
|
+
end
|
227
|
+
hash
|
228
|
+
end
|
229
|
+
|
230
|
+
# Outputs non-array value in the form of hash
|
231
|
+
# For object, use to_hash. Otherwise, just return the value
|
232
|
+
# @param [Object] value Any valid value
|
233
|
+
# @return [Hash] Returns the value in the form of hash
|
234
|
+
def _to_hash(value)
|
235
|
+
if value.is_a?(Array)
|
236
|
+
value.compact.map { |v| _to_hash(v) }
|
237
|
+
elsif value.is_a?(Hash)
|
238
|
+
{}.tap do |hash|
|
239
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
240
|
+
end
|
241
|
+
elsif value.respond_to? :to_hash
|
242
|
+
value.to_hash
|
243
|
+
else
|
244
|
+
value
|
245
|
+
end
|
246
|
+
end
|
247
|
+
|
248
|
+
end
|
249
|
+
|
250
|
+
end
|
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 0.
|
6
|
+
The version of the OpenAPI document: 0.7.2
|
7
7
|
Contact: developers@trieve.ai
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
Generator version: 7.4.0
|
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 0.
|
6
|
+
The version of the OpenAPI document: 0.7.2
|
7
7
|
Contact: developers@trieve.ai
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
Generator version: 7.4.0
|
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 0.
|
6
|
+
The version of the OpenAPI document: 0.7.2
|
7
7
|
Contact: developers@trieve.ai
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
Generator version: 7.4.0
|
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 0.
|
6
|
+
The version of the OpenAPI document: 0.7.2
|
7
7
|
Contact: developers@trieve.ai
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
Generator version: 7.4.0
|
@@ -11,5 +11,5 @@ Generator version: 7.4.0
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
module TrieveRubyClient
|
14
|
-
VERSION = '0.
|
14
|
+
VERSION = '0.7.2'
|
15
15
|
end
|
data/lib/trieve_ruby_client.rb
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 0.
|
6
|
+
The version of the OpenAPI document: 0.7.2
|
7
7
|
Contact: developers@trieve.ai
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
Generator version: 7.4.0
|
@@ -96,7 +96,7 @@ require 'trieve_ruby_client/models/update_dataset_request'
|
|
96
96
|
require 'trieve_ruby_client/models/update_group_by_tracking_id_data'
|
97
97
|
require 'trieve_ruby_client/models/update_organization_data'
|
98
98
|
require 'trieve_ruby_client/models/update_topic_data'
|
99
|
-
require 'trieve_ruby_client/models/
|
99
|
+
require 'trieve_ruby_client/models/update_user_org_role_data'
|
100
100
|
require 'trieve_ruby_client/models/upload_file_data'
|
101
101
|
require 'trieve_ruby_client/models/upload_file_result'
|
102
102
|
require 'trieve_ruby_client/models/user_organization'
|
data/openapi-generator.yaml
CHANGED
data/openapi.json
CHANGED
@@ -12,7 +12,7 @@
|
|
12
12
|
"name": "BSL",
|
13
13
|
"url": "https://github.com/devflowinc/trieve/blob/main/LICENSE.txt"
|
14
14
|
},
|
15
|
-
"version": "0.
|
15
|
+
"version": "0.7.2"
|
16
16
|
},
|
17
17
|
"servers": [
|
18
18
|
{
|
@@ -2558,15 +2558,6 @@
|
|
2558
2558
|
"type": "string",
|
2559
2559
|
"format": "uuid"
|
2560
2560
|
}
|
2561
|
-
},
|
2562
|
-
{
|
2563
|
-
"name": "delete_chunks",
|
2564
|
-
"in": "query",
|
2565
|
-
"description": "Whether or not to delete the chunks associated with the file",
|
2566
|
-
"required": true,
|
2567
|
-
"schema": {
|
2568
|
-
"type": "boolean"
|
2569
|
-
}
|
2570
2561
|
}
|
2571
2562
|
],
|
2572
2563
|
"responses": {
|
@@ -3461,7 +3452,7 @@
|
|
3461
3452
|
"topic"
|
3462
3453
|
],
|
3463
3454
|
"summary": "Create Topic",
|
3464
|
-
"description": "Create Topic\n\nCreate a new chat topic. Topics are attached to a
|
3455
|
+
"description": "Create Topic\n\nCreate a new chat topic. Topics are attached to a owner_id's and act as a coordinator for conversation message history of gen-AI chat sessions.",
|
3465
3456
|
"operationId": "create_topic",
|
3466
3457
|
"parameters": [
|
3467
3458
|
{
|
@@ -3568,23 +3559,22 @@
|
|
3568
3559
|
]
|
3569
3560
|
}
|
3570
3561
|
},
|
3571
|
-
"/api/topic/
|
3562
|
+
"/api/topic/owner/{owner_id}": {
|
3572
3563
|
"get": {
|
3573
3564
|
"tags": [
|
3574
3565
|
"topic"
|
3575
3566
|
],
|
3576
|
-
"summary": "Get All Topics for
|
3577
|
-
"description": "Get All Topics for
|
3578
|
-
"operationId": "
|
3567
|
+
"summary": "Get All Topics for Owner ID",
|
3568
|
+
"description": "Get All Topics for Owner ID\n\nGet all topics belonging to an arbitary owner_id. This is useful for managing message history and chat sessions. It is common to use a browser fingerprint or your user's id as the owner_id.",
|
3569
|
+
"operationId": "get_all_topics_for_owner_id",
|
3579
3570
|
"parameters": [
|
3580
3571
|
{
|
3581
|
-
"name": "
|
3572
|
+
"name": "owner_id",
|
3582
3573
|
"in": "path",
|
3583
|
-
"description": "The
|
3574
|
+
"description": "The owner_id to get topics of; A common approach is to use a browser fingerprint or your user's id",
|
3584
3575
|
"required": true,
|
3585
3576
|
"schema": {
|
3586
|
-
"type": "string"
|
3587
|
-
"format": "uuid"
|
3577
|
+
"type": "string"
|
3588
3578
|
}
|
3589
3579
|
},
|
3590
3580
|
{
|
@@ -3599,7 +3589,7 @@
|
|
3599
3589
|
],
|
3600
3590
|
"responses": {
|
3601
3591
|
"200": {
|
3602
|
-
"description": "All topics belonging to a given
|
3592
|
+
"description": "All topics belonging to a given owner_id",
|
3603
3593
|
"content": {
|
3604
3594
|
"application/json": {
|
3605
3595
|
"schema": {
|
@@ -3612,7 +3602,7 @@
|
|
3612
3602
|
}
|
3613
3603
|
},
|
3614
3604
|
"400": {
|
3615
|
-
"description": "Service error relating to
|
3605
|
+
"description": "Service error relating to getting topics for the owner_id",
|
3616
3606
|
"content": {
|
3617
3607
|
"application/json": {
|
3618
3608
|
"schema": {
|
@@ -3697,22 +3687,15 @@
|
|
3697
3687
|
"content": {
|
3698
3688
|
"application/json": {
|
3699
3689
|
"schema": {
|
3700
|
-
"$ref": "#/components/schemas/
|
3690
|
+
"$ref": "#/components/schemas/UpdateUserOrgRoleData"
|
3701
3691
|
}
|
3702
3692
|
}
|
3703
3693
|
},
|
3704
3694
|
"required": true
|
3705
3695
|
},
|
3706
3696
|
"responses": {
|
3707
|
-
"
|
3708
|
-
"description": "
|
3709
|
-
"content": {
|
3710
|
-
"application/json": {
|
3711
|
-
"schema": {
|
3712
|
-
"$ref": "#/components/schemas/SlimUser"
|
3713
|
-
}
|
3714
|
-
}
|
3715
|
-
}
|
3697
|
+
"204": {
|
3698
|
+
"description": "Confirmation that the user's role was updated"
|
3716
3699
|
},
|
3717
3700
|
"400": {
|
3718
3701
|
"description": "Service error relating to updating the user",
|
@@ -4078,12 +4061,6 @@
|
|
4078
4061
|
"description": "Convert HTML to raw text before processing to avoid adding noise to the vector embeddings. By default this is true. If you are using HTML content that you want to be included in the vector embeddings, set this to false.",
|
4079
4062
|
"nullable": true
|
4080
4063
|
},
|
4081
|
-
"file_id": {
|
4082
|
-
"type": "string",
|
4083
|
-
"format": "uuid",
|
4084
|
-
"description": "File_uuid is the uuid of the file that the chunk is associated with. This is used to associate chunks with files. This is useful for when you want to delete a file and all of its associated chunks.",
|
4085
|
-
"nullable": true
|
4086
|
-
},
|
4087
4064
|
"group_ids": {
|
4088
4065
|
"type": "array",
|
4089
4066
|
"items": {
|
@@ -4532,7 +4509,8 @@
|
|
4532
4509
|
"ClientDatasetConfiguration": {
|
4533
4510
|
"type": "object",
|
4534
4511
|
"required": [
|
4535
|
-
"FILE_NAME_KEY"
|
4512
|
+
"FILE_NAME_KEY",
|
4513
|
+
"IMAGE_METADATA_KEY"
|
4536
4514
|
],
|
4537
4515
|
"properties": {
|
4538
4516
|
"CREATE_CHUNK_FEATURE": {
|
@@ -4557,6 +4535,9 @@
|
|
4557
4535
|
"type": "string",
|
4558
4536
|
"nullable": true
|
4559
4537
|
},
|
4538
|
+
"IMAGE_METADATA_KEY": {
|
4539
|
+
"type": "string"
|
4540
|
+
},
|
4560
4541
|
"IMAGE_RANGE_END_KEY": {
|
4561
4542
|
"type": "string",
|
4562
4543
|
"nullable": true
|
@@ -4586,6 +4567,7 @@
|
|
4586
4567
|
"FILE_NAME_KEY": "file_name_key",
|
4587
4568
|
"FILTER_ITEMS": [],
|
4588
4569
|
"FRONTMATTER_VALS": "frontmatter vals",
|
4570
|
+
"IMAGE_METADATA_KEY": ".image_url",
|
4589
4571
|
"IMAGE_RANGE_END_KEY": "image range end key",
|
4590
4572
|
"IMAGE_RANGE_START_KEY": "image range start key",
|
4591
4573
|
"LINES_BEFORE_SHOW_MORE": 10,
|
@@ -4798,6 +4780,9 @@
|
|
4798
4780
|
},
|
4799
4781
|
"CreateTopicData": {
|
4800
4782
|
"type": "object",
|
4783
|
+
"required": [
|
4784
|
+
"owner_id"
|
4785
|
+
],
|
4801
4786
|
"properties": {
|
4802
4787
|
"first_user_message": {
|
4803
4788
|
"type": "string",
|
@@ -4813,6 +4798,10 @@
|
|
4813
4798
|
"type": "string",
|
4814
4799
|
"description": "The name of the topic. If this is not provided, the topic name is generated from the first_user_message.",
|
4815
4800
|
"nullable": true
|
4801
|
+
},
|
4802
|
+
"owner_id": {
|
4803
|
+
"type": "string",
|
4804
|
+
"description": "The owner_id of the topic. This is typically a browser fingerprint or your user's id. It is used to group topics together for a user."
|
4816
4805
|
}
|
4817
4806
|
}
|
4818
4807
|
},
|
@@ -5348,7 +5337,7 @@
|
|
5348
5337
|
"items": {
|
5349
5338
|
"type": "string"
|
5350
5339
|
},
|
5351
|
-
"description": "The types of events to get. Any combination of file_uploaded, chunk_uploaded, chunk_action_failed, or
|
5340
|
+
"description": "The types of events to get. Any combination of file_uploaded, chunk_uploaded, chunk_action_failed, chunk_updated, or qdrant_index_failed. Leave undefined to get all events.",
|
5352
5341
|
"nullable": true
|
5353
5342
|
},
|
5354
5343
|
"page": {
|
@@ -6844,12 +6833,12 @@
|
|
6844
6833
|
"type": "object",
|
6845
6834
|
"required": [
|
6846
6835
|
"id",
|
6847
|
-
"user_id",
|
6848
6836
|
"name",
|
6849
6837
|
"deleted",
|
6850
6838
|
"created_at",
|
6851
6839
|
"updated_at",
|
6852
|
-
"dataset_id"
|
6840
|
+
"dataset_id",
|
6841
|
+
"owner_id"
|
6853
6842
|
],
|
6854
6843
|
"properties": {
|
6855
6844
|
"created_at": {
|
@@ -6870,13 +6859,12 @@
|
|
6870
6859
|
"name": {
|
6871
6860
|
"type": "string"
|
6872
6861
|
},
|
6862
|
+
"owner_id": {
|
6863
|
+
"type": "string"
|
6864
|
+
},
|
6873
6865
|
"updated_at": {
|
6874
6866
|
"type": "string",
|
6875
6867
|
"format": "date-time"
|
6876
|
-
},
|
6877
|
-
"user_id": {
|
6878
|
-
"type": "string",
|
6879
|
-
"format": "uuid"
|
6880
6868
|
}
|
6881
6869
|
},
|
6882
6870
|
"example": {
|
@@ -6885,8 +6873,8 @@
|
|
6885
6873
|
"deleted": false,
|
6886
6874
|
"id": "e3e3e3e3-e3e3-e3e3-e3e3-e3e3e3e3e3e3",
|
6887
6875
|
"name": "Trieve",
|
6888
|
-
"
|
6889
|
-
"
|
6876
|
+
"owner_id": "e3e3e3e3-e3e3-e3e3-e3e3-e3e3e3e3e3e3",
|
6877
|
+
"updated_at": "2021-01-01T00:00:00"
|
6890
6878
|
}
|
6891
6879
|
},
|
6892
6880
|
"UpdateChunkByTrackingIdData": {
|
@@ -7176,17 +7164,13 @@
|
|
7176
7164
|
}
|
7177
7165
|
}
|
7178
7166
|
},
|
7179
|
-
"
|
7167
|
+
"UpdateUserOrgRoleData": {
|
7180
7168
|
"type": "object",
|
7181
7169
|
"required": [
|
7182
|
-
"organization_id"
|
7170
|
+
"organization_id",
|
7171
|
+
"role"
|
7183
7172
|
],
|
7184
7173
|
"properties": {
|
7185
|
-
"name": {
|
7186
|
-
"type": "string",
|
7187
|
-
"description": "In the sense of a legal name, not a username. The new name to assign to the user, if not provided, the current name will be used.",
|
7188
|
-
"nullable": true
|
7189
|
-
},
|
7190
7174
|
"organization_id": {
|
7191
7175
|
"type": "string",
|
7192
7176
|
"format": "uuid",
|
@@ -7195,8 +7179,7 @@
|
|
7195
7179
|
"role": {
|
7196
7180
|
"type": "integer",
|
7197
7181
|
"format": "int32",
|
7198
|
-
"description": "Either 0 (user), 1 (admin), or 2 (owner). If not provided, the current role will be used. The auth'ed user must have a role greater than or equal to the role being assigned."
|
7199
|
-
"nullable": true
|
7182
|
+
"description": "Either 0 (user), 1 (admin), or 2 (owner). If not provided, the current role will be used. The auth'ed user must have a role greater than or equal to the role being assigned."
|
7200
7183
|
},
|
7201
7184
|
"user_id": {
|
7202
7185
|
"type": "string",
|
@@ -0,0 +1,48 @@
|
|
1
|
+
=begin
|
2
|
+
#Trieve API
|
3
|
+
|
4
|
+
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 0.7.2
|
7
|
+
Contact: developers@trieve.ai
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.4.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
require 'date'
|
16
|
+
|
17
|
+
# Unit tests for TrieveRubyClient::UpdateUserOrgRoleData
|
18
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
19
|
+
# Please update as you see appropriate
|
20
|
+
describe TrieveRubyClient::UpdateUserOrgRoleData do
|
21
|
+
let(:instance) { TrieveRubyClient::UpdateUserOrgRoleData.new }
|
22
|
+
|
23
|
+
describe 'test an instance of UpdateUserOrgRoleData' do
|
24
|
+
it 'should create an instance of UpdateUserOrgRoleData' do
|
25
|
+
# uncomment below to test the instance creation
|
26
|
+
#expect(instance).to be_instance_of(TrieveRubyClient::UpdateUserOrgRoleData)
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
describe 'test attribute "organization_id"' do
|
31
|
+
it 'should work' do
|
32
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
33
|
+
end
|
34
|
+
end
|
35
|
+
|
36
|
+
describe 'test attribute "role"' do
|
37
|
+
it 'should work' do
|
38
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
describe 'test attribute "user_id"' do
|
43
|
+
it 'should work' do
|
44
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
end
|
data/spec/spec_helper.rb
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 0.
|
6
|
+
The version of the OpenAPI document: 0.7.2
|
7
7
|
Contact: developers@trieve.ai
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
Generator version: 7.4.0
|
Binary file
|
data/trieve_ruby_client.gemspec
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
#Trieve OpenAPI Specification. This document describes all of the operations available through the Trieve API.
|
7
7
|
|
8
|
-
The version of the OpenAPI document: 0.
|
8
|
+
The version of the OpenAPI document: 0.7.2
|
9
9
|
Contact: developers@trieve.ai
|
10
10
|
Generated by: https://openapi-generator.tech
|
11
11
|
Generator version: 7.4.0
|