carbon_ruby_sdk 0.2.39 → 0.2.40

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d2401dfba4e022cabaea06fd3c5c88a7ac478ac5844ed523afec47f345661190
4
- data.tar.gz: e5b881ccd3e79f60304ab784f7181b744c3e4d08982bbd5675bdc3448b6ed98e
3
+ metadata.gz: 705280dcd518ae008b5f3c2879d4518babeea313da67dd438ffa517639e7c98a
4
+ data.tar.gz: ae9da6ced1a6d2145161d8871d45d749468e6d046f3b0b79eef114782e0415e6
5
5
  SHA512:
6
- metadata.gz: 9ccf02f74adcd0cdc0af15baa8f812a608b4b4daf491ffce5af307643c44f2e9ef9f32f56361035c92e78d41548019831c0a59d82544098161200552944af5a3
7
- data.tar.gz: 05f1c9282a7df5f52b4463a4bd5b508d7988fa1788ee55e57b936b9e5fb7291f6f5740c4be0d96a0645ba1cc47cbadc2763b0dc1315485832a3829e38b1ce5d8
6
+ metadata.gz: c6df63a620c3d7ded7623ea0a7ed52e4c04249a9f06b1a23ff6ab80eaa83ceca00a8ba869d1b3cbc62473879de99e67d325f6219549d66e74869651f629330ac
7
+ data.tar.gz: b1f3ea0987cb89539e01dac95a13bfbc94d00b201639f53f5d95ca0e98082fd54f405a7ea456071a10dd44a7fa99adc11f575c464327af6bc024c169fa98d58d
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- carbon_ruby_sdk (0.2.39)
4
+ carbon_ruby_sdk (0.2.40)
5
5
  faraday (>= 1.0.1, < 3.0)
6
6
  faraday-multipart (~> 1.0, >= 1.0.4)
7
7
 
data/README.md CHANGED
@@ -6,7 +6,7 @@
6
6
 
7
7
  Connect external data to LLMs, no matter the source.
8
8
 
