vellum_ai 1.2.4 → 1.3.0

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.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/lib/requests.rb +2 -2
  3. data/lib/types_export.rb +28 -0
  4. data/lib/vellum_ai/types/audio_input.rb +75 -0
  5. data/lib/vellum_ai/types/code_executor_input.rb +64 -0
  6. data/lib/vellum_ai/types/deployment_read.rb +3 -8
  7. data/lib/vellum_ai/types/document_input.rb +75 -0
  8. data/lib/vellum_ai/types/environment_enum.rb +0 -3
  9. data/lib/vellum_ai/types/image_input.rb +75 -0
  10. data/lib/vellum_ai/types/named_scenario_input_audio_variable_value_request.rb +76 -0
  11. data/lib/vellum_ai/types/named_scenario_input_document_variable_value_request.rb +76 -0
  12. data/lib/vellum_ai/types/named_scenario_input_image_variable_value_request.rb +76 -0
  13. data/lib/vellum_ai/types/named_scenario_input_request.rb +64 -0
  14. data/lib/vellum_ai/types/named_scenario_input_video_variable_value_request.rb +76 -0
  15. data/lib/vellum_ai/types/named_test_case_audio_variable_value.rb +75 -0
  16. data/lib/vellum_ai/types/named_test_case_audio_variable_value_request.rb +76 -0
  17. data/lib/vellum_ai/types/named_test_case_document_variable_value.rb +74 -0
  18. data/lib/vellum_ai/types/named_test_case_document_variable_value_request.rb +76 -0
  19. data/lib/vellum_ai/types/named_test_case_image_variable_value.rb +74 -0
  20. data/lib/vellum_ai/types/named_test_case_image_variable_value_request.rb +75 -0
  21. data/lib/vellum_ai/types/named_test_case_variable_value.rb +64 -0
  22. data/lib/vellum_ai/types/named_test_case_variable_value_request.rb +64 -0
  23. data/lib/vellum_ai/types/named_test_case_video_variable_value.rb +74 -0
  24. data/lib/vellum_ai/types/named_test_case_video_variable_value_request.rb +75 -0
  25. data/lib/vellum_ai/types/node_execution_span_attributes.rb +11 -2
  26. data/lib/vellum_ai/types/scenario_input.rb +64 -0
  27. data/lib/vellum_ai/types/scenario_input_audio_variable_value.rb +74 -0
  28. data/lib/vellum_ai/types/scenario_input_document_variable_value.rb +74 -0
  29. data/lib/vellum_ai/types/scenario_input_image_variable_value.rb +74 -0
  30. data/lib/vellum_ai/types/scenario_input_video_variable_value.rb +74 -0
  31. data/lib/vellum_ai/types/slim_deployment_read.rb +3 -8
  32. data/lib/vellum_ai/types/slim_workflow_deployment.rb +3 -8
  33. data/lib/vellum_ai/types/span_link.rb +3 -3
  34. data/lib/vellum_ai/types/span_link_type_enum.rb +10 -1
  35. data/lib/vellum_ai/types/test_case_audio_variable_value.rb +84 -0
  36. data/lib/vellum_ai/types/test_case_document_variable_value.rb +84 -0
  37. data/lib/vellum_ai/types/test_case_image_variable_value.rb +84 -0
  38. data/lib/vellum_ai/types/test_case_variable_value.rb +64 -0
  39. data/lib/vellum_ai/types/test_case_video_variable_value.rb +84 -0
  40. data/lib/vellum_ai/types/video_input.rb +75 -0
  41. data/lib/vellum_ai/types/workflow_deployment_read.rb +3 -8
  42. data/lib/vellum_ai/types/workflow_push_deployment_config_request.rb +9 -2
  43. data/lib/vellum_ai/types/workflow_request_audio_input_request.rb +75 -0
  44. data/lib/vellum_ai/types/workflow_request_document_input_request.rb +75 -0
  45. data/lib/vellum_ai/types/workflow_request_image_input_request.rb +75 -0
  46. data/lib/vellum_ai/types/workflow_request_input_request.rb +64 -0
  47. data/lib/vellum_ai/types/workflow_request_video_input_request.rb +75 -0
  48. data/lib/vellum_ai/workflow_sandboxes/client.rb +6 -8
  49. data/lib/vellum_ai/workflows/client.rb +12 -4
  50. metadata +30 -2
@@ -8,6 +8,7 @@ require "ostruct"
8
8
  require "json"
9
9
 
10
10
  module Vellum
11
+ # A Workflow Deployment's full details.
11
12
  class WorkflowDeploymentRead
12
13
  # @return [String]
13
14
  attr_reader :id
@@ -19,10 +20,7 @@ module Vellum
19
20
  # * `ACTIVE` - Active
20
21
  # * `ARCHIVED` - Archived
21
22
  attr_reader :status
22
- # @return [Vellum::EnvironmentEnum] The environment this workflow deployment is used in
23
- # * `DEVELOPMENT` - Development
24
- # * `STAGING` - Staging
25
- # * `PRODUCTION` - Production
23
+ # @return [Vellum::EnvironmentEnum] Deprecated. The value returned will always be 'PRODUCTION'.
26
24
  attr_reader :environment
27
25
  # @return [DateTime]
28
26
  attr_reader :created
@@ -53,10 +51,7 @@ module Vellum
53
51
  # @param status [Vellum::EntityStatus] The current status of the workflow deployment
54
52
  # * `ACTIVE` - Active
55
53
  # * `ARCHIVED` - Archived
56
- # @param environment [Vellum::EnvironmentEnum] The environment this workflow deployment is used in
57
- # * `DEVELOPMENT` - Development
58
- # * `STAGING` - Staging
59
- # * `PRODUCTION` - Production
54
+ # @param environment [Vellum::EnvironmentEnum] Deprecated. The value returned will always be 'PRODUCTION'.
60
55
  # @param created [DateTime]
61
56
  # @param last_deployed_on [DateTime]
62
57
  # @param last_deployed_history_item_id [String] The ID of the history item associated with this Workflow Deployment's LATEST
@@ -12,6 +12,8 @@ module Vellum
12
12
  attr_reader :description
13
13
  # @return [Array<String>]
14
14
  attr_reader :release_tags
15
+ # @return [String]
16
+ attr_reader :release_description
15
17
  # @return [OpenStruct] Additional properties unmapped to the current class definition
16
18
  attr_reader :additional_properties
17
19
  # @return [Object]
@@ -24,15 +26,17 @@ module Vellum
24
26
  # @param name [String]
25
27
  # @param description [String]
26
28
  # @param release_tags [Array<String>]
29
+ # @param release_description [String]
27
30
  # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
28
31
  # @return [Vellum::WorkflowPushDeploymentConfigRequest]
29
- def initialize(label: OMIT, name: OMIT, description: OMIT, release_tags: OMIT, additional_properties: nil)
32
+ def initialize(label: OMIT, name: OMIT, description: OMIT, release_tags: OMIT, release_description: OMIT, additional_properties: nil)
30
33
  @label = label if label != OMIT
31
34
  @name = name if name != OMIT
32
35
  @description = description if description != OMIT
33
36
  @release_tags = release_tags if release_tags != OMIT
37
+ @release_description = release_description if release_description != OMIT
34
38
  @additional_properties = additional_properties
35
- @_field_set = { "label": label, "name": name, "description": description, "release_tags": release_tags }.reject do | _k, v |
39
+ @_field_set = { "label": label, "name": name, "description": description, "release_tags": release_tags, "release_description": release_description }.reject do | _k, v |
36
40
  v == OMIT
37
41
  end
38
42
  end
@@ -47,11 +51,13 @@ end
47
51
  name = parsed_json["name"]
48
52
  description = parsed_json["description"]
49
53
  release_tags = parsed_json["release_tags"]
54
+ release_description = parsed_json["release_description"]
50
55
  new(
51
56
  label: label,
52
57
  name: name,
53
58
  description: description,
54
59
  release_tags: release_tags,
60
+ release_description: release_description,
55
61
  additional_properties: struct
56
62
  )
57
63
  end
@@ -72,6 +78,7 @@ end
72
78
  obj.name&.is_a?(String) != false || raise("Passed value for field obj.name is not the expected type, validation failed.")
73
79
  obj.description&.is_a?(String) != false || raise("Passed value for field obj.description is not the expected type, validation failed.")
74
80
  obj.release_tags&.is_a?(Array) != false || raise("Passed value for field obj.release_tags is not the expected type, validation failed.")
81
+ obj.release_description&.is_a?(String) != false || raise("Passed value for field obj.release_description is not the expected type, validation failed.")
75
82
  end
76
83
  end
77
84
  end
@@ -0,0 +1,75 @@
1
+ # frozen_string_literal: true
2
+ require_relative "vellum_audio_request"
3
+ require "ostruct"
4
+ require "json"
5
+
6
+ module Vellum
7
+ # The input for an audio variable in a Workflow.
8
+ class WorkflowRequestAudioInputRequest
9
+ # @return [String] The variable's name, as defined in the Workflow.
10
+ attr_reader :name
11
+ # @return [String]
12
+ attr_reader :type
13
+ # @return [Vellum::VellumAudioRequest]
14
+ attr_reader :value
15
+ # @return [OpenStruct] Additional properties unmapped to the current class definition
16
+ attr_reader :additional_properties
17
+ # @return [Object]
18
+ attr_reader :_field_set
19
+ protected :_field_set
20
+
21
+ OMIT = Object.new
22
+
23
+ # @param name [String] The variable's name, as defined in the Workflow.
24
+ # @param type [String]
25
+ # @param value [Vellum::VellumAudioRequest]
26
+ # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
27
+ # @return [Vellum::WorkflowRequestAudioInputRequest]
28
+ def initialize(name:, type:, value:, additional_properties: nil)
29
+ @name = name
30
+ @type = type
31
+ @value = value
32
+ @additional_properties = additional_properties
33
+ @_field_set = { "name": name, "type": type, "value": value }
34
+ end
35
+ # Deserialize a JSON object to an instance of WorkflowRequestAudioInputRequest
36
+ #
37
+ # @param json_object [String]
38
+ # @return [Vellum::WorkflowRequestAudioInputRequest]
39
+ def self.from_json(json_object:)
40
+ struct = JSON.parse(json_object, object_class: OpenStruct)
41
+ parsed_json = JSON.parse(json_object)
42
+ name = parsed_json["name"]
43
+ type = parsed_json["type"]
44
+ unless parsed_json["value"].nil?
45
+ value = parsed_json["value"].to_json
46
+ value = Vellum::VellumAudioRequest.from_json(json_object: value)
47
+ else
48
+ value = nil
49
+ end
50
+ new(
51
+ name: name,
52
+ type: type,
53
+ value: value,
54
+ additional_properties: struct
55
+ )
56
+ end
57
+ # Serialize an instance of WorkflowRequestAudioInputRequest to a JSON object
58
+ #
59
+ # @return [String]
60
+ def to_json
61
+ @_field_set&.to_json
62
+ end
63
+ # Leveraged for Union-type generation, validate_raw attempts to parse the given
64
+ # hash and check each fields type against the current object's property
65
+ # definitions.
66
+ #
67
+ # @param obj [Object]
68
+ # @return [Void]
69
+ def self.validate_raw(obj:)
70
+ obj.name.is_a?(String) != false || raise("Passed value for field obj.name is not the expected type, validation failed.")
71
+ obj.type.is_a?(String) != false || raise("Passed value for field obj.type is not the expected type, validation failed.")
72
+ Vellum::VellumAudioRequest.validate_raw(obj: obj.value)
73
+ end
74
+ end
75
+ end
@@ -0,0 +1,75 @@
1
+ # frozen_string_literal: true
2
+ require_relative "vellum_document_request"
3
+ require "ostruct"
4
+ require "json"
5
+
6
+ module Vellum
7
+ # The input for a document variable in a Workflow.
8
+ class WorkflowRequestDocumentInputRequest
9
+ # @return [String] The variable's name, as defined in the Workflow.
10
+ attr_reader :name
11
+ # @return [String]
12
+ attr_reader :type
13
+ # @return [Vellum::VellumDocumentRequest]
14
+ attr_reader :value
15
+ # @return [OpenStruct] Additional properties unmapped to the current class definition
16
+ attr_reader :additional_properties
17
+ # @return [Object]
18
+ attr_reader :_field_set
19
+ protected :_field_set
20
+
21
+ OMIT = Object.new
22
+
23
+ # @param name [String] The variable's name, as defined in the Workflow.
24
+ # @param type [String]
25
+ # @param value [Vellum::VellumDocumentRequest]
26
+ # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
27
+ # @return [Vellum::WorkflowRequestDocumentInputRequest]
28
+ def initialize(name:, type:, value:, additional_properties: nil)
29
+ @name = name
30
+ @type = type
31
+ @value = value
32
+ @additional_properties = additional_properties
33
+ @_field_set = { "name": name, "type": type, "value": value }
34
+ end
35
+ # Deserialize a JSON object to an instance of WorkflowRequestDocumentInputRequest
36
+ #
37
+ # @param json_object [String]
38
+ # @return [Vellum::WorkflowRequestDocumentInputRequest]
39
+ def self.from_json(json_object:)
40
+ struct = JSON.parse(json_object, object_class: OpenStruct)
41
+ parsed_json = JSON.parse(json_object)
42
+ name = parsed_json["name"]
43
+ type = parsed_json["type"]
44
+ unless parsed_json["value"].nil?
45
+ value = parsed_json["value"].to_json
46
+ value = Vellum::VellumDocumentRequest.from_json(json_object: value)
47
+ else
48
+ value = nil
49
+ end
50
+ new(
51
+ name: name,
52
+ type: type,
53
+ value: value,
54
+ additional_properties: struct
55
+ )
56
+ end
57
+ # Serialize an instance of WorkflowRequestDocumentInputRequest to a JSON object
58
+ #
59
+ # @return [String]
60
+ def to_json
61
+ @_field_set&.to_json
62
+ end
63
+ # Leveraged for Union-type generation, validate_raw attempts to parse the given
64
+ # hash and check each fields type against the current object's property
65
+ # definitions.
66
+ #
67
+ # @param obj [Object]
68
+ # @return [Void]
69
+ def self.validate_raw(obj:)
70
+ obj.name.is_a?(String) != false || raise("Passed value for field obj.name is not the expected type, validation failed.")
71
+ obj.type.is_a?(String) != false || raise("Passed value for field obj.type is not the expected type, validation failed.")
72
+ Vellum::VellumDocumentRequest.validate_raw(obj: obj.value)
73
+ end
74
+ end
75
+ end
@@ -0,0 +1,75 @@
1
+ # frozen_string_literal: true
2
+ require_relative "vellum_image_request"
3
+ require "ostruct"
4
+ require "json"
5
+
6
+ module Vellum
7
+ # The input for an image variable in a Workflow.
8
+ class WorkflowRequestImageInputRequest
9
+ # @return [String] The variable's name, as defined in the Workflow.
10
+ attr_reader :name
11
+ # @return [String]
12
+ attr_reader :type
13
+ # @return [Vellum::VellumImageRequest]
14
+ attr_reader :value
15
+ # @return [OpenStruct] Additional properties unmapped to the current class definition
16
+ attr_reader :additional_properties
17
+ # @return [Object]
18
+ attr_reader :_field_set
19
+ protected :_field_set
20
+
21
+ OMIT = Object.new
22
+
23
+ # @param name [String] The variable's name, as defined in the Workflow.
24
+ # @param type [String]
25
+ # @param value [Vellum::VellumImageRequest]
26
+ # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
27
+ # @return [Vellum::WorkflowRequestImageInputRequest]
28
+ def initialize(name:, type:, value:, additional_properties: nil)
29
+ @name = name
30
+ @type = type
31
+ @value = value
32
+ @additional_properties = additional_properties
33
+ @_field_set = { "name": name, "type": type, "value": value }
34
+ end
35
+ # Deserialize a JSON object to an instance of WorkflowRequestImageInputRequest
36
+ #
37
+ # @param json_object [String]
38
+ # @return [Vellum::WorkflowRequestImageInputRequest]
39
+ def self.from_json(json_object:)
40
+ struct = JSON.parse(json_object, object_class: OpenStruct)
41
+ parsed_json = JSON.parse(json_object)
42
+ name = parsed_json["name"]
43
+ type = parsed_json["type"]
44
+ unless parsed_json["value"].nil?
45
+ value = parsed_json["value"].to_json
46
+ value = Vellum::VellumImageRequest.from_json(json_object: value)
47
+ else
48
+ value = nil
49
+ end
50
+ new(
51
+ name: name,
52
+ type: type,
53
+ value: value,
54
+ additional_properties: struct
55
+ )
56
+ end
57
+ # Serialize an instance of WorkflowRequestImageInputRequest to a JSON object
58
+ #
59
+ # @return [String]
60
+ def to_json
61
+ @_field_set&.to_json
62
+ end
63
+ # Leveraged for Union-type generation, validate_raw attempts to parse the given
64
+ # hash and check each fields type against the current object's property
65
+ # definitions.
66
+ #
67
+ # @param obj [Object]
68
+ # @return [Void]
69
+ def self.validate_raw(obj:)
70
+ obj.name.is_a?(String) != false || raise("Passed value for field obj.name is not the expected type, validation failed.")
71
+ obj.type.is_a?(String) != false || raise("Passed value for field obj.type is not the expected type, validation failed.")
72
+ Vellum::VellumImageRequest.validate_raw(obj: obj.value)
73
+ end
74
+ end
75
+ end
@@ -4,6 +4,10 @@ require_relative "workflow_request_string_input_request"
4
4
  require_relative "workflow_request_json_input_request"
5
5
  require_relative "workflow_request_chat_history_input_request"
6
6
  require_relative "workflow_request_number_input_request"
7
+ require_relative "workflow_request_audio_input_request"
8
+ require_relative "workflow_request_video_input_request"
9
+ require_relative "workflow_request_image_input_request"
10
+ require_relative "workflow_request_document_input_request"
7
11
 
8
12
  module Vellum
9
13
  class WorkflowRequestInputRequest
@@ -51,6 +55,46 @@ end
51
55
  return Vellum::WorkflowRequestNumberInputRequest.from_json(json_object: struct)
52
56
  else
53
57
  return nil
58
+ end
59
+ rescue StandardError
60
+ # noop
61
+ end
62
+ begin
63
+ Vellum::WorkflowRequestAudioInputRequest.validate_raw(obj: struct)
64
+ unless struct.nil?
65
+ return Vellum::WorkflowRequestAudioInputRequest.from_json(json_object: struct)
66
+ else
67
+ return nil
68
+ end
69
+ rescue StandardError
70
+ # noop
71
+ end
72
+ begin
73
+ Vellum::WorkflowRequestVideoInputRequest.validate_raw(obj: struct)
74
+ unless struct.nil?
75
+ return Vellum::WorkflowRequestVideoInputRequest.from_json(json_object: struct)
76
+ else
77
+ return nil
78
+ end
79
+ rescue StandardError
80
+ # noop
81
+ end
82
+ begin
83
+ Vellum::WorkflowRequestImageInputRequest.validate_raw(obj: struct)
84
+ unless struct.nil?
85
+ return Vellum::WorkflowRequestImageInputRequest.from_json(json_object: struct)
86
+ else
87
+ return nil
88
+ end
89
+ rescue StandardError
90
+ # noop
91
+ end
92
+ begin
93
+ Vellum::WorkflowRequestDocumentInputRequest.validate_raw(obj: struct)
94
+ unless struct.nil?
95
+ return Vellum::WorkflowRequestDocumentInputRequest.from_json(json_object: struct)
96
+ else
97
+ return nil
54
98
  end
55
99
  rescue StandardError
56
100
  # noop
@@ -84,6 +128,26 @@ end
84
128
  rescue StandardError
85
129
  # noop
86
130
  end
131
+ begin
132
+ return Vellum::WorkflowRequestAudioInputRequest.validate_raw(obj: obj)
133
+ rescue StandardError
134
+ # noop
135
+ end
136
+ begin
137
+ return Vellum::WorkflowRequestVideoInputRequest.validate_raw(obj: obj)
138
+ rescue StandardError
139
+ # noop
140
+ end
141
+ begin
142
+ return Vellum::WorkflowRequestImageInputRequest.validate_raw(obj: obj)
143
+ rescue StandardError
144
+ # noop
145
+ end
146
+ begin
147
+ return Vellum::WorkflowRequestDocumentInputRequest.validate_raw(obj: obj)
148
+ rescue StandardError
149
+ # noop
150
+ end
87
151
  raise("Passed value matched no type within the union, validation failed.")
88
152
  end
89
153
  end
@@ -0,0 +1,75 @@
1
+ # frozen_string_literal: true
2
+ require_relative "vellum_video_request"
3
+ require "ostruct"
4
+ require "json"
5
+
6
+ module Vellum
7
+ # The input for a video variable in a Workflow.
8
+ class WorkflowRequestVideoInputRequest
9
+ # @return [String] The variable's name, as defined in the Workflow.
10
+ attr_reader :name
11
+ # @return [String]
12
+ attr_reader :type
13
+ # @return [Vellum::VellumVideoRequest]
14
+ attr_reader :value
15
+ # @return [OpenStruct] Additional properties unmapped to the current class definition
16
+ attr_reader :additional_properties
17
+ # @return [Object]
18
+ attr_reader :_field_set
19
+ protected :_field_set
20
+
21
+ OMIT = Object.new
22
+
23
+ # @param name [String] The variable's name, as defined in the Workflow.
24
+ # @param type [String]
25
+ # @param value [Vellum::VellumVideoRequest]
26
+ # @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
27
+ # @return [Vellum::WorkflowRequestVideoInputRequest]
28
+ def initialize(name:, type:, value:, additional_properties: nil)
29
+ @name = name
30
+ @type = type
31
+ @value = value
32
+ @additional_properties = additional_properties
33
+ @_field_set = { "name": name, "type": type, "value": value }
34
+ end
35
+ # Deserialize a JSON object to an instance of WorkflowRequestVideoInputRequest
36
+ #
37
+ # @param json_object [String]
38
+ # @return [Vellum::WorkflowRequestVideoInputRequest]
39
+ def self.from_json(json_object:)
40
+ struct = JSON.parse(json_object, object_class: OpenStruct)
41
+ parsed_json = JSON.parse(json_object)
42
+ name = parsed_json["name"]
43
+ type = parsed_json["type"]
44
+ unless parsed_json["value"].nil?
45
+ value = parsed_json["value"].to_json
46
+ value = Vellum::VellumVideoRequest.from_json(json_object: value)
47
+ else
48
+ value = nil
49
+ end
50
+ new(
51
+ name: name,
52
+ type: type,
53
+ value: value,
54
+ additional_properties: struct
55
+ )
56
+ end
57
+ # Serialize an instance of WorkflowRequestVideoInputRequest to a JSON object
58
+ #
59
+ # @return [String]
60
+ def to_json
61
+ @_field_set&.to_json
62
+ end
63
+ # Leveraged for Union-type generation, validate_raw attempts to parse the given
64
+ # hash and check each fields type against the current object's property
65
+ # definitions.
66
+ #
67
+ # @param obj [Object]
68
+ # @return [Void]
69
+ def self.validate_raw(obj:)
70
+ obj.name.is_a?(String) != false || raise("Passed value for field obj.name is not the expected type, validation failed.")
71
+ obj.type.is_a?(String) != false || raise("Passed value for field obj.type is not the expected type, validation failed.")
72
+ Vellum::VellumVideoRequest.validate_raw(obj: obj.value)
73
+ end
74
+ end
75
+ end
@@ -19,7 +19,6 @@ module Vellum
19
19
  @request_client = request_client
