docusign_maestro 1.0.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/CHANGELOG.md +35 -0
- data/README.md +230 -0
- data/docusign_maestro.gemspec +48 -0
- data/lib/docusign_maestro/api/workflow_instance_management_api.rb +248 -0
- data/lib/docusign_maestro/api/workflow_management_api.rb +440 -0
- data/lib/docusign_maestro/api/workflow_trigger_api.rb +95 -0
- data/lib/docusign_maestro/client/api_client.rb +600 -0
- data/lib/docusign_maestro/client/api_error.rb +37 -0
- data/lib/docusign_maestro/client/auth/oauth.rb +1061 -0
- data/lib/docusign_maestro/configuration.rb +203 -0
- data/lib/docusign_maestro/models/access_token_response.rb +204 -0
- data/lib/docusign_maestro/models/access_token_token_types.rb +30 -0
- data/lib/docusign_maestro/models/account_id.rb +175 -0
- data/lib/docusign_maestro/models/aow_uuid.rb +174 -0
- data/lib/docusign_maestro/models/aow_uuid_string.rb +174 -0
- data/lib/docusign_maestro/models/cancel_response.rb +197 -0
- data/lib/docusign_maestro/models/create_or_update_workflow_definition_request_body.rb +184 -0
- data/lib/docusign_maestro/models/deploy_request.rb +188 -0
- data/lib/docusign_maestro/models/deploy_response.rb +220 -0
- data/lib/docusign_maestro/models/deploy_status.rb +30 -0
- data/lib/docusign_maestro/models/deployment_status.rb +33 -0
- data/lib/docusign_maestro/models/ds_do_until_step.rb +247 -0
- data/lib/docusign_maestro/models/ds_doc_gen_step.rb +261 -0
- data/lib/docusign_maestro/models/ds_doc_gen_step_input.rb +246 -0
- data/lib/docusign_maestro/models/ds_idv_step.rb +261 -0
- data/lib/docusign_maestro/models/ds_idv_step_input.rb +234 -0
- data/lib/docusign_maestro/models/ds_if_else_step.rb +264 -0
- data/lib/docusign_maestro/models/ds_loop_step.rb +247 -0
- data/lib/docusign_maestro/models/ds_parallel_step.rb +246 -0
- data/lib/docusign_maestro/models/ds_service_step.rb +175 -0
- data/lib/docusign_maestro/models/ds_sign_step.rb +261 -0
- data/lib/docusign_maestro/models/ds_sign_step_input.rb +241 -0
- data/lib/docusign_maestro/models/ds_step_id.rb +175 -0
- data/lib/docusign_maestro/models/ds_transformation_step.rb +279 -0
- data/lib/docusign_maestro/models/ds_web_forms_step.rb +265 -0
- data/lib/docusign_maestro/models/ds_web_forms_step_config.rb +188 -0
- data/lib/docusign_maestro/models/ds_workflow_boolean_expression.rb +219 -0
- data/lib/docusign_maestro/models/ds_workflow_comparison_expression.rb +232 -0
- data/lib/docusign_maestro/models/ds_workflow_comparison_operator_types.rb +39 -0
- data/lib/docusign_maestro/models/ds_workflow_concat_expression.rb +200 -0
- data/lib/docusign_maestro/models/ds_workflow_doc_gen_doc_output_format.rb +29 -0
- data/lib/docusign_maestro/models/ds_workflow_expression_types_boolean_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_expression_types_comparison_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_expression_types_parallel_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_index_of_expression.rb +218 -0
- data/lib/docusign_maestro/models/ds_workflow_lane.rb +205 -0
- data/lib/docusign_maestro/models/ds_workflow_lanes_record.rb +174 -0
- data/lib/docusign_maestro/models/ds_workflow_last_index_of_expression.rb +218 -0
- data/lib/docusign_maestro/models/ds_workflow_logical_operator_types.rb +29 -0
- data/lib/docusign_maestro/models/ds_workflow_parallel_expression.rb +204 -0
- data/lib/docusign_maestro/models/ds_workflow_participant_record.rb +175 -0
- data/lib/docusign_maestro/models/ds_workflow_replace_expression.rb +233 -0
- data/lib/docusign_maestro/models/ds_workflow_step.rb +175 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_do_until.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_ds_doc_gen.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_ds_idv.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_ds_if_else.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_ds_sign.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_ds_transformation.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_ds_web_forms.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_loop.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_step_types_parallel.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_substring_expression.rb +228 -0
- data/lib/docusign_maestro/models/ds_workflow_to_lower_expression.rb +203 -0
- data/lib/docusign_maestro/models/ds_workflow_to_upper_expression.rb +203 -0
- data/lib/docusign_maestro/models/ds_workflow_transformation_expression.rb +175 -0
- data/lib/docusign_maestro/models/ds_workflow_transformation_expression_types_concat_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_transformation_expression_types_index_of_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_transformation_expression_types_last_index_of_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_transformation_expression_types_replace_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_transformation_expression_types_substring_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_transformation_expression_types_to_lower_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_transformation_expression_types_to_upper_expression.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_trigger.rb +274 -0
- data/lib/docusign_maestro/models/ds_workflow_trigger_types.rb +29 -0
- data/lib/docusign_maestro/models/ds_workflow_variable.rb +175 -0
- data/lib/docusign_maestro/models/ds_workflow_variable_from_participant.rb +217 -0
- data/lib/docusign_maestro/models/ds_workflow_variable_from_step.rb +231 -0
- data/lib/docusign_maestro/models/ds_workflow_variable_from_variable.rb +231 -0
- data/lib/docusign_maestro/models/ds_workflow_variable_record.rb +175 -0
- data/lib/docusign_maestro/models/ds_workflow_variable_source_types_participant.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_variable_source_types_step.rb +28 -0
- data/lib/docusign_maestro/models/ds_workflow_variable_source_types_variable.rb +28 -0
- data/lib/docusign_maestro/models/e_sign_document_from_e_sign_template.rb +231 -0
- data/lib/docusign_maestro/models/e_sign_document_from_previous_step.rb +232 -0
- data/lib/docusign_maestro/models/e_sign_document_types_from_ds_template.rb +28 -0
- data/lib/docusign_maestro/models/e_sign_document_types_from_previous_step.rb +28 -0
- data/lib/docusign_maestro/models/e_sign_documents.rb +175 -0
- data/lib/docusign_maestro/models/e_sign_locale_policy.rb +174 -0
- data/lib/docusign_maestro/models/e_sign_signer.rb +247 -0
- data/lib/docusign_maestro/models/e_sign_tabs.rb +416 -0
- data/lib/docusign_maestro/models/e_sign_tabs_record.rb +251 -0
- data/lib/docusign_maestro/models/error_codes.rb +44 -0
- data/lib/docusign_maestro/models/error_response.rb +193 -0
- data/lib/docusign_maestro/models/event_types.rb +31 -0
- data/lib/docusign_maestro/models/get_configuration_instance_response.rb +201 -0
- data/lib/docusign_maestro/models/get_configuration_instances_response.rb +203 -0
- data/lib/docusign_maestro/models/get_configuration_instances_response_config_instances.rb +192 -0
- data/lib/docusign_maestro/models/http_types.rb +31 -0
- data/lib/docusign_maestro/models/invalid_workflow_response.rb +204 -0
- data/lib/docusign_maestro/models/last_deployed_id.rb +174 -0
- data/lib/docusign_maestro/models/new_or_updated_workflow_definition_response.rb +232 -0
- data/lib/docusign_maestro/models/number_or_variable.rb +175 -0
- data/lib/docusign_maestro/models/participant.rb +231 -0
- data/lib/docusign_maestro/models/participant_keys.rb +30 -0
- data/lib/docusign_maestro/models/progress_instance.rb +205 -0
- data/lib/docusign_maestro/models/record_string_boolean.rb +174 -0
- data/lib/docusign_maestro/models/record_string_or_variable_or_transformation.rb +175 -0
- data/lib/docusign_maestro/models/record_to_never.rb +174 -0
- data/lib/docusign_maestro/models/replication_status.rb +37 -0
- data/lib/docusign_maestro/models/started_by_instance.rb +237 -0
- data/lib/docusign_maestro/models/string_or_variable_or_transformation.rb +175 -0
- data/lib/docusign_maestro/models/success_message_response.rb +184 -0
- data/lib/docusign_maestro/models/template_id.rb +175 -0
- data/lib/docusign_maestro/models/trigger_payload.rb +211 -0
- data/lib/docusign_maestro/models/trigger_workflow_via_post_response.rb +194 -0
- data/lib/docusign_maestro/models/user_id.rb +175 -0
- data/lib/docusign_maestro/models/validation_errors.rb +202 -0
- data/lib/docusign_maestro/models/version_string.rb +174 -0
- data/lib/docusign_maestro/models/workflow_creator_id.rb +175 -0
- data/lib/docusign_maestro/models/workflow_date_time.rb +174 -0
- data/lib/docusign_maestro/models/workflow_definition.rb +315 -0
- data/lib/docusign_maestro/models/workflow_definition_list.rb +197 -0
- data/lib/docusign_maestro/models/workflow_definition_metadata.rb +272 -0
- data/lib/docusign_maestro/models/workflow_definition_with_id.rb +292 -0
- data/lib/docusign_maestro/models/workflow_delete_response.rb +202 -0
- data/lib/docusign_maestro/models/workflow_instance.rb +304 -0
- data/lib/docusign_maestro/models/workflow_instance_id.rb +175 -0
- data/lib/docusign_maestro/models/workflow_instance_map.rb +174 -0
- data/lib/docusign_maestro/models/workflow_instance_state.rb +30 -0
- data/lib/docusign_maestro/models/workflow_instances_list.rb +175 -0
- data/lib/docusign_maestro/models/workflow_metadata_status.rb +33 -0
- data/lib/docusign_maestro/models/workflow_step_error.rb +224 -0
- data/lib/docusign_maestro/models/workflow_step_error_error.rb +194 -0
- data/lib/docusign_maestro/models/workflow_step_history.rb +298 -0
- data/lib/docusign_maestro/models/workflow_step_history_list.rb +175 -0
- data/lib/docusign_maestro/models/workflow_step_history_state.rb +30 -0
- data/lib/docusign_maestro/version.rb +14 -0
- data/lib/docusign_maestro.rb +160 -0
- data/runLinter.sh +1 -0
- metadata +446 -0
@@ -0,0 +1,440 @@
|
|
1
|
+
=begin
|
2
|
+
#Maestro API
|
3
|
+
|
4
|
+
#Maestro authors and executes experiences that allow non-coders the ability to define Simple Business Process without having to write code and to deploy them seamlessly without having to have development expertise
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.0.0
|
7
|
+
Contact: devcenter@docusign.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
|
10
|
+
=end
|
11
|
+
|
12
|
+
require "uri"
|
13
|
+
|
14
|
+
module DocuSign_Maestro
|
15
|
+
|
16
|
+
class GetWorkflowDefinitionOptions
|
17
|
+
# deployed workflow definition metadata object id
|
18
|
+
attr_accessor :last_deployed_id
|
19
|
+
|
20
|
+
def self.default
|
21
|
+
@@default ||= GetWorkflowDefinitionOptions.new
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
class GetWorkflowDefinitionsOptions
|
26
|
+
# workflow definition metadata status
|
27
|
+
attr_accessor :status
|
28
|
+
|
29
|
+
def self.default
|
30
|
+
@@default ||= GetWorkflowDefinitionsOptions.new
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
|
35
|
+
class WorkflowManagementApi
|
36
|
+
attr_accessor :api_client
|
37
|
+
|
38
|
+
def initialize(api_client = WorkflowManagementApi.default)
|
39
|
+
@api_client = api_client
|
40
|
+
end
|
41
|
+
|
42
|
+
# Creates a new workflow definition.
|
43
|
+
# Creates a new workflow definition.
|
44
|
+
# @param account_id Account ID
|
45
|
+
# @param body Request Body to create a new workflow definition.
|
46
|
+
# @return [NewOrUpdatedWorkflowDefinitionResponse]
|
47
|
+
def create_workflow_definition(account_id, body)
|
48
|
+
data, _status_code, _headers = create_workflow_definition_with_http_info(account_id, body)
|
49
|
+
return data
|
50
|
+
end
|
51
|
+
|
52
|
+
# Creates a new workflow definition.
|
53
|
+
# Creates a new workflow definition.
|
54
|
+
# @param account_id Account ID
|
55
|
+
# @param body Request Body to create a new workflow definition.
|
56
|
+
# @return [Array<(NewOrUpdatedWorkflowDefinitionResponse, Fixnum, Hash)>] NewOrUpdatedWorkflowDefinitionResponse data, response status code and response headers
|
57
|
+
def create_workflow_definition_with_http_info(account_id, body)
|
58
|
+
if @api_client.config.debugging
|
59
|
+
@api_client.config.logger.debug "Calling API: WorkflowManagementApi.create_workflow_definition ..."
|
60
|
+
end
|
61
|
+
# verify the required parameter 'account_id' is set
|
62
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling WorkflowManagementApi.create_workflow_definition" if account_id.nil?
|
63
|
+
# verify the required parameter 'body' is set
|
64
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling WorkflowManagementApi.create_workflow_definition" if body.nil?
|
65
|
+
# resource path
|
66
|
+
local_var_path = "aow-manage/v1.0/management/accounts/{accountId}/workflowDefinitions".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s)
|
67
|
+
|
68
|
+
# query parameters
|
69
|
+
query_params = {}
|
70
|
+
|
71
|
+
# header parameters
|
72
|
+
header_params = {}
|
73
|
+
# HTTP header 'Accept' (if needed)
|
74
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
75
|
+
# HTTP header 'Content-Type'
|
76
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
77
|
+
|
78
|
+
# form parameters
|
79
|
+
form_params = {}
|
80
|
+
|
81
|
+
# http body (model)
|
82
|
+
post_body = @api_client.object_to_http_body(body)
|
83
|
+
auth_names = []
|
84
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
85
|
+
:header_params => header_params,
|
86
|
+
:query_params => query_params,
|
87
|
+
:form_params => form_params,
|
88
|
+
:body => post_body,
|
89
|
+
:auth_names => auth_names,
|
90
|
+
:return_type => 'NewOrUpdatedWorkflowDefinitionResponse')
|
91
|
+
if @api_client.config.debugging
|
92
|
+
@api_client.config.logger.debug "API called: WorkflowManagementApi#create_workflow_definition\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
93
|
+
end
|
94
|
+
return data, status_code, headers
|
95
|
+
end
|
96
|
+
|
97
|
+
# Deletes a workflow definition.
|
98
|
+
# Deletes a workflow definition.
|
99
|
+
# @param account_id Account ID
|
100
|
+
# @param workflow_definition_id Workflow Definition ID
|
101
|
+
# @return [WorkflowDeleteResponse]
|
102
|
+
def delete_workflow_definition(account_id, workflow_definition_id)
|
103
|
+
data, _status_code, _headers = delete_workflow_definition_with_http_info(account_id, workflow_definition_id)
|
104
|
+
return data
|
105
|
+
end
|
106
|
+
|
107
|
+
# Deletes a workflow definition.
|
108
|
+
# Deletes a workflow definition.
|
109
|
+
# @param account_id Account ID
|
110
|
+
# @param workflow_definition_id Workflow Definition ID
|
111
|
+
# @return [Array<(WorkflowDeleteResponse, Fixnum, Hash)>] WorkflowDeleteResponse data, response status code and response headers
|
112
|
+
def delete_workflow_definition_with_http_info(account_id, workflow_definition_id)
|
113
|
+
if @api_client.config.debugging
|
114
|
+
@api_client.config.logger.debug "Calling API: WorkflowManagementApi.delete_workflow_definition ..."
|
115
|
+
end
|
116
|
+
# verify the required parameter 'account_id' is set
|
117
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling WorkflowManagementApi.delete_workflow_definition" if account_id.nil?
|
118
|
+
# verify the required parameter 'workflow_definition_id' is set
|
119
|
+
fail ArgumentError, "Missing the required parameter 'workflow_definition_id' when calling WorkflowManagementApi.delete_workflow_definition" if workflow_definition_id.nil?
|
120
|
+
# resource path
|
121
|
+
local_var_path = "aow-manage/v1.0/management/accounts/{accountId}/workflowDefinitions/{workflowDefinitionId}".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s).sub('{' + 'workflowDefinitionId' + '}', workflow_definition_id.to_s)
|
122
|
+
|
123
|
+
# query parameters
|
124
|
+
query_params = {}
|
125
|
+
|
126
|
+
# header parameters
|
127
|
+
header_params = {}
|
128
|
+
# HTTP header 'Accept' (if needed)
|
129
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
130
|
+
# HTTP header 'Content-Type'
|
131
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
132
|
+
|
133
|
+
# form parameters
|
134
|
+
form_params = {}
|
135
|
+
|
136
|
+
# http body (model)
|
137
|
+
post_body = nil
|
138
|
+
auth_names = []
|
139
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
|
140
|
+
:header_params => header_params,
|
141
|
+
:query_params => query_params,
|
142
|
+
:form_params => form_params,
|
143
|
+
:body => post_body,
|
144
|
+
:auth_names => auth_names,
|
145
|
+
:return_type => 'WorkflowDeleteResponse')
|
146
|
+
if @api_client.config.debugging
|
147
|
+
@api_client.config.logger.debug "API called: WorkflowManagementApi#delete_workflow_definition\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
148
|
+
end
|
149
|
+
return data, status_code, headers
|
150
|
+
end
|
151
|
+
|
152
|
+
# Get Workflow Definition
|
153
|
+
# Returns a workflow definition.
|
154
|
+
# @param account_id Account ID
|
155
|
+
# @param workflow_definition_id Workflow Definition ID
|
156
|
+
# @param DocuSign_Maestro::GetWorkflowDefinitionOptions Options for modifying the behavior of the function.
|
157
|
+
# @return [WorkflowDefinitionWithId]
|
158
|
+
def get_workflow_definition(account_id, workflow_definition_id, options = DocuSign_Maestro::GetWorkflowDefinitionOptions.default)
|
159
|
+
data, _status_code, _headers = get_workflow_definition_with_http_info(account_id, workflow_definition_id, options)
|
160
|
+
return data
|
161
|
+
end
|
162
|
+
|
163
|
+
# Get Workflow Definition
|
164
|
+
# Returns a workflow definition.
|
165
|
+
# @param account_id Account ID
|
166
|
+
# @param workflow_definition_id Workflow Definition ID
|
167
|
+
# @param DocuSign_Maestro::GetWorkflowDefinitionOptions Options for modifying the behavior of the function.
|
168
|
+
# @return [Array<(WorkflowDefinitionWithId, Fixnum, Hash)>] WorkflowDefinitionWithId data, response status code and response headers
|
169
|
+
def get_workflow_definition_with_http_info(account_id, workflow_definition_id, options = DocuSign_Maestro::GetWorkflowDefinitionOptions.default)
|
170
|
+
if @api_client.config.debugging
|
171
|
+
@api_client.config.logger.debug "Calling API: WorkflowManagementApi.get_workflow_definition ..."
|
172
|
+
end
|
173
|
+
# verify the required parameter 'account_id' is set
|
174
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling WorkflowManagementApi.get_workflow_definition" if account_id.nil?
|
175
|
+
# verify the required parameter 'workflow_definition_id' is set
|
176
|
+
fail ArgumentError, "Missing the required parameter 'workflow_definition_id' when calling WorkflowManagementApi.get_workflow_definition" if workflow_definition_id.nil?
|
177
|
+
# resource path
|
178
|
+
local_var_path = "aow-manage/v1.0/management/accounts/{accountId}/workflowDefinitions/{workflowDefinitionId}".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s).sub('{' + 'workflowDefinitionId' + '}', workflow_definition_id.to_s)
|
179
|
+
|
180
|
+
# query parameters
|
181
|
+
query_params = {}
|
182
|
+
query_params[:'lastDeployedId'] = options.last_deployed_id if !options.last_deployed_id.nil?
|
183
|
+
|
184
|
+
# header parameters
|
185
|
+
header_params = {}
|
186
|
+
# HTTP header 'Accept' (if needed)
|
187
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
188
|
+
# HTTP header 'Content-Type'
|
189
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
190
|
+
|
191
|
+
# form parameters
|
192
|
+
form_params = {}
|
193
|
+
|
194
|
+
# http body (model)
|
195
|
+
post_body = nil
|
196
|
+
auth_names = []
|
197
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
198
|
+
:header_params => header_params,
|
199
|
+
:query_params => query_params,
|
200
|
+
:form_params => form_params,
|
201
|
+
:body => post_body,
|
202
|
+
:auth_names => auth_names,
|
203
|
+
:return_type => 'WorkflowDefinitionWithId')
|
204
|
+
if @api_client.config.debugging
|
205
|
+
@api_client.config.logger.debug "API called: WorkflowManagementApi#get_workflow_definition\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
206
|
+
end
|
207
|
+
return data, status_code, headers
|
208
|
+
end
|
209
|
+
|
210
|
+
# Gets configuration instances
|
211
|
+
# Returns a list of configuration instances for a workflow definition
|
212
|
+
# @param account_id Account ID
|
213
|
+
# @param workflow_definition_id Workflow Definition ID
|
214
|
+
# @return [GetConfigurationInstancesResponse]
|
215
|
+
def get_workflow_definition_config_instances(account_id, workflow_definition_id)
|
216
|
+
data, _status_code, _headers = get_workflow_definition_config_instances_with_http_info(account_id, workflow_definition_id)
|
217
|
+
return data
|
218
|
+
end
|
219
|
+
|
220
|
+
# Gets configuration instances
|
221
|
+
# Returns a list of configuration instances for a workflow definition
|
222
|
+
# @param account_id Account ID
|
223
|
+
# @param workflow_definition_id Workflow Definition ID
|
224
|
+
# @return [Array<(GetConfigurationInstancesResponse, Fixnum, Hash)>] GetConfigurationInstancesResponse data, response status code and response headers
|
225
|
+
def get_workflow_definition_config_instances_with_http_info(account_id, workflow_definition_id)
|
226
|
+
if @api_client.config.debugging
|
227
|
+
@api_client.config.logger.debug "Calling API: WorkflowManagementApi.get_workflow_definition_config_instances ..."
|
228
|
+
end
|
229
|
+
# verify the required parameter 'account_id' is set
|
230
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling WorkflowManagementApi.get_workflow_definition_config_instances" if account_id.nil?
|
231
|
+
# verify the required parameter 'workflow_definition_id' is set
|
232
|
+
fail ArgumentError, "Missing the required parameter 'workflow_definition_id' when calling WorkflowManagementApi.get_workflow_definition_config_instances" if workflow_definition_id.nil?
|
233
|
+
# resource path
|
234
|
+
local_var_path = "aow-manage/v1.0/management/accounts/{accountId}/workflowDefinitions/{workflowDefinitionId}/configInstances".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s).sub('{' + 'workflowDefinitionId' + '}', workflow_definition_id.to_s)
|
235
|
+
|
236
|
+
# query parameters
|
237
|
+
query_params = {}
|
238
|
+
|
239
|
+
# header parameters
|
240
|
+
header_params = {}
|
241
|
+
# HTTP header 'Accept' (if needed)
|
242
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
243
|
+
# HTTP header 'Content-Type'
|
244
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
245
|
+
|
246
|
+
# form parameters
|
247
|
+
form_params = {}
|
248
|
+
|
249
|
+
# http body (model)
|
250
|
+
post_body = nil
|
251
|
+
auth_names = []
|
252
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
253
|
+
:header_params => header_params,
|
254
|
+
:query_params => query_params,
|
255
|
+
:form_params => form_params,
|
256
|
+
:body => post_body,
|
257
|
+
:auth_names => auth_names,
|
258
|
+
:return_type => 'GetConfigurationInstancesResponse')
|
259
|
+
if @api_client.config.debugging
|
260
|
+
@api_client.config.logger.debug "API called: WorkflowManagementApi#get_workflow_definition_config_instances\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
261
|
+
end
|
262
|
+
return data, status_code, headers
|
263
|
+
end
|
264
|
+
|
265
|
+
# Get Workflow Definitions metadata
|
266
|
+
# Returns a list of workflow definitions' metadata.
|
267
|
+
# @param account_id Account ID
|
268
|
+
# @param DocuSign_Maestro::GetWorkflowDefinitionsOptions Options for modifying the behavior of the function.
|
269
|
+
# @return [WorkflowDefinitionList]
|
270
|
+
def get_workflow_definitions(account_id, options = DocuSign_Maestro::GetWorkflowDefinitionsOptions.default)
|
271
|
+
data, _status_code, _headers = get_workflow_definitions_with_http_info(account_id, options)
|
272
|
+
return data
|
273
|
+
end
|
274
|
+
|
275
|
+
# Get Workflow Definitions metadata
|
276
|
+
# Returns a list of workflow definitions' metadata.
|
277
|
+
# @param account_id Account ID
|
278
|
+
# @param DocuSign_Maestro::GetWorkflowDefinitionsOptions Options for modifying the behavior of the function.
|
279
|
+
# @return [Array<(WorkflowDefinitionList, Fixnum, Hash)>] WorkflowDefinitionList data, response status code and response headers
|
280
|
+
def get_workflow_definitions_with_http_info(account_id, options = DocuSign_Maestro::GetWorkflowDefinitionsOptions.default)
|
281
|
+
if @api_client.config.debugging
|
282
|
+
@api_client.config.logger.debug "Calling API: WorkflowManagementApi.get_workflow_definitions ..."
|
283
|
+
end
|
284
|
+
# verify the required parameter 'account_id' is set
|
285
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling WorkflowManagementApi.get_workflow_definitions" if account_id.nil?
|
286
|
+
if options.status && !['active', 'inactive', 'publishing', 'unpublishing', 'archived', 'archiving'].include?(options.status)
|
287
|
+
fail ArgumentError, 'invalid value for "status", must be one of active, inactive, publishing, unpublishing, archived, archiving'
|
288
|
+
end
|
289
|
+
# resource path
|
290
|
+
local_var_path = "aow-manage/v1.0/management/accounts/{accountId}/workflowDefinitions".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s)
|
291
|
+
|
292
|
+
# query parameters
|
293
|
+
query_params = {}
|
294
|
+
query_params[:'status'] = options.status if !options.status.nil?
|
295
|
+
|
296
|
+
# header parameters
|
297
|
+
header_params = {}
|
298
|
+
# HTTP header 'Accept' (if needed)
|
299
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
300
|
+
# HTTP header 'Content-Type'
|
301
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
302
|
+
|
303
|
+
# form parameters
|
304
|
+
form_params = {}
|
305
|
+
|
306
|
+
# http body (model)
|
307
|
+
post_body = nil
|
308
|
+
auth_names = []
|
309
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
310
|
+
:header_params => header_params,
|
311
|
+
:query_params => query_params,
|
312
|
+
:form_params => form_params,
|
313
|
+
:body => post_body,
|
314
|
+
:auth_names => auth_names,
|
315
|
+
:return_type => 'WorkflowDefinitionList')
|
316
|
+
if @api_client.config.debugging
|
317
|
+
@api_client.config.logger.debug "API called: WorkflowManagementApi#get_workflow_definitions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
318
|
+
end
|
319
|
+
return data, status_code, headers
|
320
|
+
end
|
321
|
+
|
322
|
+
# Publishes or unpublishes a workflow definition.
|
323
|
+
# Publishes or unpublishes a workflow definition.
|
324
|
+
# @param account_id Account ID
|
325
|
+
# @param workflow_definition_id Workflow Definition ID
|
326
|
+
# @param body Request Body to publish or unpublish a workflow definition.
|
327
|
+
# @return [DeployResponse]
|
328
|
+
def publish_or_un_publish_workflow_definition(account_id, workflow_definition_id, body)
|
329
|
+
data, _status_code, _headers = publish_or_un_publish_workflow_definition_with_http_info(account_id, workflow_definition_id, body)
|
330
|
+
return data
|
331
|
+
end
|
332
|
+
|
333
|
+
# Publishes or unpublishes a workflow definition.
|
334
|
+
# Publishes or unpublishes a workflow definition.
|
335
|
+
# @param account_id Account ID
|
336
|
+
# @param workflow_definition_id Workflow Definition ID
|
337
|
+
# @param body Request Body to publish or unpublish a workflow definition.
|
338
|
+
# @return [Array<(DeployResponse, Fixnum, Hash)>] DeployResponse data, response status code and response headers
|
339
|
+
def publish_or_un_publish_workflow_definition_with_http_info(account_id, workflow_definition_id, body)
|
340
|
+
if @api_client.config.debugging
|
341
|
+
@api_client.config.logger.debug "Calling API: WorkflowManagementApi.publish_or_un_publish_workflow_definition ..."
|
342
|
+
end
|
343
|
+
# verify the required parameter 'account_id' is set
|
344
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling WorkflowManagementApi.publish_or_un_publish_workflow_definition" if account_id.nil?
|
345
|
+
# verify the required parameter 'workflow_definition_id' is set
|
346
|
+
fail ArgumentError, "Missing the required parameter 'workflow_definition_id' when calling WorkflowManagementApi.publish_or_un_publish_workflow_definition" if workflow_definition_id.nil?
|
347
|
+
# verify the required parameter 'body' is set
|
348
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling WorkflowManagementApi.publish_or_un_publish_workflow_definition" if body.nil?
|
349
|
+
# resource path
|
350
|
+
local_var_path = "aow-manage/v1.0/management/accounts/{accountId}/workflowDefinitions/{workflowDefinitionId}/publish".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s).sub('{' + 'workflowDefinitionId' + '}', workflow_definition_id.to_s)
|
351
|
+
|
352
|
+
# query parameters
|
353
|
+
query_params = {}
|
354
|
+
|
355
|
+
# header parameters
|
356
|
+
header_params = {}
|
357
|
+
# HTTP header 'Accept' (if needed)
|
358
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
359
|
+
# HTTP header 'Content-Type'
|
360
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
361
|
+
|
362
|
+
# form parameters
|
363
|
+
form_params = {}
|
364
|
+
|
365
|
+
# http body (model)
|
366
|
+
post_body = @api_client.object_to_http_body(body)
|
367
|
+
auth_names = []
|
368
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
369
|
+
:header_params => header_params,
|
370
|
+
:query_params => query_params,
|
371
|
+
:form_params => form_params,
|
372
|
+
:body => post_body,
|
373
|
+
:auth_names => auth_names,
|
374
|
+
:return_type => 'DeployResponse')
|
375
|
+
if @api_client.config.debugging
|
376
|
+
@api_client.config.logger.debug "API called: WorkflowManagementApi#publish_or_un_publish_workflow_definition\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
377
|
+
end
|
378
|
+
return data, status_code, headers
|
379
|
+
end
|
380
|
+
|
381
|
+
# Updates a workflow definition.
|
382
|
+
# Updates a workflow definition.
|
383
|
+
# @param account_id Account ID
|
384
|
+
# @param workflow_definition_id Workflow Definition ID
|
385
|
+
# @param body Request Body to update a workflow definition.
|
386
|
+
# @return [NewOrUpdatedWorkflowDefinitionResponse]
|
387
|
+
def update_workflow_definition(account_id, workflow_definition_id, body)
|
388
|
+
data, _status_code, _headers = update_workflow_definition_with_http_info(account_id, workflow_definition_id, body)
|
389
|
+
return data
|
390
|
+
end
|
391
|
+
|
392
|
+
# Updates a workflow definition.
|
393
|
+
# Updates a workflow definition.
|
394
|
+
# @param account_id Account ID
|
395
|
+
# @param workflow_definition_id Workflow Definition ID
|
396
|
+
# @param body Request Body to update a workflow definition.
|
397
|
+
# @return [Array<(NewOrUpdatedWorkflowDefinitionResponse, Fixnum, Hash)>] NewOrUpdatedWorkflowDefinitionResponse data, response status code and response headers
|
398
|
+
def update_workflow_definition_with_http_info(account_id, workflow_definition_id, body)
|
399
|
+
if @api_client.config.debugging
|
400
|
+
@api_client.config.logger.debug "Calling API: WorkflowManagementApi.update_workflow_definition ..."
|
401
|
+
end
|
402
|
+
# verify the required parameter 'account_id' is set
|
403
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling WorkflowManagementApi.update_workflow_definition" if account_id.nil?
|
404
|
+
# verify the required parameter 'workflow_definition_id' is set
|
405
|
+
fail ArgumentError, "Missing the required parameter 'workflow_definition_id' when calling WorkflowManagementApi.update_workflow_definition" if workflow_definition_id.nil?
|
406
|
+
# verify the required parameter 'body' is set
|
407
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling WorkflowManagementApi.update_workflow_definition" if body.nil?
|
408
|
+
# resource path
|
409
|
+
local_var_path = "aow-manage/v1.0/management/accounts/{accountId}/workflowDefinitions/{workflowDefinitionId}".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s).sub('{' + 'workflowDefinitionId' + '}', workflow_definition_id.to_s)
|
410
|
+
|
411
|
+
# query parameters
|
412
|
+
query_params = {}
|
413
|
+
|
414
|
+
# header parameters
|
415
|
+
header_params = {}
|
416
|
+
# HTTP header 'Accept' (if needed)
|
417
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
418
|
+
# HTTP header 'Content-Type'
|
419
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
420
|
+
|
421
|
+
# form parameters
|
422
|
+
form_params = {}
|
423
|
+
|
424
|
+
# http body (model)
|
425
|
+
post_body = @api_client.object_to_http_body(body)
|
426
|
+
auth_names = []
|
427
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
|
428
|
+
:header_params => header_params,
|
429
|
+
:query_params => query_params,
|
430
|
+
:form_params => form_params,
|
431
|
+
:body => post_body,
|
432
|
+
:auth_names => auth_names,
|
433
|
+
:return_type => 'NewOrUpdatedWorkflowDefinitionResponse')
|
434
|
+
if @api_client.config.debugging
|
435
|
+
@api_client.config.logger.debug "API called: WorkflowManagementApi#update_workflow_definition\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
436
|
+
end
|
437
|
+
return data, status_code, headers
|
438
|
+
end
|
439
|
+
end
|
440
|
+
end
|
@@ -0,0 +1,95 @@
|
|
1
|
+
=begin
|
2
|
+
#Maestro API
|
3
|
+
|
4
|
+
#Maestro authors and executes experiences that allow non-coders the ability to define Simple Business Process without having to write code and to deploy them seamlessly without having to have development expertise
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.0.0
|
7
|
+
Contact: devcenter@docusign.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
|
10
|
+
=end
|
11
|
+
|
12
|
+
require "uri"
|
13
|
+
|
14
|
+
module DocuSign_Maestro
|
15
|
+
|
16
|
+
class TriggerWorkflowOptions
|
17
|
+
# Managed Token Id registered with DS Account Server
|
18
|
+
attr_accessor :mtid
|
19
|
+
|
20
|
+
# Managed Token Secret registered with DS Account Server
|
21
|
+
attr_accessor :mtsec
|
22
|
+
|
23
|
+
def self.default
|
24
|
+
@@default ||= TriggerWorkflowOptions.new
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
|
29
|
+
class WorkflowTriggerApi
|
30
|
+
attr_accessor :api_client
|
31
|
+
|
32
|
+
def initialize(api_client = WorkflowTriggerApi.default)
|
33
|
+
@api_client = api_client
|
34
|
+
end
|
35
|
+
|
36
|
+
# Creates a new workflow instance after authenticating with DS Account Server
|
37
|
+
# Creates a new workflow instance after authenticating with DS Account Server
|
38
|
+
# @param account_id Account ID
|
39
|
+
# @param body JSON payload that will be passed to the triggered workflow
|
40
|
+
# @param DocuSign_Maestro::TriggerWorkflowOptions Options for modifying the behavior of the function.
|
41
|
+
# @return [TriggerWorkflowViaPostResponse]
|
42
|
+
def trigger_workflow(account_id, body, options = DocuSign_Maestro::TriggerWorkflowOptions.default)
|
43
|
+
data, _status_code, _headers = trigger_workflow_with_http_info(account_id, body, options)
|
44
|
+
return data
|
45
|
+
end
|
46
|
+
|
47
|
+
# Creates a new workflow instance after authenticating with DS Account Server
|
48
|
+
# Creates a new workflow instance after authenticating with DS Account Server
|
49
|
+
# @param account_id Account ID
|
50
|
+
# @param body JSON payload that will be passed to the triggered workflow
|
51
|
+
# @param DocuSign_Maestro::TriggerWorkflowOptions Options for modifying the behavior of the function.
|
52
|
+
# @return [Array<(TriggerWorkflowViaPostResponse, Fixnum, Hash)>] TriggerWorkflowViaPostResponse data, response status code and response headers
|
53
|
+
def trigger_workflow_with_http_info(account_id, body, options = DocuSign_Maestro::TriggerWorkflowOptions.default)
|
54
|
+
if @api_client.config.debugging
|
55
|
+
@api_client.config.logger.debug "Calling API: WorkflowTriggerApi.trigger_workflow ..."
|
56
|
+
end
|
57
|
+
# verify the required parameter 'account_id' is set
|
58
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling WorkflowTriggerApi.trigger_workflow" if account_id.nil?
|
59
|
+
# verify the required parameter 'body' is set
|
60
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling WorkflowTriggerApi.trigger_workflow" if body.nil?
|
61
|
+
# resource path
|
62
|
+
local_var_path = "aow-auth/v1.0/accounts/{accountId}/workflows/trigger".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s)
|
63
|
+
|
64
|
+
# query parameters
|
65
|
+
query_params = {}
|
66
|
+
query_params[:'mtid'] = options.mtid if !options.mtid.nil?
|
67
|
+
query_params[:'mtsec'] = options.mtsec if !options.mtsec.nil?
|
68
|
+
|
69
|
+
# header parameters
|
70
|
+
header_params = {}
|
71
|
+
# HTTP header 'Accept' (if needed)
|
72
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
73
|
+
# HTTP header 'Content-Type'
|
74
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
75
|
+
|
76
|
+
# form parameters
|
77
|
+
form_params = {}
|
78
|
+
|
79
|
+
# http body (model)
|
80
|
+
post_body = @api_client.object_to_http_body(body)
|
81
|
+
auth_names = []
|
82
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
83
|
+
:header_params => header_params,
|
84
|
+
:query_params => query_params,
|
85
|
+
:form_params => form_params,
|
86
|
+
:body => post_body,
|
87
|
+
:auth_names => auth_names,
|
88
|
+
:return_type => 'TriggerWorkflowViaPostResponse')
|
89
|
+
if @api_client.config.debugging
|
90
|
+
@api_client.config.logger.debug "API called: WorkflowTriggerApi#trigger_workflow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
91
|
+
end
|
92
|
+
return data, status_code, headers
|
93
|
+
end
|
94
|
+
end
|
95
|
+
end
|