vellum_ai 1.11.0 → 1.11.7
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/lib/requests.rb +2 -2
- data/lib/types_export.rb +1 -0
- data/lib/vellum_ai/ad_hoc/client.rb +2 -0
- data/lib/vellum_ai/documents/client.rb +12 -4
- data/lib/vellum_ai/types/integration_name.rb +26 -0
- data/lib/vellum_ai/types/runner_config_request.rb +84 -0
- data/lib/vellum_ai/types/vellum_audio.rb +20 -2
- data/lib/vellum_ai/types/vellum_audio_request.rb +20 -2
- data/lib/vellum_ai/types/vellum_code_resource_definition.rb +11 -2
- data/lib/vellum_ai/types/vellum_document.rb +20 -2
- data/lib/vellum_ai/types/vellum_document_request.rb +20 -2
- data/lib/vellum_ai/types/vellum_image.rb +20 -2
- data/lib/vellum_ai/types/vellum_image_request.rb +20 -2
- data/lib/vellum_ai/types/vellum_variable.rb +9 -2
- data/lib/vellum_ai/types/vellum_variable_type.rb +2 -0
- data/lib/vellum_ai/types/vellum_video.rb +20 -2
- data/lib/vellum_ai/types/vellum_video_request.rb +20 -2
- data/lib/vellum_ai/uploaded_files/client.rb +10 -8
- data/lib/vellum_ai/workflows/client.rb +17 -4
- metadata +3 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 53eb525cec2e014edbf9577d5d7b0707370e6cc1bfb62ca9f9ccd350dbaa5ba6
|
|
4
|
+
data.tar.gz: ea4aaf0240913c409b2c7d4e3eb3cb7403be68173ccd6d19496baa66b459b52b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 336ad28b692f1750a6c652c8808c4dbe91e026fbcf1d4682f8868eb6e5334a0c14cd1f56214b51262effd7b209edda31c7ebb50d2dcc63242e5c7883b9c89d4d
|
|
7
|
+
data.tar.gz: 7655b92f055ab5f79f8f985663395c67b4747ab8fb2f759836d275196f79b7cca212ee0ac17bd2e402bca681ac9df134915cb0316a9051e2857b4dee6454ccef
|
data/lib/requests.rb
CHANGED
|
@@ -56,7 +56,7 @@ end
|
|
|
56
56
|
end
|
|
57
57
|
# @return [Hash{String => String}]
|
|
58
58
|
def get_headers
|
|
59
|
-
headers = { "X-Fern-Language": 'Ruby', "X-Fern-SDK-Name": 'vellum_ai', "X-Fern-SDK-Version": '1.11.
|
|
59
|
+
headers = { "X-Fern-Language": 'Ruby', "X-Fern-SDK-Name": 'vellum_ai', "X-Fern-SDK-Version": '1.11.7' }
|
|
60
60
|
headers["X-API-KEY"] = ((@api_key.is_a? Method) ? @api_key.call : @api_key) unless @api_key.nil?
|
|
61
61
|
headers
|
|
62
62
|
end
|
|
@@ -107,7 +107,7 @@ end
|
|
|
107
107
|
end
|
|
108
108
|
# @return [Hash{String => String}]
|
|
109
109
|
def get_headers
|
|
110
|
-
headers = { "X-Fern-Language": 'Ruby', "X-Fern-SDK-Name": 'vellum_ai', "X-Fern-SDK-Version": '1.11.
|
|
110
|
+
headers = { "X-Fern-Language": 'Ruby', "X-Fern-SDK-Name": 'vellum_ai', "X-Fern-SDK-Version": '1.11.7' }
|
|
111
111
|
headers["X-API-KEY"] = ((@api_key.is_a? Method) ? @api_key.call : @api_key) unless @api_key.nil?
|
|
112
112
|
headers
|
|
113
113
|
end
|
data/lib/types_export.rb
CHANGED
|
@@ -450,6 +450,7 @@ require_relative "vellum_ai/types/release_tag_release"
|
|
|
450
450
|
require_relative "vellum_ai/types/release_tag_source"
|
|
451
451
|
require_relative "vellum_ai/types/replace_test_suite_test_case_request"
|
|
452
452
|
require_relative "vellum_ai/types/rich_text_child_block"
|
|
453
|
+
require_relative "vellum_ai/types/runner_config_request"
|
|
453
454
|
require_relative "vellum_ai/types/sandbox_scenario"
|
|
454
455
|
require_relative "vellum_ai/types/scenario_input_string_variable_value"
|
|
455
456
|
require_relative "vellum_ai/types/scenario_input_json_variable_value"
|
|
@@ -33,6 +33,7 @@ module Vellum
|
|
|
33
33
|
# * :extensions (Hash)
|
|
34
34
|
# * :color (String)
|
|
35
35
|
# * :description (String)
|
|
36
|
+
# * :schema (Hash{String => Object})
|
|
36
37
|
# @param parameters [Hash] Request of type Vellum::PromptParameters, as a Hash
|
|
37
38
|
# * :stop (Array<String>)
|
|
38
39
|
# * :temperature (Float)
|
|
@@ -121,6 +122,7 @@ end
|
|
|
121
122
|
# * :extensions (Hash)
|
|
122
123
|
# * :color (String)
|
|
123
124
|
# * :description (String)
|
|
125
|
+
# * :schema (Hash{String => Object})
|
|
124
126
|
# @param parameters [Hash] Request of type Vellum::PromptParameters, as a Hash
|
|
125
127
|
# * :stop (Array<String>)
|
|
126
128
|
# * :temperature (Float)
|
|
@@ -189,13 +189,15 @@ end
|
|
|
189
189
|
# to be re-indexed.
|
|
190
190
|
# @param label [String] A human-friendly name for this document. Typically the filename.
|
|
191
191
|
# @param contents [String, IO]
|
|
192
|
+
# @param url [String] A URL from which the document can be downloaded. Either contents or url must be
|
|
193
|
+
# provided.
|
|
192
194
|
# @param keywords [Array<String>] Optionally include a list of keywords that'll be associated with this document.
|
|
193
195
|
# Used when performing keyword searches.
|
|
194
196
|
# @param metadata [String] A stringified JSON object containing any metadata associated with the document
|
|
195
197
|
# that you'd like to filter upon later.
|
|
196
198
|
# @param request_options [Vellum::RequestOptions]
|
|
197
199
|
# @return [Vellum::UploadDocumentResponse]
|
|
198
|
-
def upload(add_to_index_names: nil, external_id: nil, label:, contents
|
|
200
|
+
def upload(add_to_index_names: nil, external_id: nil, label:, contents: nil, url: nil, keywords: nil, metadata: nil, request_options: nil)
|
|
199
201
|
response = @request_client.conn.post do | req |
|
|
200
202
|
unless request_options&.timeout_in_seconds.nil?
|
|
201
203
|
req.options.timeout = request_options.timeout_in_seconds
|
|
@@ -212,7 +214,9 @@ end
|
|
|
212
214
|
unless request_options.nil? || request_options&.additional_query_parameters.nil?
|
|
213
215
|
req.params = { **(request_options&.additional_query_parameters || {}) }.compact
|
|
214
216
|
end
|
|
215
|
-
req.body = { **(request_options&.additional_body_parameters || {}), add_to_index_names: add_to_index_names, external_id: external_id, label: label, contents:
|
|
217
|
+
req.body = { **(request_options&.additional_body_parameters || {}), add_to_index_names: add_to_index_names, external_id: external_id, label: label, contents: unless contents.nil?
|
|
218
|
+
Vellum::FileUtilities.as_faraday_multipart(file_like: contents)
|
|
219
|
+
end, url: url, keywords: keywords, metadata: metadata }.compact
|
|
216
220
|
req.url "#{@request_client.get_url(environment: Documents, request_options: request_options)}/v1/upload-document"
|
|
217
221
|
end
|
|
218
222
|
Vellum::UploadDocumentResponse.from_json(json_object: response.body)
|
|
@@ -402,13 +406,15 @@ end
|
|
|
402
406
|
# to be re-indexed.
|
|
403
407
|
# @param label [String] A human-friendly name for this document. Typically the filename.
|
|
404
408
|
# @param contents [String, IO]
|
|
409
|
+
# @param url [String] A URL from which the document can be downloaded. Either contents or url must be
|
|
410
|
+
# provided.
|
|
405
411
|
# @param keywords [Array<String>] Optionally include a list of keywords that'll be associated with this document.
|
|
406
412
|
# Used when performing keyword searches.
|
|
407
413
|
# @param metadata [String] A stringified JSON object containing any metadata associated with the document
|
|
408
414
|
# that you'd like to filter upon later.
|
|
409
415
|
# @param request_options [Vellum::RequestOptions]
|
|
410
416
|
# @return [Vellum::UploadDocumentResponse]
|
|
411
|
-
def upload(add_to_index_names: nil, external_id: nil, label:, contents
|
|
417
|
+
def upload(add_to_index_names: nil, external_id: nil, label:, contents: nil, url: nil, keywords: nil, metadata: nil, request_options: nil)
|
|
412
418
|
Async do
|
|
413
419
|
response = @request_client.conn.post do | req |
|
|
414
420
|
unless request_options&.timeout_in_seconds.nil?
|
|
@@ -426,7 +432,9 @@ end
|
|
|
426
432
|
unless request_options.nil? || request_options&.additional_query_parameters.nil?
|
|
427
433
|
req.params = { **(request_options&.additional_query_parameters || {}) }.compact
|
|
428
434
|
end
|
|
429
|
-
req.body = { **(request_options&.additional_body_parameters || {}), add_to_index_names: add_to_index_names, external_id: external_id, label: label, contents:
|
|
435
|
+
req.body = { **(request_options&.additional_body_parameters || {}), add_to_index_names: add_to_index_names, external_id: external_id, label: label, contents: unless contents.nil?
|
|
436
|
+
Vellum::FileUtilities.as_faraday_multipart(file_like: contents)
|
|
437
|
+
end, url: url, keywords: keywords, metadata: metadata }.compact
|
|
430
438
|
req.url "#{@request_client.get_url(environment: Documents, request_options: request_options)}/v1/upload-document"
|
|
431
439
|
end
|
|
432
440
|
Vellum::UploadDocumentResponse.from_json(json_object: response.body)
|
|
@@ -10,19 +10,29 @@ module Vellum
|
|
|
10
10
|
# * `CODA` - Coda
|
|
11
11
|
# * `HUBSPOT` - Hubspot
|
|
12
12
|
# * `INTERCOM` - Intercom
|
|
13
|
+
# * `INSTAGRAM` - Instagram
|
|
13
14
|
# * `LINEAR` - Linear
|
|
14
15
|
# * `LINKUP` - Linkup
|
|
15
16
|
# * `LISTENNOTES` - Listen Notes
|
|
16
17
|
# * `LMNT` - LMNT
|
|
17
18
|
# * `LINKEDIN` - LinkedIn
|
|
18
19
|
# * `MAILCHIMP` - Mailchimp
|
|
20
|
+
# * `MIRO` - Miro
|
|
19
21
|
# * `MEM0` - Mem0
|
|
22
|
+
# * `MONDAY` - Monday
|
|
20
23
|
# * `NEON` - Neon
|
|
21
24
|
# * `GITHUB` - Github
|
|
22
25
|
# * `GOOGLE_SHEETS` - Google Sheets
|
|
23
26
|
# * `GOOGLE_CALENDAR` - Google Calendar
|
|
24
27
|
# * `GOOGLE_DRIVE` - Google Drive
|
|
25
28
|
# * `GMAIL` - Gmail
|
|
29
|
+
# * `GOOGLE_ADS` - Google Ads
|
|
30
|
+
# * `GOOGLE_ANALYTICS` - Google Analytics
|
|
31
|
+
# * `GOOGLE_DOCS` - Google Docs
|
|
32
|
+
# * `GOOGLE_PHOTOS` - Google Photos
|
|
33
|
+
# * `GOOGLE_SEARCH_CONSOLE` - Google Search Console
|
|
34
|
+
# * `GOOGLE_SLIDES` - Google Slides
|
|
35
|
+
# * `GOOGLE_TASKS` - Google Tasks
|
|
26
36
|
# * `ACCULYNX` - AccuLynx
|
|
27
37
|
# * `AFFINITY` - Affinity
|
|
28
38
|
# * `AGENCYZOOM` - AgencyZoom
|
|
@@ -62,16 +72,19 @@ module Vellum
|
|
|
62
72
|
# * `SERPAPI` - Serp Api
|
|
63
73
|
# * `SHARE_POINT` - SharePoint
|
|
64
74
|
# * `SHORTCUT` - Shortcut
|
|
75
|
+
# * `SPOTIFY` - Spotify
|
|
65
76
|
# * `STRIPE` - Stripe
|
|
66
77
|
# * `SUPABASE` - Supabase
|
|
67
78
|
# * `TAVILY` - Tavily
|
|
68
79
|
# * `TELEGRAM` - Telegram
|
|
80
|
+
# * `TODOIST` - Todoist
|
|
69
81
|
# * `WEBFLOW` - Webflow
|
|
70
82
|
# * `YOUSEARCH` - You Search
|
|
71
83
|
# * `ZENDESK` - Zendesk
|
|
72
84
|
# * `ZENROWS` - ZenRows
|
|
73
85
|
# * `DROPBOX` - Dropbox
|
|
74
86
|
# * `EVENTBRITE` - Eventbrite
|
|
87
|
+
# * `FACEBOOK` - Facebook
|
|
75
88
|
# * `CONFLUENCE` - Confluence
|
|
76
89
|
# * `COINBASE` - Coinbase
|
|
77
90
|
# * `DISCORD` - Discord
|
|
@@ -88,19 +101,29 @@ module Vellum
|
|
|
88
101
|
CODA = "CODA"
|
|
89
102
|
HUBSPOT = "HUBSPOT"
|
|
90
103
|
INTERCOM = "INTERCOM"
|
|
104
|
+
INSTAGRAM = "INSTAGRAM"
|
|
91
105
|
LINEAR = "LINEAR"
|
|
92
106
|
LINKUP = "LINKUP"
|
|
93
107
|
LISTENNOTES = "LISTENNOTES"
|
|
94
108
|
LMNT = "LMNT"
|
|
95
109
|
LINKEDIN = "LINKEDIN"
|
|
96
110
|
MAILCHIMP = "MAILCHIMP"
|
|
111
|
+
MIRO = "MIRO"
|
|
97
112
|
MEM_0 = "MEM0"
|
|
113
|
+
MONDAY = "MONDAY"
|
|
98
114
|
NEON = "NEON"
|
|
99
115
|
GITHUB = "GITHUB"
|
|
100
116
|
GOOGLE_SHEETS = "GOOGLE_SHEETS"
|
|
101
117
|
GOOGLE_CALENDAR = "GOOGLE_CALENDAR"
|
|
102
118
|
GOOGLE_DRIVE = "GOOGLE_DRIVE"
|
|
103
119
|
GMAIL = "GMAIL"
|
|
120
|
+
GOOGLE_ADS = "GOOGLE_ADS"
|
|
121
|
+
GOOGLE_ANALYTICS = "GOOGLE_ANALYTICS"
|
|
122
|
+
GOOGLE_DOCS = "GOOGLE_DOCS"
|
|
123
|
+
GOOGLE_PHOTOS = "GOOGLE_PHOTOS"
|
|
124
|
+
GOOGLE_SEARCH_CONSOLE = "GOOGLE_SEARCH_CONSOLE"
|
|
125
|
+
GOOGLE_SLIDES = "GOOGLE_SLIDES"
|
|
126
|
+
GOOGLE_TASKS = "GOOGLE_TASKS"
|
|
104
127
|
ACCULYNX = "ACCULYNX"
|
|
105
128
|
AFFINITY = "AFFINITY"
|
|
106
129
|
AGENCYZOOM = "AGENCYZOOM"
|
|
@@ -140,16 +163,19 @@ module Vellum
|
|
|
140
163
|
SERPAPI = "SERPAPI"
|
|
141
164
|
SHARE_POINT = "SHARE_POINT"
|
|
142
165
|
SHORTCUT = "SHORTCUT"
|
|
166
|
+
SPOTIFY = "SPOTIFY"
|
|
143
167
|
STRIPE = "STRIPE"
|
|
144
168
|
SUPABASE = "SUPABASE"
|
|
145
169
|
TAVILY = "TAVILY"
|
|
146
170
|
TELEGRAM = "TELEGRAM"
|
|
171
|
+
TODOIST = "TODOIST"
|
|
147
172
|
WEBFLOW = "WEBFLOW"
|
|
148
173
|
YOUSEARCH = "YOUSEARCH"
|
|
149
174
|
ZENDESK = "ZENDESK"
|
|
150
175
|
ZENROWS = "ZENROWS"
|
|
151
176
|
DROPBOX = "DROPBOX"
|
|
152
177
|
EVENTBRITE = "EVENTBRITE"
|
|
178
|
+
FACEBOOK = "FACEBOOK"
|
|
153
179
|
CONFLUENCE = "CONFLUENCE"
|
|
154
180
|
COINBASE = "COINBASE"
|
|
155
181
|
DISCORD = "DISCORD"
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
require "ostruct"
|
|
3
|
+
require "json"
|
|
4
|
+
|
|
5
|
+
module Vellum
|
|
6
|
+
class RunnerConfigRequest
|
|
7
|
+
# @return [String]
|
|
8
|
+
attr_reader :container_image_name
|
|
9
|
+
# @return [String]
|
|
10
|
+
attr_reader :container_image_tag
|
|
11
|
+
# @return [String]
|
|
12
|
+
attr_reader :codegen_version
|
|
13
|
+
# @return [String]
|
|
14
|
+
attr_reader :sdk_version
|
|
15
|
+
# @return [Boolean]
|
|
16
|
+
attr_reader :is_deployment_inlining_enabled
|
|
17
|
+
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
|
18
|
+
attr_reader :additional_properties
|
|
19
|
+
# @return [Object]
|
|
20
|
+
attr_reader :_field_set
|
|
21
|
+
protected :_field_set
|
|
22
|
+
|
|
23
|
+
OMIT = Object.new
|
|
24
|
+
|
|
25
|
+
# @param container_image_name [String]
|
|
26
|
+
# @param container_image_tag [String]
|
|
27
|
+
# @param codegen_version [String]
|
|
28
|
+
# @param sdk_version [String]
|
|
29
|
+
# @param is_deployment_inlining_enabled [Boolean]
|
|
30
|
+
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
31
|
+
# @return [Vellum::RunnerConfigRequest]
|
|
32
|
+
def initialize(container_image_name: OMIT, container_image_tag: OMIT, codegen_version: OMIT, sdk_version: OMIT, is_deployment_inlining_enabled: OMIT, additional_properties: nil)
|
|
33
|
+
@container_image_name = container_image_name if container_image_name != OMIT
|
|
34
|
+
@container_image_tag = container_image_tag if container_image_tag != OMIT
|
|
35
|
+
@codegen_version = codegen_version if codegen_version != OMIT
|
|
36
|
+
@sdk_version = sdk_version if sdk_version != OMIT
|
|
37
|
+
@is_deployment_inlining_enabled = is_deployment_inlining_enabled if is_deployment_inlining_enabled != OMIT
|
|
38
|
+
@additional_properties = additional_properties
|
|
39
|
+
@_field_set = { "container_image_name": container_image_name, "container_image_tag": container_image_tag, "codegen_version": codegen_version, "sdk_version": sdk_version, "is_deployment_inlining_enabled": is_deployment_inlining_enabled }.reject do | _k, v |
|
|
40
|
+
v == OMIT
|
|
41
|
+
end
|
|
42
|
+
end
|
|
43
|
+
# Deserialize a JSON object to an instance of RunnerConfigRequest
|
|
44
|
+
#
|
|
45
|
+
# @param json_object [String]
|
|
46
|
+
# @return [Vellum::RunnerConfigRequest]
|
|
47
|
+
def self.from_json(json_object:)
|
|
48
|
+
struct = JSON.parse(json_object, object_class: OpenStruct)
|
|
49
|
+
parsed_json = JSON.parse(json_object)
|
|
50
|
+
container_image_name = parsed_json["container_image_name"]
|
|
51
|
+
container_image_tag = parsed_json["container_image_tag"]
|
|
52
|
+
codegen_version = parsed_json["codegen_version"]
|
|
53
|
+
sdk_version = parsed_json["sdk_version"]
|
|
54
|
+
is_deployment_inlining_enabled = parsed_json["is_deployment_inlining_enabled"]
|
|
55
|
+
new(
|
|
56
|
+
container_image_name: container_image_name,
|
|
57
|
+
container_image_tag: container_image_tag,
|
|
58
|
+
codegen_version: codegen_version,
|
|
59
|
+
sdk_version: sdk_version,
|
|
60
|
+
is_deployment_inlining_enabled: is_deployment_inlining_enabled,
|
|
61
|
+
additional_properties: struct
|
|
62
|
+
)
|
|
63
|
+
end
|
|
64
|
+
# Serialize an instance of RunnerConfigRequest to a JSON object
|
|
65
|
+
#
|
|
66
|
+
# @return [String]
|
|
67
|
+
def to_json
|
|
68
|
+
@_field_set&.to_json
|
|
69
|
+
end
|
|
70
|
+
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
|
71
|
+
# hash and check each fields type against the current object's property
|
|
72
|
+
# definitions.
|
|
73
|
+
#
|
|
74
|
+
# @param obj [Object]
|
|
75
|
+
# @return [Void]
|
|
76
|
+
def self.validate_raw(obj:)
|
|
77
|
+
obj.container_image_name&.is_a?(String) != false || raise("Passed value for field obj.container_image_name is not the expected type, validation failed.")
|
|
78
|
+
obj.container_image_tag&.is_a?(String) != false || raise("Passed value for field obj.container_image_tag is not the expected type, validation failed.")
|
|
79
|
+
obj.codegen_version&.is_a?(String) != false || raise("Passed value for field obj.codegen_version is not the expected type, validation failed.")
|
|
80
|
+
obj.sdk_version&.is_a?(String) != false || raise("Passed value for field obj.sdk_version is not the expected type, validation failed.")
|
|
81
|
+
obj.is_deployment_inlining_enabled&.is_a?(Boolean) != false || raise("Passed value for field obj.is_deployment_inlining_enabled is not the expected type, validation failed.")
|
|
82
|
+
end
|
|
83
|
+
end
|
|
84
|
+
end
|
|
@@ -4,7 +4,16 @@ require "json"
|
|
|
4
4
|
|
|
5
5
|
module Vellum
|
|
6
6
|
class VellumAudio
|
|
7
|
-
# @return [String]
|
|
7
|
+
# @return [String] The reference to the source data. This can be one of the following formats:
|
|
8
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
9
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
10
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
11
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
12
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
13
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
14
|
+
# given its ID. See
|
|
15
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
16
|
+
# details.
|
|
8
17
|
attr_reader :src
|
|
9
18
|
# @return [Hash{String => Object}]
|
|
10
19
|
attr_reader :metadata
|
|
@@ -16,7 +25,16 @@ module Vellum
|
|
|
16
25
|
|
|
17
26
|
OMIT = Object.new
|
|
18
27
|
|
|
19
|
-
# @param src [String]
|
|
28
|
+
# @param src [String] The reference to the source data. This can be one of the following formats:
|
|
29
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
30
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
31
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
32
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
33
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
34
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
35
|
+
# given its ID. See
|
|
36
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
37
|
+
# details.
|
|
20
38
|
# @param metadata [Hash{String => Object}]
|
|
21
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
22
40
|
# @return [Vellum::VellumAudio]
|
|
@@ -4,7 +4,16 @@ require "json"
|
|
|
4
4
|
|
|
5
5
|
module Vellum
|
|
6
6
|
class VellumAudioRequest
|
|
7
|
-
# @return [String]
|
|
7
|
+
# @return [String] The reference to the source data. This can be one of the following formats:
|
|
8
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
9
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
10
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
11
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
12
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
13
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
14
|
+
# given its ID. See
|
|
15
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
16
|
+
# details.
|
|
8
17
|
attr_reader :src
|
|
9
18
|
# @return [Hash{String => Object}]
|
|
10
19
|
attr_reader :metadata
|
|
@@ -16,7 +25,16 @@ module Vellum
|
|
|
16
25
|
|
|
17
26
|
OMIT = Object.new
|
|
18
27
|
|
|
19
|
-
# @param src [String]
|
|
28
|
+
# @param src [String] The reference to the source data. This can be one of the following formats:
|
|
29
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
30
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
31
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
32
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
33
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
34
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
35
|
+
# given its ID. See
|
|
36
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
37
|
+
# details.
|
|
20
38
|
# @param metadata [Hash{String => Object}]
|
|
21
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
22
40
|
# @return [Vellum::VellumAudioRequest]
|
|
@@ -8,6 +8,8 @@ module Vellum
|
|
|
8
8
|
attr_reader :name
|
|
9
9
|
# @return [Array<String>] The module that this resource is defined in.
|
|
10
10
|
attr_reader :module_
|
|
11
|
+
# @return [Boolean] Whether this node should be excluded from monitoring views.
|
|
12
|
+
attr_reader :exclude_from_monitoring
|
|
11
13
|
# @return [String]
|
|
12
14
|
attr_reader :id
|
|
13
15
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
|
@@ -20,15 +22,19 @@ module Vellum
|
|
|
20
22
|
|
|
21
23
|
# @param name [String]
|
|
22
24
|
# @param module_ [Array<String>] The module that this resource is defined in.
|
|
25
|
+
# @param exclude_from_monitoring [Boolean] Whether this node should be excluded from monitoring views.
|
|
23
26
|
# @param id [String]
|
|
24
27
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
25
28
|
# @return [Vellum::VellumCodeResourceDefinition]
|
|
26
|
-
def initialize(name:, module_:, id:, additional_properties: nil)
|
|
29
|
+
def initialize(name:, module_:, exclude_from_monitoring: OMIT, id:, additional_properties: nil)
|
|
27
30
|
@name = name
|
|
28
31
|
@module_ = module_
|
|
32
|
+
@exclude_from_monitoring = exclude_from_monitoring if exclude_from_monitoring != OMIT
|
|
29
33
|
@id = id
|
|
30
34
|
@additional_properties = additional_properties
|
|
31
|
-
@_field_set = { "name": name, "module": module_, "id": id }
|
|
35
|
+
@_field_set = { "name": name, "module": module_, "exclude_from_monitoring": exclude_from_monitoring, "id": id }.reject do | _k, v |
|
|
36
|
+
v == OMIT
|
|
37
|
+
end
|
|
32
38
|
end
|
|
33
39
|
# Deserialize a JSON object to an instance of VellumCodeResourceDefinition
|
|
34
40
|
#
|
|
@@ -39,10 +45,12 @@ module Vellum
|
|
|
39
45
|
parsed_json = JSON.parse(json_object)
|
|
40
46
|
name = parsed_json["name"]
|
|
41
47
|
module_ = parsed_json["module"]
|
|
48
|
+
exclude_from_monitoring = parsed_json["exclude_from_monitoring"]
|
|
42
49
|
id = parsed_json["id"]
|
|
43
50
|
new(
|
|
44
51
|
name: name,
|
|
45
52
|
module_: module_,
|
|
53
|
+
exclude_from_monitoring: exclude_from_monitoring,
|
|
46
54
|
id: id,
|
|
47
55
|
additional_properties: struct
|
|
48
56
|
)
|
|
@@ -62,6 +70,7 @@ module Vellum
|
|
|
62
70
|
def self.validate_raw(obj:)
|
|
63
71
|
obj.name.is_a?(String) != false || raise("Passed value for field obj.name is not the expected type, validation failed.")
|
|
64
72
|
obj.module_.is_a?(Array) != false || raise("Passed value for field obj.module_ is not the expected type, validation failed.")
|
|
73
|
+
obj.exclude_from_monitoring&.is_a?(Boolean) != false || raise("Passed value for field obj.exclude_from_monitoring is not the expected type, validation failed.")
|
|
65
74
|
obj.id.is_a?(String) != false || raise("Passed value for field obj.id is not the expected type, validation failed.")
|
|
66
75
|
end
|
|
67
76
|
end
|
|
@@ -4,7 +4,16 @@ require "json"
|
|
|
4
4
|
|
|
5
5
|
module Vellum
|
|
6
6
|
class VellumDocument
|
|
7
|
-
# @return [String]
|
|
7
|
+
# @return [String] The reference to the source data. This can be one of the following formats:
|
|
8
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
9
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
10
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
11
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
12
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
13
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
14
|
+
# given its ID. See
|
|
15
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
16
|
+
# details.
|
|
8
17
|
attr_reader :src
|
|
9
18
|
# @return [Hash{String => Object}]
|
|
10
19
|
attr_reader :metadata
|
|
@@ -16,7 +25,16 @@ module Vellum
|
|
|
16
25
|
|
|
17
26
|
OMIT = Object.new
|
|
18
27
|
|
|
19
|
-
# @param src [String]
|
|
28
|
+
# @param src [String] The reference to the source data. This can be one of the following formats:
|
|
29
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
30
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
31
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
32
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
33
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
34
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
35
|
+
# given its ID. See
|
|
36
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
37
|
+
# details.
|
|
20
38
|
# @param metadata [Hash{String => Object}]
|
|
21
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
22
40
|
# @return [Vellum::VellumDocument]
|
|
@@ -4,7 +4,16 @@ require "json"
|
|
|
4
4
|
|
|
5
5
|
module Vellum
|
|
6
6
|
class VellumDocumentRequest
|
|
7
|
-
# @return [String]
|
|
7
|
+
# @return [String] The reference to the source data. This can be one of the following formats:
|
|
8
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
9
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
10
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
11
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
12
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
13
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
14
|
+
# given its ID. See
|
|
15
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
16
|
+
# details.
|
|
8
17
|
attr_reader :src
|
|
9
18
|
# @return [Hash{String => Object}]
|
|
10
19
|
attr_reader :metadata
|
|
@@ -16,7 +25,16 @@ module Vellum
|
|
|
16
25
|
|
|
17
26
|
OMIT = Object.new
|
|
18
27
|
|
|
19
|
-
# @param src [String]
|
|
28
|
+
# @param src [String] The reference to the source data. This can be one of the following formats:
|
|
29
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
30
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
31
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
32
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
33
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
34
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
35
|
+
# given its ID. See
|
|
36
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
37
|
+
# details.
|
|
20
38
|
# @param metadata [Hash{String => Object}]
|
|
21
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
22
40
|
# @return [Vellum::VellumDocumentRequest]
|
|
@@ -4,7 +4,16 @@ require "json"
|
|
|
4
4
|
|
|
5
5
|
module Vellum
|
|
6
6
|
class VellumImage
|
|
7
|
-
# @return [String]
|
|
7
|
+
# @return [String] The reference to the source data. This can be one of the following formats:
|
|
8
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
9
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
10
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
11
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
12
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
13
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
14
|
+
# given its ID. See
|
|
15
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
16
|
+
# details.
|
|
8
17
|
attr_reader :src
|
|
9
18
|
# @return [Hash{String => Object}]
|
|
10
19
|
attr_reader :metadata
|
|
@@ -16,7 +25,16 @@ module Vellum
|
|
|
16
25
|
|
|
17
26
|
OMIT = Object.new
|
|
18
27
|
|
|
19
|
-
# @param src [String]
|
|
28
|
+
# @param src [String] The reference to the source data. This can be one of the following formats:
|
|
29
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
30
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
31
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
32
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
33
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
34
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
35
|
+
# given its ID. See
|
|
36
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
37
|
+
# details.
|
|
20
38
|
# @param metadata [Hash{String => Object}]
|
|
21
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
22
40
|
# @return [Vellum::VellumImage]
|
|
@@ -4,7 +4,16 @@ require "json"
|
|
|
4
4
|
|
|
5
5
|
module Vellum
|
|
6
6
|
class VellumImageRequest
|
|
7
|
-
# @return [String]
|
|
7
|
+
# @return [String] The reference to the source data. This can be one of the following formats:
|
|
8
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
9
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
10
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
11
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
12
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
13
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
14
|
+
# given its ID. See
|
|
15
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
16
|
+
# details.
|
|
8
17
|
attr_reader :src
|
|
9
18
|
# @return [Hash{String => Object}]
|
|
10
19
|
attr_reader :metadata
|
|
@@ -16,7 +25,16 @@ module Vellum
|
|
|
16
25
|
|
|
17
26
|
OMIT = Object.new
|
|
18
27
|
|
|
19
|
-
# @param src [String]
|
|
28
|
+
# @param src [String] The reference to the source data. This can be one of the following formats:
|
|
29
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
30
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
31
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
32
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
33
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
34
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
35
|
+
# given its ID. See
|
|
36
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
37
|
+
# details.
|
|
20
38
|
# @param metadata [Hash{String => Object}]
|
|
21
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
22
40
|
# @return [Vellum::VellumImageRequest]
|
|
@@ -19,6 +19,8 @@ module Vellum
|
|
|
19
19
|
attr_reader :default
|
|
20
20
|
# @return [Vellum::VellumVariableExtensions]
|
|
21
21
|
attr_reader :extensions
|
|
22
|
+
# @return [Hash{String => Object}]
|
|
23
|
+
attr_reader :schema
|
|
22
24
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
|
23
25
|
attr_reader :additional_properties
|
|
24
26
|
# @return [Object]
|
|
@@ -33,17 +35,19 @@ module Vellum
|
|
|
33
35
|
# @param required [Boolean]
|
|
34
36
|
# @param default [Vellum::VellumValue]
|
|
35
37
|
# @param extensions [Vellum::VellumVariableExtensions]
|
|
38
|
+
# @param schema [Hash{String => Object}]
|
|
36
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
37
40
|
# @return [Vellum::VellumVariable]
|
|
38
|
-
def initialize(id:, key:, type:, required: OMIT, default: OMIT, extensions: OMIT, additional_properties: nil)
|
|
41
|
+
def initialize(id:, key:, type:, required: OMIT, default: OMIT, extensions: OMIT, schema: OMIT, additional_properties: nil)
|
|
39
42
|
@id = id
|
|
40
43
|
@key = key
|
|
41
44
|
@type = type
|
|
42
45
|
@required = required if required != OMIT
|
|
43
46
|
@default = default if default != OMIT
|
|
44
47
|
@extensions = extensions if extensions != OMIT
|
|
48
|
+
@schema = schema if schema != OMIT
|
|
45
49
|
@additional_properties = additional_properties
|
|
46
|
-
@_field_set = { "id": id, "key": key, "type": type, "required": required, "default": default, "extensions": extensions }.reject do | _k, v |
|
|
50
|
+
@_field_set = { "id": id, "key": key, "type": type, "required": required, "default": default, "extensions": extensions, "schema": schema }.reject do | _k, v |
|
|
47
51
|
v == OMIT
|
|
48
52
|
end
|
|
49
53
|
end
|
|
@@ -70,6 +74,7 @@ end
|
|
|
70
74
|
else
|
|
71
75
|
extensions = nil
|
|
72
76
|
end
|
|
77
|
+
schema = parsed_json["schema"]
|
|
73
78
|
new(
|
|
74
79
|
id: id,
|
|
75
80
|
key: key,
|
|
@@ -77,6 +82,7 @@ end
|
|
|
77
82
|
required: required,
|
|
78
83
|
default: default,
|
|
79
84
|
extensions: extensions,
|
|
85
|
+
schema: schema,
|
|
80
86
|
additional_properties: struct
|
|
81
87
|
)
|
|
82
88
|
end
|
|
@@ -99,6 +105,7 @@ end
|
|
|
99
105
|
obj.required&.is_a?(Boolean) != false || raise("Passed value for field obj.required is not the expected type, validation failed.")
|
|
100
106
|
obj.default.nil? || Vellum::VellumValue.validate_raw(obj: obj.default)
|
|
101
107
|
obj.extensions.nil? || Vellum::VellumVariableExtensions.validate_raw(obj: obj.extensions)
|
|
108
|
+
obj.schema&.is_a?(Hash) != false || raise("Passed value for field obj.schema is not the expected type, validation failed.")
|
|
102
109
|
end
|
|
103
110
|
end
|
|
104
111
|
end
|
|
@@ -15,6 +15,7 @@ module Vellum
|
|
|
15
15
|
# * `DOCUMENT` - DOCUMENT
|
|
16
16
|
# * `NULL` - NULL
|
|
17
17
|
# * `THINKING` - THINKING
|
|
18
|
+
# * `REFERENCE` - REFERENCE
|
|
18
19
|
class VellumVariableType
|
|
19
20
|
|
|
20
21
|
STRING = "STRING"
|
|
@@ -31,6 +32,7 @@ module Vellum
|
|
|
31
32
|
DOCUMENT = "DOCUMENT"
|
|
32
33
|
NULL = "NULL"
|
|
33
34
|
THINKING = "THINKING"
|
|
35
|
+
REFERENCE = "REFERENCE"
|
|
34
36
|
|
|
35
37
|
end
|
|
36
38
|
end
|
|
@@ -4,7 +4,16 @@ require "json"
|
|
|
4
4
|
|
|
5
5
|
module Vellum
|
|
6
6
|
class VellumVideo
|
|
7
|
-
# @return [String]
|
|
7
|
+
# @return [String] The reference to the source data. This can be one of the following formats:
|
|
8
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
9
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
10
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
11
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
12
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
13
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
14
|
+
# given its ID. See
|
|
15
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
16
|
+
# details.
|
|
8
17
|
attr_reader :src
|
|
9
18
|
# @return [Hash{String => Object}]
|
|
10
19
|
attr_reader :metadata
|
|
@@ -16,7 +25,16 @@ module Vellum
|
|
|
16
25
|
|
|
17
26
|
OMIT = Object.new
|
|
18
27
|
|
|
19
|
-
# @param src [String]
|
|
28
|
+
# @param src [String] The reference to the source data. This can be one of the following formats:
|
|
29
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
30
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
31
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
32
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
33
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
34
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
35
|
+
# given its ID. See
|
|
36
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
37
|
+
# details.
|
|
20
38
|
# @param metadata [Hash{String => Object}]
|
|
21
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
22
40
|
# @return [Vellum::VellumVideo]
|
|
@@ -4,7 +4,16 @@ require "json"
|
|
|
4
4
|
|
|
5
5
|
module Vellum
|
|
6
6
|
class VellumVideoRequest
|
|
7
|
-
# @return [String]
|
|
7
|
+
# @return [String] The reference to the source data. This can be one of the following formats:
|
|
8
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
9
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
10
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
11
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
12
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
13
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
14
|
+
# given its ID. See
|
|
15
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
16
|
+
# details.
|
|
8
17
|
attr_reader :src
|
|
9
18
|
# @return [Hash{String => Object}]
|
|
10
19
|
attr_reader :metadata
|
|
@@ -16,7 +25,16 @@ module Vellum
|
|
|
16
25
|
|
|
17
26
|
OMIT = Object.new
|
|
18
27
|
|
|
19
|
-
# @param src [String]
|
|
28
|
+
# @param src [String] The reference to the source data. This can be one of the following formats:
|
|
29
|
+
# 1. A base64-encoded data URL (e.g.,
|
|
30
|
+
# 'data:application/pdf;base64,JVBERi0xLjQKJcfs...').
|
|
31
|
+
# 2. A url pointing to a file accessible over HTTP or HTTPS.
|
|
32
|
+
# 3. A reference to a file that's been previously uploaded to Vellum, in the form
|
|
33
|
+
# of 'vellum:uploaded-file:{uploaded_file_id}'.
|
|
34
|
+
# You can use the Uploaded Files API to retrieve the url of the uploaded file
|
|
35
|
+
# given its ID. See
|
|
36
|
+
# https://docs.vellum.ai/developers/client-sdk/uploaded-files/retrieve for
|
|
37
|
+
# details.
|
|
20
38
|
# @param metadata [Hash{String => Object}]
|
|
21
39
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
|
22
40
|
# @return [Vellum::VellumVideoRequest]
|
|
@@ -48,6 +48,9 @@ end
|
|
|
48
48
|
# Retrieve a previously uploaded file by its ID
|
|
49
49
|
#
|
|
50
50
|
# @param id [String] A UUID string identifying this uploaded file.
|
|
51
|
+
# @param expiry_seconds [Integer] The number of seconds until the signed URL expires. Must be > 0 and <= 2592000
|
|
52
|
+
# (30 days). Non-numeric or out-of-range values fall back to the default (604800
|
|
53
|
+
# seconds or 7 days).
|
|
51
54
|
# @param request_options [Vellum::RequestOptions]
|
|
52
55
|
# @return [Vellum::UploadedFileRead]
|
|
53
56
|
# @example
|
|
@@ -57,7 +60,7 @@ end
|
|
|
57
60
|
# api_key: "YOUR_API_KEY"
|
|
58
61
|
# )
|
|
59
62
|
# api.uploaded_files.retrieve(id: "id")
|
|
60
|
-
def retrieve(id:, request_options: nil)
|
|
63
|
+
def retrieve(id:, expiry_seconds: nil, request_options: nil)
|
|
61
64
|
response = @request_client.conn.get do | req |
|
|
62
65
|
unless request_options&.timeout_in_seconds.nil?
|
|
63
66
|
req.options.timeout = request_options.timeout_in_seconds
|
|
@@ -71,9 +74,7 @@ end
|
|
|
71
74
|
req.headers["X-API-Version"] = "2025-07-30"
|
|
72
75
|
end
|
|
73
76
|
req.headers = { **(req.headers || {}), **@request_client.get_headers, **(request_options&.additional_headers || {}) }.compact
|
|
74
|
-
|
|
75
|
-
req.params = { **(request_options&.additional_query_parameters || {}) }.compact
|
|
76
|
-
end
|
|
77
|
+
req.params = { **(request_options&.additional_query_parameters || {}), "expiry_seconds": expiry_seconds }.compact
|
|
77
78
|
unless request_options.nil? || request_options&.additional_body_parameters.nil?
|
|
78
79
|
req.body = { **(request_options&.additional_body_parameters || {}) }.compact
|
|
79
80
|
end
|
|
@@ -152,6 +153,9 @@ end
|
|
|
152
153
|
# Retrieve a previously uploaded file by its ID
|
|
153
154
|
#
|
|
154
155
|
# @param id [String] A UUID string identifying this uploaded file.
|
|
156
|
+
# @param expiry_seconds [Integer] The number of seconds until the signed URL expires. Must be > 0 and <= 2592000
|
|
157
|
+
# (30 days). Non-numeric or out-of-range values fall back to the default (604800
|
|
158
|
+
# seconds or 7 days).
|
|
155
159
|
# @param request_options [Vellum::RequestOptions]
|
|
156
160
|
# @return [Vellum::UploadedFileRead]
|
|
157
161
|
# @example
|
|
@@ -161,7 +165,7 @@ end
|
|
|
161
165
|
# api_key: "YOUR_API_KEY"
|
|
162
166
|
# )
|
|
163
167
|
# api.uploaded_files.retrieve(id: "id")
|
|
164
|
-
def retrieve(id:, request_options: nil)
|
|
168
|
+
def retrieve(id:, expiry_seconds: nil, request_options: nil)
|
|
165
169
|
Async do
|
|
166
170
|
response = @request_client.conn.get do | req |
|
|
167
171
|
unless request_options&.timeout_in_seconds.nil?
|
|
@@ -176,9 +180,7 @@ end
|
|
|
176
180
|
req.headers["X-API-Version"] = "2025-07-30"
|
|
177
181
|
end
|
|
178
182
|
req.headers = { **(req.headers || {}), **@request_client.get_headers, **(request_options&.additional_headers || {}) }.compact
|
|
179
|
-
|
|
180
|
-
req.params = { **(request_options&.additional_query_parameters || {}) }.compact
|
|
181
|
-
end
|
|
183
|
+
req.params = { **(request_options&.additional_query_parameters || {}), "expiry_seconds": expiry_seconds }.compact
|
|
182
184
|
unless request_options.nil? || request_options&.additional_body_parameters.nil?
|
|
183
185
|
req.body = { **(request_options&.additional_body_parameters || {}) }.compact
|
|
184
186
|
end
|
|
@@ -5,6 +5,7 @@ require_relative "../types/workflow_push_deployment_config_request"
|
|
|
5
5
|
require_relative "../types/dataset_row_push_request"
|
|
6
6
|
require_relative "../types/workflow_push_response"
|
|
7
7
|
require_relative "../../core/file_utilities"
|
|
8
|
+
require_relative "../types/runner_config_request"
|
|
8
9
|
require "json"
|
|
9
10
|
require "async"
|
|
10
11
|
require "async"
|
|
@@ -141,6 +142,12 @@ end
|
|
|
141
142
|
#
|
|
142
143
|
# @param files [Hash{String => Object}]
|
|
143
144
|
# @param module_ [String]
|
|
145
|
+
# @param runner_config [Hash] Request of type Vellum::RunnerConfigRequest, as a Hash
|
|
146
|
+
# * :container_image_name (String)
|
|
147
|
+
# * :container_image_tag (String)
|
|
148
|
+
# * :codegen_version (String)
|
|
149
|
+
# * :sdk_version (String)
|
|
150
|
+
# * :is_deployment_inlining_enabled (Boolean)
|
|
144
151
|
# @param request_options [Vellum::RequestOptions]
|
|
145
152
|
# @return [Hash{String => Object}]
|
|
146
153
|
# @example
|
|
@@ -150,7 +157,7 @@ end
|
|
|
150
157
|
# api_key: "YOUR_API_KEY"
|
|
151
158
|
# )
|
|
152
159
|
# api.workflows.serialize_workflow_files(files: { "files": {"key":"value"} })
|
|
153
|
-
def serialize_workflow_files(files:, module_: nil, request_options: nil)
|
|
160
|
+
def serialize_workflow_files(files:, module_: nil, runner_config: nil, request_options: nil)
|
|
154
161
|
response = @request_client.conn.post do | req |
|
|
155
162
|
unless request_options&.timeout_in_seconds.nil?
|
|
156
163
|
req.options.timeout = request_options.timeout_in_seconds
|
|
@@ -167,7 +174,7 @@ end
|
|
|
167
174
|
unless request_options.nil? || request_options&.additional_query_parameters.nil?
|
|
168
175
|
req.params = { **(request_options&.additional_query_parameters || {}) }.compact
|
|
169
176
|
end
|
|
170
|
-
req.body = { **(request_options&.additional_body_parameters || {}), files: files, module: module_ }.compact
|
|
177
|
+
req.body = { **(request_options&.additional_body_parameters || {}), files: files, module: module_, runner_config: runner_config }.compact
|
|
171
178
|
req.url "#{@request_client.get_url(environment: Default, request_options: request_options)}/v1/workflows/serialize"
|
|
172
179
|
end
|
|
173
180
|
parsed_json = JSON.parse(response.body)
|
|
@@ -308,6 +315,12 @@ end
|
|
|
308
315
|
#
|
|
309
316
|
# @param files [Hash{String => Object}]
|
|
310
317
|
# @param module_ [String]
|
|
318
|
+
# @param runner_config [Hash] Request of type Vellum::RunnerConfigRequest, as a Hash
|
|
319
|
+
# * :container_image_name (String)
|
|
320
|
+
# * :container_image_tag (String)
|
|
321
|
+
# * :codegen_version (String)
|
|
322
|
+
# * :sdk_version (String)
|
|
323
|
+
# * :is_deployment_inlining_enabled (Boolean)
|
|
311
324
|
# @param request_options [Vellum::RequestOptions]
|
|
312
325
|
# @return [Hash{String => Object}]
|
|
313
326
|
# @example
|
|
@@ -317,7 +330,7 @@ end
|
|
|
317
330
|
# api_key: "YOUR_API_KEY"
|
|
318
331
|
# )
|
|
319
332
|
# api.workflows.serialize_workflow_files(files: { "files": {"key":"value"} })
|
|
320
|
-
def serialize_workflow_files(files:, module_: nil, request_options: nil)
|
|
333
|
+
def serialize_workflow_files(files:, module_: nil, runner_config: nil, request_options: nil)
|
|
321
334
|
Async do
|
|
322
335
|
response = @request_client.conn.post do | req |
|
|
323
336
|
unless request_options&.timeout_in_seconds.nil?
|
|
@@ -335,7 +348,7 @@ end
|
|
|
335
348
|
unless request_options.nil? || request_options&.additional_query_parameters.nil?
|
|
336
349
|
req.params = { **(request_options&.additional_query_parameters || {}) }.compact
|
|
337
350
|
end
|
|
338
|
-
req.body = { **(request_options&.additional_body_parameters || {}), files: files, module: module_ }.compact
|
|
351
|
+
req.body = { **(request_options&.additional_body_parameters || {}), files: files, module: module_, runner_config: runner_config }.compact
|
|
339
352
|
req.url "#{@request_client.get_url(environment: Default, request_options: request_options)}/v1/workflows/serialize"
|
|
340
353
|
end
|
|
341
354
|
parsed_json = JSON.parse(response.body)
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: vellum_ai
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.11.
|
|
4
|
+
version: 1.11.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Vellum
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2025-11-
|
|
11
|
+
date: 2025-11-26 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: faraday
|
|
@@ -571,6 +571,7 @@ files:
|
|
|
571
571
|
- lib/vellum_ai/types/replace_test_suite_test_case_request.rb
|
|
572
572
|
- lib/vellum_ai/types/rich_text_child_block.rb
|
|
573
573
|
- lib/vellum_ai/types/rich_text_prompt_block.rb
|
|
574
|
+
- lib/vellum_ai/types/runner_config_request.rb
|
|
574
575
|
- lib/vellum_ai/types/sandbox_scenario.rb
|
|
575
576
|
- lib/vellum_ai/types/scenario_input.rb
|
|
576
577
|
- lib/vellum_ai/types/scenario_input_audio_variable_value.rb
|