20
20
  end
21
21
  # @param id [String] A UUID string identifying this workflow sandbox.
22
- # @param workflow_id [String] An ID identifying the Workflow you'd like to deploy.
23
22
  # @param workflow_deployment_id [String] The Vellum-generated ID of the Workflow Deployment you'd like to update. Cannot
24
23
  # specify both this and workflow_deployment_name. Leave null to create a new
25
24
  # Workflow Deployment.
@@ -40,8 +39,8 @@ module Vellum
40
39
  # environment: Vellum::Environment::PRODUCTION,
41
40
  # api_key: "YOUR_API_KEY"
42
41
  # )
43
- # api.workflow_sandboxes.deploy_workflow(id: "id", workflow_id: "workflow_id")
44
- def deploy_workflow(id:, workflow_id:, workflow_deployment_id: nil, workflow_deployment_name: nil, label: nil, release_tags: nil, release_description: nil, request_options: nil)
42
+ # api.workflow_sandboxes.deploy_workflow(id: "id")
43
+ def deploy_workflow(id:, workflow_deployment_id: nil, workflow_deployment_name: nil, label: nil, release_tags: nil, release_description: nil, request_options: nil)
45
44
  response = @request_client.conn.post do | req |
46
45
  unless request_options&.timeout_in_seconds.nil?
47
46
  req.options.timeout = request_options.timeout_in_seconds
@@ -59,7 +58,7 @@ module Vellum
59
58
  req.params = { **(request_options&.additional_query_parameters || {}) }.compact
60
59
  end
61
60
  req.body = { **(request_options&.additional_body_parameters || {}), workflow_deployment_id: workflow_deployment_id, workflow_deployment_name: workflow_deployment_name, label: label, release_tags: release_tags, release_description: release_description }.compact
62
- req.url "#{@request_client.get_url(environment: Default, request_options: request_options)}/v1/workflow-sandboxes/#{id}/workflows/#{workflow_id}/deploy"
61
+ req.url "#{@request_client.get_url(environment: Default, request_options: request_options)}/v1/workflow-sandboxes/#{id}/deploy"
63
62
  end
64
63
  Vellum::WorkflowDeploymentRead.from_json(json_object: response.body)
65
64
  end
@@ -113,7 +112,6 @@ end
113
112
  @request_client = request_client
114
113
  end
115
114
  # @param id [String] A UUID string identifying this workflow sandbox.
116
- # @param workflow_id [String] An ID identifying the Workflow you'd like to deploy.
117
115
  # @param workflow_deployment_id [String] The Vellum-generated ID of the Workflow Deployment you'd like to update. Cannot
118
116
  # specify both this and workflow_deployment_name. Leave null to create a new
119
117
  # Workflow Deployment.
@@ -134,8 +132,8 @@ end
134
132
  # environment: Vellum::Environment::PRODUCTION,
135
133
  # api_key: "YOUR_API_KEY"
136
134
  # )
137
- # api.workflow_sandboxes.deploy_workflow(id: "id", workflow_id: "workflow_id")
138
- def deploy_workflow(id:, workflow_id:, workflow_deployment_id: nil, workflow_deployment_name: nil, label: nil, release_tags: nil, release_description: nil, request_options: nil)
135
+ # api.workflow_sandboxes.deploy_workflow(id: "id")
136
+ def deploy_workflow(id:, workflow_deployment_id: nil, workflow_deployment_name: nil, label: nil, release_tags: nil, release_description: nil, request_options: nil)
139
137
  Async do
140
138
  response = @request_client.conn.post do | req |
141
139
  unless request_options&.timeout_in_seconds.nil?
@@ -154,7 +152,7 @@ end
154
152
  req.params = { **(request_options&.additional_query_parameters || {}) }.compact
155
153
  end
156
154
  req.body = { **(request_options&.additional_body_parameters || {}), workflow_deployment_id: workflow_deployment_id, workflow_deployment_name: workflow_deployment_name, label: label, release_tags: release_tags, release_description: release_description }.compact
157
- req.url "#{@request_client.get_url(environment: Default, request_options: request_options)}/v1/workflow-sandboxes/#{id}/workflows/#{workflow_id}/deploy"
155
+ req.url "#{@request_client.get_url(environment: Default, request_options: request_options)}/v1/workflow-sandboxes/#{id}/deploy"
158
156
  end
159
157
  Vellum::WorkflowDeploymentRead.from_json(json_object: response.body)
160
158
  end
@@ -23,14 +23,17 @@ module Vellum
23
23
  # @param exclude_display [Boolean]
24
24
  # @param include_json [Boolean]
25
25
  # @param include_sandbox [Boolean]
26
+ # @param release_tag [String] Release tag to use when pulling from deployment (implies deployment-only lookup)
26
27
  # @param strict [Boolean]
28
+ # @param version [String] Semantic version range to validate against the Workflow SDK version (e.g.,
29
+ # '>=1.0.0,<1.2.3')
27
30
  # @param request_options [Vellum::RequestOptions]
28
31
  # @yield on_data[chunk, overall_received_bytes, env] Leverage the Faraday on_data callback which
29
32
  # will receive tuples of strings, the sum of characters received so far, and the
30
33
  # response environment. The latter will allow access to the response status,
31
34
  # headers and reason, as well as the request info.
32
35
  # @return [Void]
33
- def pull(id:, exclude_code: nil, exclude_display: nil, include_json: nil, include_sandbox: nil, strict: nil, request_options: nil, &on_data)
36
+ def pull(id:, exclude_code: nil, exclude_display: nil, include_json: nil, include_sandbox: nil, release_tag: nil, strict: nil, version: nil, request_options: nil, &on_data)
34
37
  response = @request_client.conn.get do | req |
35
38
  unless request_options&.timeout_in_seconds.nil?
36
39
  req.options.timeout = request_options.timeout_in_seconds
@@ -45,7 +48,7 @@ module Vellum
45
48
  end
46
49
  req.headers = { **(req.headers || {}), **@request_client.get_headers, **(request_options&.additional_headers || {}) }.compact
47
50
  req.options.on_data = on_data
48
- req.params = { **(request_options&.additional_query_parameters || {}), "exclude_code": exclude_code, "exclude_display": exclude_display, "include_json": include_json, "include_sandbox": include_sandbox, "strict": strict }.compact
51
+ req.params = { **(request_options&.additional_query_parameters || {}), "exclude_code": exclude_code, "exclude_display": exclude_display, "include_json": include_json, "include_sandbox": include_sandbox, "release_tag": release_tag, "strict": strict, "version": version }.compact
49
52
  unless request_options.nil? || request_options&.additional_body_parameters.nil?
50
53
  req.body = { **(request_options&.additional_body_parameters || {}) }.compact
51
54
  end
@@ -59,6 +62,7 @@ end
59
62
  # * :name (String)
60
63
  # * :description (String)
61
64
  # * :release_tags (Array<String>)
65
+ # * :release_description (String)
62
66
  # @param artifact [String, IO]
63
67
  # @param dry_run [Boolean]
64
68
  # @param strict [Boolean]
@@ -104,14 +108,17 @@ end
104
108
  # @param exclude_display [Boolean]
105
109
  # @param include_json [Boolean]
106
110
  # @param include_sandbox [Boolean]
111
+ # @param release_tag [String] Release tag to use when pulling from deployment (implies deployment-only lookup)
107
112
  # @param strict [Boolean]
113
+ # @param version [String] Semantic version range to validate against the Workflow SDK version (e.g.,
114
+ # '>=1.0.0,<1.2.3')
108
115
  # @param request_options [Vellum::RequestOptions]
109
116
  # @yield on_data[chunk, overall_received_bytes, env] Leverage the Faraday on_data callback which
110
117
  # will receive tuples of strings, the sum of characters received so far, and the
111
118
  # response environment. The latter will allow access to the response status,
112
119
  # headers and reason, as well as the request info.
113
120
  # @return [Void]
114
- def pull(id:, exclude_code: nil, exclude_display: nil, include_json: nil, include_sandbox: nil, strict: nil, request_options: nil, &on_data)
121
+ def pull(id:, exclude_code: nil, exclude_display: nil, include_json: nil, include_sandbox: nil, release_tag: nil, strict: nil, version: nil, request_options: nil, &on_data)
115
122
  Async do
116
123
  response = @request_client.conn.get do | req |
117
124
  unless request_options&.timeout_in_seconds.nil?
@@ -127,7 +134,7 @@ end
127
134
  end
128
135
  req.headers = { **(req.headers || {}), **@request_client.get_headers, **(request_options&.additional_headers || {}) }.compact
129
136
  req.options.on_data = on_data
130
- req.params = { **(request_options&.additional_query_parameters || {}), "exclude_code": exclude_code, "exclude_display": exclude_display, "include_json": include_json, "include_sandbox": include_sandbox, "strict": strict }.compact
137
+ req.params = { **(request_options&.additional_query_parameters || {}), "exclude_code": exclude_code, "exclude_display": exclude_display, "include_json": include_json, "include_sandbox": include_sandbox, "release_tag": release_tag, "strict": strict, "version": version }.compact
131
138
  unless request_options.nil? || request_options&.additional_body_parameters.nil?
132
139
  req.body = { **(request_options&.additional_body_parameters || {}) }.compact
133
140
  end
@@ -142,6 +149,7 @@ end
142
149
  # * :name (String)
143
150
  # * :description (String)
144
151
  # * :release_tags (Array<String>)
152
+ # * :release_description (String)
145
153
  # @param artifact [String, IO]
146
154
  # @param dry_run [Boolean]
147
155
  # @param strict [Boolean]