9
- [![npm](https://img.shields.io/badge/gem-v0.2.39-blue)](https://rubygems.org/gems/carbon_ruby_sdk/versions/0.2.39)
9
+ [![npm](https://img.shields.io/badge/gem-v0.2.40-blue)](https://rubygems.org/gems/carbon_ruby_sdk/versions/0.2.40)
10
10
 
11
11
  </div>
12
12
 
@@ -111,7 +111,7 @@ Connect external data to LLMs, no matter the source.
111
111
  Add to Gemfile:
112
112
 
113
113
  ```ruby
114
- gem 'carbon_ruby_sdk', '~> 0.2.39'
114
+ gem 'carbon_ruby_sdk', '~> 0.2.40'
115
115
  ```
116
116
 
117
117
  ## Getting Started<a id="getting-started"></a>
@@ -50,6 +50,9 @@ module Carbon
50
50
  # Filter by request ID(s) which were used to sync the files
51
51
  attr_accessor :request_ids
52
52
 
53
+ # Filter by upload ID(s) which were used to sync the files
54
+ attr_accessor :upload_ids
55
+
53
56
  # The error message of the file. The query will return files with error messages that contain this string. To search for files with no error message, use an empty string.
54
57
  attr_accessor :sync_error_message
55
58
 
@@ -79,6 +82,7 @@ module Carbon
79
82
  :'include_all_children' => :'include_all_children',
80
83
  :'non_synced_only' => :'non_synced_only',
81
84
  :'request_ids' => :'request_ids',
85
+ :'upload_ids' => :'upload_ids',
82
86
  :'sync_error_message' => :'sync_error_message',
83
87
  :'include_containers' => :'include_containers',
84
88
  :'external_urls' => :'external_urls',
@@ -108,6 +112,7 @@ module Carbon
108
112
  :'include_all_children' => :'Boolean',
109
113
  :'non_synced_only' => :'Boolean',
110
114
  :'request_ids' => :'Array<String>',
115
+ :'upload_ids' => :'Array<String>',
111
116
  :'sync_error_message' => :'String',
112
117
  :'include_containers' => :'Boolean',
113
118
  :'external_urls' => :'Array<String>',
@@ -130,6 +135,7 @@ module Carbon
130
135
  :'embedding_generators',
131
136
  :'root_files_only',
132
137
  :'request_ids',
138
+ :'upload_ids',
133
139
  :'sync_error_message',
134
140
  :'include_containers',
135
141
  :'external_urls',
@@ -228,6 +234,12 @@ module Carbon
228
234
  end
229
235
  end
230
236
 
237
+ if attributes.key?(:'upload_ids')
238
+ if (value = attributes[:'upload_ids']).is_a?(Array)
239
+ self.upload_ids = value
240
+ end
241
+ end
242
+
231
243
  if attributes.key?(:'sync_error_message')
232
244
  self.sync_error_message = attributes[:'sync_error_message']
233
245
  end
@@ -257,6 +269,10 @@ module Carbon
257
269
  invalid_properties.push('invalid value for "request_ids", number of items must be less than or equal to 100.')
258
270
  end
259
271
 
272
+ if !@upload_ids.nil? && @upload_ids.length > 100
273
+ invalid_properties.push('invalid value for "upload_ids", number of items must be less than or equal to 100.')
274
+ end
275
+
260
276
  invalid_properties
261
277
  end
262
278
 
@@ -264,6 +280,7 @@ module Carbon
264
280
  # @return true if the model is valid
265
281
  def valid?
266
282
  return false if !@request_ids.nil? && @request_ids.length > 100
283
+ return false if !@upload_ids.nil? && @upload_ids.length > 100
267
284
  true
268
285
  end
269
286
 
@@ -277,6 +294,16 @@ module Carbon
277
294
  @request_ids = request_ids
278
295
  end
279
296
 
297
+ # Custom attribute writer method with validation
298
+ # @param [Object] upload_ids Value to be assigned
299
+ def upload_ids=(upload_ids)
300
+ if !upload_ids.nil? && upload_ids.length > 100
301
+ fail ArgumentError, 'invalid value for "upload_ids", number of items must be less than or equal to 100.'
302
+ end
303
+
304
+ @upload_ids = upload_ids
305
+ end
306
+
280
307
  # Checks equality by comparing each attribute.
281
308
  # @param [Object] Object to be compared
282
309
  def ==(o)
@@ -296,6 +323,7 @@ module Carbon
296
323
  include_all_children == o.include_all_children &&
297
324
  non_synced_only == o.non_synced_only &&
298
325
  request_ids == o.request_ids &&
326
+ upload_ids == o.upload_ids &&
299
327
  sync_error_message == o.sync_error_message &&
300
328
  include_containers == o.include_containers &&
301
329
  external_urls == o.external_urls &&
@@ -311,7 +339,7 @@ module Carbon
311
339
  # Calculates hash code according to all attributes.
312
340
  # @return [Integer] Hash code
313
341
  def hash
314
- [tags, source, name, tags_v2, ids, external_file_ids, sync_statuses, parent_file_ids, organization_user_data_source_id, embedding_generators, root_files_only, include_all_children, non_synced_only, request_ids, sync_error_message, include_containers, external_urls, file_types_at_source].hash
342
+ [tags, source, name, tags_v2, ids, external_file_ids, sync_statuses, parent_file_ids, organization_user_data_source_id, embedding_generators, root_files_only, include_all_children, non_synced_only, request_ids, upload_ids, sync_error_message, include_containers, external_urls, file_types_at_source].hash
315
343
  end
316
344
 
317
345
  # Builds the object from hash
@@ -114,7 +114,7 @@ module Carbon
114
114
  # Check to see if the all the properties in the model are valid
115
115
  # @return true if the model is valid
116
116
  def valid?
117
- webhook_type_validator = EnumAttributeValidator.new('String', ["ADD", "ALL_UPLOADED_FILES_QUEUED", "CANCEL", "CHECKUP", "DATA_SOURCE_READY", "EMBEDDING_STORAGE_MODIFIED", "FILES_CREATED", "FILES_SKIPPED", "FILE_DELETED", "FILE_ERROR", "FILE_READY", "FILE_STATISTICS_AGGREGATED", "FILE_SYNCING", "FILE_SYNC_LIMIT_REACHED", "MOVED_TO_COLD_STORAGE", "MOVED_TO_HOT_STORAGE", "ORGANIZATION_USER_DELETED", "RATE_LIMIT_ERROR", "REVOKE", "SPARSE_VECTOR_QUEUE_STATUS", "UPDATE", "WEBPAGE_ERROR", "WEBPAGE_READY", "WEBSCRAPE_URLS_READY"])
117
+ webhook_type_validator = EnumAttributeValidator.new('String', ["ADD", "ALL_FILES_PROCESSED", "ALL_UPLOADED_FILES_QUEUED", "CANCEL", "CHECKUP", "DATA_SOURCE_READY", "EMBEDDING_STORAGE_MODIFIED", "FILES_CREATED", "FILES_SKIPPED", "FILE_DELETED", "FILE_ERROR", "FILE_READY", "FILE_STATISTICS_AGGREGATED", "FILE_SYNCING", "FILE_SYNC_LIMIT_REACHED", "MOVED_TO_COLD_STORAGE", "MOVED_TO_HOT_STORAGE", "ORGANIZATION_USER_DELETED", "RATE_LIMIT_ERROR", "REVOKE", "SPARSE_VECTOR_QUEUE_STATUS", "UPDATE", "WEBPAGE_ERROR", "WEBPAGE_READY", "WEBSCRAPE_URLS_READY"])
118
118
  return false unless webhook_type_validator.valid?(@webhook_type)
119
119
  true
120
120
  end
@@ -122,7 +122,7 @@ module Carbon
122
122
  # Custom attribute writer method checking allowed values (enum).
123
123
  # @param [Object] webhook_type Object to be assigned
124
124
  def webhook_type=(webhook_type)
125
- validator = EnumAttributeValidator.new('String', ["ADD", "ALL_UPLOADED_FILES_QUEUED", "CANCEL", "CHECKUP", "DATA_SOURCE_READY", "EMBEDDING_STORAGE_MODIFIED", "FILES_CREATED", "FILES_SKIPPED", "FILE_DELETED", "FILE_ERROR", "FILE_READY", "FILE_STATISTICS_AGGREGATED", "FILE_SYNCING", "FILE_SYNC_LIMIT_REACHED", "MOVED_TO_COLD_STORAGE", "MOVED_TO_HOT_STORAGE", "ORGANIZATION_USER_DELETED", "RATE_LIMIT_ERROR", "REVOKE", "SPARSE_VECTOR_QUEUE_STATUS", "UPDATE", "WEBPAGE_ERROR", "WEBPAGE_READY", "WEBSCRAPE_URLS_READY"])
125
+ validator = EnumAttributeValidator.new('String', ["ADD", "ALL_FILES_PROCESSED", "ALL_UPLOADED_FILES_QUEUED", "CANCEL", "CHECKUP", "DATA_SOURCE_READY", "EMBEDDING_STORAGE_MODIFIED", "FILES_CREATED", "FILES_SKIPPED", "FILE_DELETED", "FILE_ERROR", "FILE_READY", "FILE_STATISTICS_AGGREGATED", "FILE_SYNCING", "FILE_SYNC_LIMIT_REACHED", "MOVED_TO_COLD_STORAGE", "MOVED_TO_HOT_STORAGE", "ORGANIZATION_USER_DELETED", "RATE_LIMIT_ERROR", "REVOKE", "SPARSE_VECTOR_QUEUE_STATUS", "UPDATE", "WEBPAGE_ERROR", "WEBPAGE_READY", "WEBSCRAPE_URLS_READY"])
126
126
  unless validator.valid?(webhook_type)
127
127
  fail ArgumentError, "invalid value for \"webhook_type\", must be one of #{validator.allowable_values}."
128
128
  end
@@ -69,6 +69,8 @@ module Carbon
69
69
 
70
70
  attr_accessor :request_id
71
71
 
72
+ attr_accessor :upload_id
73
+
72
74
  attr_accessor :sync_properties
73
75
 
74
76
  attr_accessor :messages_metadata
@@ -117,6 +119,7 @@ module Carbon
117
119
  :'source_created_at' => :'source_created_at',
118
120
  :'generate_sparse_vectors' => :'generate_sparse_vectors',
119
121
  :'request_id' => :'request_id',
122
+ :'upload_id' => :'upload_id',
120
123
  :'sync_properties' => :'sync_properties',
121
124
  :'messages_metadata' => :'messages_metadata',
122
125
  :'file_contents_deleted' => :'file_contents_deleted',
@@ -165,6 +168,7 @@ module Carbon
165
168
  :'source_created_at' => :'Time',
166
169
  :'generate_sparse_vectors' => :'Boolean',
167
170
  :'request_id' => :'String',
171
+ :'upload_id' => :'String',
168
172
  :'sync_properties' => :'Object',
169
173
  :'messages_metadata' => :'Object',
170
174
  :'file_contents_deleted' => :'Boolean',
@@ -200,6 +204,7 @@ module Carbon
200
204
  :'source_created_at',
201
205
  :'generate_sparse_vectors',
202
206
  :'request_id',
207
+ :'upload_id',
203
208
  :'hot_storage_time_to_live',
204
209
  ])
205
210
  end
@@ -337,6 +342,10 @@ module Carbon
337
342
  self.request_id = attributes[:'request_id']
338
343
  end
339
344
 
345
+ if attributes.key?(:'upload_id')
346
+ self.upload_id = attributes[:'upload_id']
347
+ end
348
+
340
349
  if attributes.key?(:'sync_properties')
341
350
  self.sync_properties = attributes[:'sync_properties']
342
351
  end
@@ -494,6 +503,7 @@ module Carbon
494
503
  source_created_at == o.source_created_at &&
495
504
  generate_sparse_vectors == o.generate_sparse_vectors &&
496
505
  request_id == o.request_id &&
506
+ upload_id == o.upload_id &&
497
507
  sync_properties == o.sync_properties &&
498
508
  messages_metadata == o.messages_metadata &&
499
509
  file_contents_deleted == o.file_contents_deleted &&
@@ -513,7 +523,7 @@ module Carbon
513
523
  # Calculates hash code according to all attributes.
514
524
  # @return [Integer] Hash code
515
525
  def hash
516
- [tags, id, source, organization_id, organization_supplied_user_id, organization_user_data_source_id, external_file_id, external_url, sync_status, sync_error_message, last_sync, file_statistics, file_metadata, embedding_properties, chunk_size, chunk_overlap, chunk_properties, ocr_properties, ocr_job_started_at, name, parent_id, enable_auto_sync, presigned_url, parsed_text_url, additional_presigned_urls, skip_embedding_generation, source_created_at, generate_sparse_vectors, request_id, sync_properties, messages_metadata, file_contents_deleted, supports_cold_storage, hot_storage_time_to_live, embedding_storage_status, created_at, updated_at].hash
526
+ [tags, id, source, organization_id, organization_supplied_user_id, organization_user_data_source_id, external_file_id, external_url, sync_status, sync_error_message, last_sync, file_statistics, file_metadata, embedding_properties, chunk_size, chunk_overlap, chunk_properties, ocr_properties, ocr_job_started_at, name, parent_id, enable_auto_sync, presigned_url, parsed_text_url, additional_presigned_urls, skip_embedding_generation, source_created_at, generate_sparse_vectors, request_id, upload_id, sync_properties, messages_metadata, file_contents_deleted, supports_cold_storage, hot_storage_time_to_live, embedding_storage_status, created_at, updated_at].hash
517
527
  end
518
528
 
519
529
  # Builds the object from hash
@@ -7,5 +7,5 @@ The version of the OpenAPI document: 1.0.0
7
7
  =end
8
8
 
9
9
  module Carbon
10
- VERSION = '0.2.39'
10
+ VERSION = '0.2.40'
11
11
  end
@@ -103,6 +103,12 @@ describe Carbon::OrganizationUserFilesToSyncFilters do
103
103
  end
104
104
  end
105
105
 
106
+ describe 'test attribute "upload_ids"' do
107
+ it 'should work' do
108
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
109
+ end
110
+ end
111
+
106
112
  describe 'test attribute "sync_error_message"' do
107
113
  it 'should work' do
108
114
  # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
@@ -22,7 +22,7 @@ describe Carbon::SentWebhookPayload do
22
22
  describe 'test attribute "webhook_type"' do
23
23
  it 'should work' do
24
24
  # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
25
- # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["ADD", "ALL_UPLOADED_FILES_QUEUED", "CANCEL", "CHECKUP", "DATA_SOURCE_READY", "EMBEDDING_STORAGE_MODIFIED", "FILES_CREATED", "FILES_SKIPPED", "FILE_DELETED", "FILE_ERROR", "FILE_READY", "FILE_STATISTICS_AGGREGATED", "FILE_SYNCING", "FILE_SYNC_LIMIT_REACHED", "MOVED_TO_COLD_STORAGE", "MOVED_TO_HOT_STORAGE", "ORGANIZATION_USER_DELETED", "RATE_LIMIT_ERROR", "REVOKE", "SPARSE_VECTOR_QUEUE_STATUS", "UPDATE", "WEBPAGE_ERROR", "WEBPAGE_READY", "WEBSCRAPE_URLS_READY"])
25
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["ADD", "ALL_FILES_PROCESSED", "ALL_UPLOADED_FILES_QUEUED", "CANCEL", "CHECKUP", "DATA_SOURCE_READY", "EMBEDDING_STORAGE_MODIFIED", "FILES_CREATED", "FILES_SKIPPED", "FILE_DELETED", "FILE_ERROR", "FILE_READY", "FILE_STATISTICS_AGGREGATED", "FILE_SYNCING", "FILE_SYNC_LIMIT_REACHED", "MOVED_TO_COLD_STORAGE", "MOVED_TO_HOT_STORAGE", "ORGANIZATION_USER_DELETED", "RATE_LIMIT_ERROR", "REVOKE", "SPARSE_VECTOR_QUEUE_STATUS", "UPDATE", "WEBPAGE_ERROR", "WEBPAGE_READY", "WEBSCRAPE_URLS_READY"])
26
26
  # validator.allowable_values.each do |value|
27
27
  # expect { instance.webhook_type = value }.not_to raise_error
28
28
  # end
@@ -193,6 +193,12 @@ describe Carbon::UserFile do
193
193
  end
194
194
  end
195
195
 
196
+ describe 'test attribute "upload_id"' do
197
+ it 'should work' do
198
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
199
+ end
200
+ end
201
+
196
202
  describe 'test attribute "sync_properties"' do
197
203
  it 'should work' do
198
204
  # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: carbon_ruby_sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.39
4
+ version: 0.2.40
5
5
  platform: ruby
6
6
  authors:
7
7
  - Konfig
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-10-09 00:00:00.000000000 Z
11
+ date: 2024-10-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday