api-sdk-rb 1.11.66 → 1.11.133

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 (430) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +294 -285
  3. data/docs/{GetPartnerCreditTransactions200Response.md → AccountCreditTransactionListResponse.md} +2 -2
  4. data/docs/AdapterConnection.md +7 -1
  5. data/docs/{GetUserAdapterConnections200Response.md → AdapterConnectionListResponse.md} +2 -2
  6. data/docs/{RemoveUserAdapterConnection200Response.md → AdapterConnectionRemovalResponse.md} +2 -2
  7. data/docs/{SetUserAdapterConnection200Response.md → AdapterConnectionResponse.md} +2 -2
  8. data/docs/{AddAiAnswersKnowledgeDocument201Response.md → AiAnswersKnowledgeDocumentResponse.md} +2 -2
  9. data/docs/BrandColor.md +22 -0
  10. data/docs/BrandFont.md +24 -0
  11. data/docs/BrandKitApi.md +593 -0
  12. data/docs/BrandKitAssetView.md +42 -0
  13. data/docs/BrandKitFigmaSource.md +26 -0
  14. data/docs/BrandKitTokens.md +26 -0
  15. data/docs/BrandKitTokensFonts.md +24 -0
  16. data/docs/BrandKitView.md +36 -0
  17. data/docs/BrandKitViewOwner.md +20 -0
  18. data/docs/{OperationsIdGetResponse.md → BrandKitViewResponse.md} +3 -3
  19. data/docs/BrandSpacing.md +32 -0
  20. data/docs/BrandTextStyle.md +22 -0
  21. data/docs/CanvasesApi.md +45 -45
  22. data/docs/Composition.md +5 -1
  23. data/docs/{CreateCompositionDatabaseRecord201Response.md → CompositionDatabaseRecordResponse.md} +2 -2
  24. data/docs/CompositionLastEditedBy.md +20 -0
  25. data/docs/CompositionsApi.md +821 -473
  26. data/docs/ConfirmAdapterConnectionRequest.md +18 -0
  27. data/docs/{CreateCompositionContentItem201Response.md → ContentItemWriteResultResponse.md} +2 -2
  28. data/docs/CreateWidget201ResponseData.md +2 -4
  29. data/docs/CreateWorkspaceWorkflowFromPresetRequest.md +20 -0
  30. data/docs/CreateWorkspaceWorkflowRequest.md +22 -0
  31. data/docs/CreditsApi.md +20 -20
  32. data/docs/DeleteUpload200Response.md +22 -0
  33. data/docs/{UploadsIdDelete200ResponseData.md → DeleteUpload200ResponseData.md} +2 -2
  34. data/docs/DeleteWorkspaceWorkflow200Response.md +22 -0
  35. data/docs/{GetPartnerDesignDefaults200Response.md → DesignDefaultsResponse.md} +2 -2
  36. data/docs/EntitlementsApi.md +18 -18
  37. data/docs/GetOperationResponse.md +22 -0
  38. data/docs/{OperationsIdGetResponseData.md → GetOperationResponseData.md} +3 -3
  39. data/docs/GetOperationResponseDataMetadata.md +24 -0
  40. data/docs/GetPublicCompositionEmbed200Response.md +7 -1
  41. data/docs/GetPublicCompositionEmbed200ResponseAdapters.md +20 -0
  42. data/docs/GetPublicCompositionEmbed200ResponseAdaptersCaptcha.md +18 -0
  43. data/docs/GetPublicCompositionEmbed200ResponseEntries.md +20 -0
  44. data/docs/GetPublicCompositionEmbed200ResponseMedia.md +18 -0
  45. data/docs/GetWorkspaceWorkflowStats200Response.md +22 -0
  46. data/docs/GetWorkspaceWorkflowVersion200Response.md +22 -0
  47. data/docs/InvoicesApi.md +9 -9
  48. data/docs/ListPartnerWorkflowPresets200Response.md +22 -0
  49. data/docs/{UploadsGet200Response.md → ListUploads200Response.md} +2 -2
  50. data/docs/ListWorkspaceWorkflowCompositionOptions200Response.md +22 -0
  51. data/docs/ListWorkspaceWorkflowPresets200Response.md +22 -0
  52. data/docs/ListWorkspaceWorkflowVersions200Response.md +22 -0
  53. data/docs/ListWorkspaceWorkflows200Response.md +22 -0
  54. data/docs/{GetManagedUserLimits200Response.md → ManagedUserLimitsResponse.md} +2 -2
  55. data/docs/{DeleteManagedUser200Response.md → ManagedUserRemovalResponse.md} +2 -2
  56. data/docs/ManagedUsersApi.md +261 -171
  57. data/docs/NewComposition.md +1 -1
  58. data/docs/NewEditorSession.md +1 -1
  59. data/docs/OfferWorkflowPresetRequest.md +24 -0
  60. data/docs/OfferedWorkflowPreset.md +40 -0
  61. data/docs/OfferedWorkflowPresetList.md +18 -0
  62. data/docs/OfferedWorkflowPresetWidget.md +22 -0
  63. data/docs/OperationsApi.md +11 -11
  64. data/docs/PartnerCustomization.md +2 -2
  65. data/docs/PartnerNotification.md +1 -1
  66. data/docs/PartnersApi.md +644 -352
  67. data/docs/PatchBrandKitAssetRequest.md +24 -0
  68. data/docs/PatchBrandKitRequest.md +30 -0
  69. data/docs/PatchBrandKitRequestFonts.md +24 -0
  70. data/docs/PatchBrandKitRequestSpacing.md +32 -0
  71. data/docs/PostBrandKitIconRequest.md +20 -0
  72. data/docs/PublicEmbedApi.md +324 -58
  73. data/docs/PublicWorkflow.md +36 -0
  74. data/docs/PublicWorkflowEventsAccepted.md +22 -0
  75. data/docs/PublicWorkflowEventsRequest.md +24 -0
  76. data/docs/PublicWorkflowEventsRequestEventsInner.md +24 -0
  77. data/docs/PublicWorkflowEventsRequestHeightsInner.md +20 -0
  78. data/docs/{CreateCompositionFromWidget201Response.md → PublicWorkflowResponse.md} +3 -3
  79. data/docs/PublicWorkflowTranslation.md +20 -0
  80. data/docs/PublishWorkspaceWorkflow200Response.md +22 -0
  81. data/docs/PublishWorkspaceWorkflowRequest.md +18 -0
  82. data/docs/PutBrandKitRequest.md +22 -0
  83. data/docs/RemovePartnerWorkflowPreset200Response.md +22 -0
  84. data/docs/ReportPublicWorkflowEvents200Response.md +22 -0
  85. data/docs/SaveWorkspaceWorkflowRequest.md +24 -0
  86. data/docs/SetAdapterConnectionRequest.md +1 -1
  87. data/docs/SetPartnerWorkflowPreset200Response.md +22 -0
  88. data/docs/TokensApi.md +11 -9
  89. data/docs/UpdateComposition.md +1 -1
  90. data/docs/Upload.md +1 -1
  91. data/docs/UploadLimits.md +3 -3
  92. data/docs/UploadsApi.md +85 -85
  93. data/docs/UsersApi.md +191 -115
  94. data/docs/Widget.md +2 -4
  95. data/docs/WidgetClarification.md +22 -0
  96. data/docs/WidgetClarificationOption.md +22 -0
  97. data/docs/WidgetClarificationQuestion.md +26 -0
  98. data/docs/WidgetNextStep.md +24 -0
  99. data/docs/WidgetPlan.md +26 -0
  100. data/docs/WidgetPlanDecisions.md +32 -0
  101. data/docs/WidgetPlanDecisionsAdaptersInner.md +20 -0
  102. data/docs/WidgetPlanDecisionsLibrariesInner.md +22 -0
  103. data/docs/WidgetPlanDecisionsResponsive.md +22 -0
  104. data/docs/WidgetPlanTask.md +24 -0
  105. data/docs/WidgetsApi.md +38 -38
  106. data/docs/Workflow.md +50 -0
  107. data/docs/WorkflowCompositionAction.md +24 -0
  108. data/docs/WorkflowCompositionField.md +24 -0
  109. data/docs/WorkflowCompositionOption.md +30 -0
  110. data/docs/WorkflowCompositionOptionActions.md +22 -0
  111. data/docs/WorkflowCompositionOptionInputs.md +24 -0
  112. data/docs/WorkflowCompositionOptions.md +24 -0
  113. data/docs/WorkflowConditionCase.md +24 -0
  114. data/docs/WorkflowConditionTest.md +22 -0
  115. data/docs/WorkflowCounter.md +20 -0
  116. data/docs/WorkflowDetail.md +60 -0
  117. data/docs/WorkflowDetailAllOfLastEditedBy.md +20 -0
  118. data/docs/WorkflowDetailResponse.md +22 -0
  119. data/docs/WorkflowEdge.md +24 -0
  120. data/docs/WorkflowFailureReason.md +15 -0
  121. data/docs/WorkflowFailureReasonCounter.md +22 -0
  122. data/docs/WorkflowFieldReference.md +22 -0
  123. data/docs/WorkflowGraph.md +22 -0
  124. data/docs/WorkflowIssue.md +28 -0
  125. data/docs/WorkflowList.md +24 -0
  126. data/docs/WorkflowNode.md +30 -0
  127. data/docs/WorkflowNodePosition.md +20 -0
  128. data/docs/WorkflowPresetChoice.md +26 -0
  129. data/docs/WorkflowPresetChoices.md +18 -0
  130. data/docs/WorkflowPresetRemoval.md +18 -0
  131. data/docs/WorkflowPresetWidget.md +20 -0
  132. data/docs/WorkflowPublishResult.md +22 -0
  133. data/docs/WorkflowRemoved.md +18 -0
  134. data/docs/WorkflowResponse.md +22 -0
  135. data/docs/WorkflowSchedule.md +24 -0
  136. data/docs/WorkflowStats.md +34 -0
  137. data/docs/WorkflowStatus.md +15 -0
  138. data/docs/WorkflowTrigger.md +28 -0
  139. data/docs/WorkflowTriggerValuesInner.md +20 -0
  140. data/docs/WorkflowVersion.md +28 -0
  141. data/docs/WorkflowVersionDetail.md +32 -0
  142. data/docs/WorkflowVersionList.md +18 -0
  143. data/docs/WorkflowVersionPublishedBy.md +20 -0
  144. data/docs/WorkflowsApi.md +1527 -0
  145. data/lib/api-sdk-rb/api/brand_kit_api.rb +581 -0
  146. data/lib/api-sdk-rb/api/canvases_api.rb +39 -39
  147. data/lib/api-sdk-rb/api/compositions_api.rb +993 -565
  148. data/lib/api-sdk-rb/api/credits_api.rb +20 -20
  149. data/lib/api-sdk-rb/api/entitlements_api.rb +14 -14
  150. data/lib/api-sdk-rb/api/invoices_api.rb +10 -10
  151. data/lib/api-sdk-rb/api/managed_users_api.rb +278 -172
  152. data/lib/api-sdk-rb/api/operations_api.rb +10 -10
  153. data/lib/api-sdk-rb/api/partners_api.rb +668 -352
  154. data/lib/api-sdk-rb/api/public_embed_api.rb +339 -62
  155. data/lib/api-sdk-rb/api/tokens_api.rb +8 -6
  156. data/lib/api-sdk-rb/api/uploads_api.rb +96 -96
  157. data/lib/api-sdk-rb/api/users_api.rb +213 -119
  158. data/lib/api-sdk-rb/api/widgets_api.rb +40 -40
  159. data/lib/api-sdk-rb/api/workflows_api.rb +1775 -0
  160. data/lib/api-sdk-rb/configuration.rb +11 -23
  161. data/lib/api-sdk-rb/models/{get_user_adapter_connections200_response.rb → account_credit_transaction_list_response.rb} +4 -4
  162. data/lib/api-sdk-rb/models/adapter_connection.rb +48 -5
  163. data/lib/api-sdk-rb/models/{get_partner_credit_transactions200_response.rb → adapter_connection_list_response.rb} +4 -4
  164. data/lib/api-sdk-rb/models/adapter_connection_removal_response.rb +246 -0
  165. data/lib/api-sdk-rb/models/{delete_managed_user200_response.rb → adapter_connection_response.rb} +4 -4
  166. data/lib/api-sdk-rb/models/ai_answers_knowledge_document_response.rb +246 -0
  167. data/lib/api-sdk-rb/models/brand_color.rb +329 -0
  168. data/lib/api-sdk-rb/models/brand_font.rb +357 -0
  169. data/lib/api-sdk-rb/models/brand_kit_asset_view.rb +409 -0
  170. data/lib/api-sdk-rb/models/brand_kit_figma_source.rb +277 -0
  171. data/lib/api-sdk-rb/models/brand_kit_tokens.rb +335 -0
  172. data/lib/api-sdk-rb/models/brand_kit_tokens_fonts.rb +241 -0
  173. data/lib/api-sdk-rb/models/brand_kit_view.rb +344 -0
  174. data/lib/api-sdk-rb/models/brand_kit_view_owner.rb +267 -0
  175. data/lib/api-sdk-rb/models/brand_kit_view_response.rb +247 -0
  176. data/lib/api-sdk-rb/models/brand_spacing.rb +557 -0
  177. data/lib/api-sdk-rb/models/brand_text_style.rb +344 -0
  178. data/lib/api-sdk-rb/models/composition.rb +26 -5
  179. data/lib/api-sdk-rb/models/{create_composition_database_record201_response.rb → composition_database_record_response.rb} +3 -3
  180. data/lib/api-sdk-rb/models/composition_last_edited_by.rb +242 -0
  181. data/lib/api-sdk-rb/models/confirm_adapter_connection_request.rb +241 -0
  182. data/lib/api-sdk-rb/models/content_item_write_result_response.rb +246 -0
  183. data/lib/api-sdk-rb/models/create_widget201_response_data.rb +9 -20
  184. data/lib/api-sdk-rb/models/create_workspace_workflow_from_preset_request.rb +278 -0
  185. data/lib/api-sdk-rb/models/create_workspace_workflow_request.rb +271 -0
  186. data/lib/api-sdk-rb/models/{operations_id_get_response.rb → delete_upload200_response.rb} +4 -5
  187. data/lib/api-sdk-rb/models/{uploads_id_delete200_response_data.rb → delete_upload200_response_data.rb} +3 -3
  188. data/lib/api-sdk-rb/models/delete_workspace_workflow200_response.rb +246 -0
  189. data/lib/api-sdk-rb/models/design_defaults_response.rb +246 -0
  190. data/lib/api-sdk-rb/models/get_operation_response.rb +247 -0
  191. data/lib/api-sdk-rb/models/{operations_id_get_response_data.rb → get_operation_response_data.rb} +5 -8
  192. data/lib/api-sdk-rb/models/get_operation_response_data_metadata.rb +283 -0
  193. data/lib/api-sdk-rb/models/get_public_composition_embed200_response.rb +29 -2
  194. data/lib/api-sdk-rb/models/get_public_composition_embed200_response_adapters.rb +225 -0
  195. data/lib/api-sdk-rb/models/get_public_composition_embed200_response_adapters_captcha.rb +216 -0
  196. data/lib/api-sdk-rb/models/get_public_composition_embed200_response_entries.rb +224 -0
  197. data/lib/api-sdk-rb/models/get_public_composition_embed200_response_media.rb +216 -0
  198. data/lib/api-sdk-rb/models/get_workspace_workflow_stats200_response.rb +246 -0
  199. data/lib/api-sdk-rb/models/{create_composition_from_widget201_response.rb → get_workspace_workflow_version200_response.rb} +4 -4
  200. data/lib/api-sdk-rb/models/list_partner_workflow_presets200_response.rb +246 -0
  201. data/lib/api-sdk-rb/models/{uploads_get200_response.rb → list_uploads200_response.rb} +3 -3
  202. data/lib/api-sdk-rb/models/list_workspace_workflow_composition_options200_response.rb +246 -0
  203. data/lib/api-sdk-rb/models/{create_composition_content_item201_response.rb → list_workspace_workflow_presets200_response.rb} +4 -4
  204. data/lib/api-sdk-rb/models/{add_ai_answers_knowledge_document201_response.rb → list_workspace_workflow_versions200_response.rb} +4 -4
  205. data/lib/api-sdk-rb/models/list_workspace_workflows200_response.rb +246 -0
  206. data/lib/api-sdk-rb/models/{get_managed_user_limits200_response.rb → managed_user_limits_response.rb} +3 -3
  207. data/lib/api-sdk-rb/models/{uploads_id_delete200_response.rb → managed_user_removal_response.rb} +4 -4
  208. data/lib/api-sdk-rb/models/new_composition.rb +1 -1
  209. data/lib/api-sdk-rb/models/new_editor_session.rb +1 -1
  210. data/lib/api-sdk-rb/models/offer_workflow_preset_request.rb +322 -0
  211. data/lib/api-sdk-rb/models/offered_workflow_preset.rb +423 -0
  212. data/lib/api-sdk-rb/models/offered_workflow_preset_list.rb +223 -0
  213. data/lib/api-sdk-rb/models/offered_workflow_preset_widget.rb +251 -0
  214. data/lib/api-sdk-rb/models/partner_notification.rb +1 -1
  215. data/lib/api-sdk-rb/models/partner_notification_event_type.rb +5 -1
  216. data/lib/api-sdk-rb/models/patch_brand_kit_asset_request.rb +289 -0
  217. data/lib/api-sdk-rb/models/patch_brand_kit_request.rb +363 -0
  218. data/lib/api-sdk-rb/models/patch_brand_kit_request_fonts.rb +242 -0
  219. data/lib/api-sdk-rb/models/patch_brand_kit_request_spacing.rb +502 -0
  220. data/lib/api-sdk-rb/models/post_brand_kit_icon_request.rb +237 -0
  221. data/lib/api-sdk-rb/models/public_workflow.rb +351 -0
  222. data/lib/api-sdk-rb/models/public_workflow_events_accepted.rb +242 -0
  223. data/lib/api-sdk-rb/models/public_workflow_events_request.rb +301 -0
  224. data/lib/api-sdk-rb/models/public_workflow_events_request_events_inner.rb +354 -0
  225. data/lib/api-sdk-rb/models/public_workflow_events_request_heights_inner.rb +267 -0
  226. data/lib/api-sdk-rb/models/public_workflow_response.rb +246 -0
  227. data/lib/api-sdk-rb/models/public_workflow_translation.rb +242 -0
  228. data/lib/api-sdk-rb/models/{set_user_adapter_connection200_response.rb → publish_workspace_workflow200_response.rb} +4 -4
  229. data/lib/api-sdk-rb/models/publish_workspace_workflow_request.rb +240 -0
  230. data/lib/api-sdk-rb/models/put_brand_kit_request.rb +239 -0
  231. data/lib/api-sdk-rb/models/{remove_user_adapter_connection200_response.rb → remove_partner_workflow_preset200_response.rb} +4 -4
  232. data/lib/api-sdk-rb/models/report_public_workflow_events200_response.rb +246 -0
  233. data/lib/api-sdk-rb/models/save_workspace_workflow_request.rb +296 -0
  234. data/lib/api-sdk-rb/models/set_adapter_connection_request.rb +1 -1
  235. data/lib/api-sdk-rb/models/{get_partner_design_defaults200_response.rb → set_partner_workflow_preset200_response.rb} +4 -4
  236. data/lib/api-sdk-rb/models/update_composition.rb +1 -1
  237. data/lib/api-sdk-rb/models/upload.rb +1 -1
  238. data/lib/api-sdk-rb/models/upload_limits.rb +3 -3
  239. data/lib/api-sdk-rb/models/widget.rb +9 -20
  240. data/lib/api-sdk-rb/models/widget_clarification.rb +279 -0
  241. data/lib/api-sdk-rb/models/widget_clarification_option.rb +256 -0
  242. data/lib/api-sdk-rb/models/widget_clarification_question.rb +329 -0
  243. data/lib/api-sdk-rb/models/widget_next_step.rb +307 -0
  244. data/lib/api-sdk-rb/models/widget_plan.rb +306 -0
  245. data/lib/api-sdk-rb/models/widget_plan_decisions.rb +346 -0
  246. data/lib/api-sdk-rb/models/widget_plan_decisions_adapters_inner.rb +237 -0
  247. data/lib/api-sdk-rb/models/widget_plan_decisions_libraries_inner.rb +255 -0
  248. data/lib/api-sdk-rb/models/widget_plan_decisions_responsive.rb +311 -0
  249. data/lib/api-sdk-rb/models/widget_plan_task.rb +320 -0
  250. data/lib/api-sdk-rb/models/workflow.rb +509 -0
  251. data/lib/api-sdk-rb/models/workflow_composition_action.rb +266 -0
  252. data/lib/api-sdk-rb/models/workflow_composition_field.rb +303 -0
  253. data/lib/api-sdk-rb/models/workflow_composition_option.rb +316 -0
  254. data/lib/api-sdk-rb/models/workflow_composition_option_actions.rb +284 -0
  255. data/lib/api-sdk-rb/models/workflow_composition_option_inputs.rb +304 -0
  256. data/lib/api-sdk-rb/models/workflow_composition_options.rb +271 -0
  257. data/lib/api-sdk-rb/models/workflow_condition_case.rb +322 -0
  258. data/lib/api-sdk-rb/models/workflow_condition_test.rb +284 -0
  259. data/lib/api-sdk-rb/models/workflow_counter.rb +238 -0
  260. data/lib/api-sdk-rb/models/workflow_detail.rb +580 -0
  261. data/lib/api-sdk-rb/models/workflow_detail_all_of_last_edited_by.rb +242 -0
  262. data/lib/api-sdk-rb/models/workflow_detail_response.rb +246 -0
  263. data/lib/api-sdk-rb/models/workflow_edge.rb +292 -0
  264. data/lib/api-sdk-rb/models/workflow_failure_reason.rb +42 -0
  265. data/lib/api-sdk-rb/models/workflow_failure_reason_counter.rb +277 -0
  266. data/lib/api-sdk-rb/models/workflow_field_reference.rb +300 -0
  267. data/lib/api-sdk-rb/models/workflow_graph.rb +330 -0
  268. data/lib/api-sdk-rb/models/workflow_issue.rb +309 -0
  269. data/lib/api-sdk-rb/models/workflow_list.rb +271 -0
  270. data/lib/api-sdk-rb/models/workflow_node.rb +343 -0
  271. data/lib/api-sdk-rb/models/workflow_node_position.rb +238 -0
  272. data/lib/api-sdk-rb/models/workflow_preset_choice.rb +288 -0
  273. data/lib/api-sdk-rb/models/workflow_preset_choices.rb +224 -0
  274. data/lib/api-sdk-rb/models/workflow_preset_removal.rb +222 -0
  275. data/lib/api-sdk-rb/models/workflow_preset_widget.rb +234 -0
  276. data/lib/api-sdk-rb/models/workflow_publish_result.rb +256 -0
  277. data/lib/api-sdk-rb/models/workflow_removed.rb +221 -0
  278. data/lib/api-sdk-rb/models/workflow_response.rb +246 -0
  279. data/lib/api-sdk-rb/models/workflow_schedule.rb +298 -0
  280. data/lib/api-sdk-rb/models/workflow_stats.rb +347 -0
  281. data/lib/api-sdk-rb/models/workflow_status.rb +42 -0
  282. data/lib/api-sdk-rb/models/workflow_trigger.rb +303 -0
  283. data/lib/api-sdk-rb/models/workflow_trigger_values_inner.rb +271 -0
  284. data/lib/api-sdk-rb/models/workflow_version.rb +316 -0
  285. data/lib/api-sdk-rb/models/workflow_version_detail.rb +354 -0
  286. data/lib/api-sdk-rb/models/workflow_version_list.rb +224 -0
  287. data/lib/api-sdk-rb/models/workflow_version_published_by.rb +225 -0
  288. data/lib/api-sdk-rb/version.rb +1 -1
  289. data/lib/api-sdk-rb.rb +116 -17
  290. data/spec/api/brand_kit_api_spec.rb +136 -0
  291. data/spec/api/canvases_api_spec.rb +10 -10
  292. data/spec/api/compositions_api_spec.rb +227 -149
  293. data/spec/api/credits_api_spec.rb +5 -5
  294. data/spec/api/entitlements_api_spec.rb +4 -4
  295. data/spec/api/invoices_api_spec.rb +2 -2
  296. data/spec/api/managed_users_api_spec.rb +63 -42
  297. data/spec/api/operations_api_spec.rb +3 -3
  298. data/spec/api/partners_api_spec.rb +138 -84
  299. data/spec/api/public_embed_api_spec.rb +66 -15
  300. data/spec/api/tokens_api_spec.rb +3 -2
  301. data/spec/api/uploads_api_spec.rb +24 -24
  302. data/spec/api/users_api_spec.rb +43 -28
  303. data/spec/api/widgets_api_spec.rb +9 -9
  304. data/spec/api/workflows_api_spec.rb +339 -0
  305. data/spec/models/account_credit_transaction_list_response_spec.rb +48 -0
  306. data/spec/models/adapter_connection_list_response_spec.rb +48 -0
  307. data/spec/models/{get_managed_user_limits200_response_spec.rb → adapter_connection_removal_response_spec.rb} +6 -6
  308. data/spec/models/{delete_managed_user200_response_spec.rb → adapter_connection_response_spec.rb} +6 -6
  309. data/spec/models/adapter_connection_spec.rb +18 -0
  310. data/spec/models/ai_answers_knowledge_document_response_spec.rb +48 -0
  311. data/spec/models/brand_color_spec.rb +52 -0
  312. data/spec/models/brand_font_spec.rb +62 -0
  313. data/spec/models/brand_kit_asset_view_spec.rb +120 -0
  314. data/spec/models/brand_kit_figma_source_spec.rb +60 -0
  315. data/spec/models/brand_kit_tokens_fonts_spec.rb +54 -0
  316. data/spec/models/brand_kit_tokens_spec.rb +60 -0
  317. data/spec/models/brand_kit_view_owner_spec.rb +46 -0
  318. data/spec/models/{uploads_get200_response_spec.rb → brand_kit_view_response_spec.rb} +6 -6
  319. data/spec/models/brand_kit_view_spec.rb +90 -0
  320. data/spec/models/brand_spacing_spec.rb +78 -0
  321. data/spec/models/brand_text_style_spec.rb +52 -0
  322. data/spec/models/composition_database_record_response_spec.rb +48 -0
  323. data/spec/models/composition_last_edited_by_spec.rb +42 -0
  324. data/spec/models/composition_spec.rb +12 -0
  325. data/spec/models/confirm_adapter_connection_request_spec.rb +36 -0
  326. data/spec/models/content_item_write_result_response_spec.rb +48 -0
  327. data/spec/models/create_widget201_response_data_spec.rb +1 -7
  328. data/spec/models/create_workspace_workflow_from_preset_request_spec.rb +42 -0
  329. data/spec/models/create_workspace_workflow_request_spec.rb +48 -0
  330. data/spec/models/{uploads_id_delete200_response_data_spec.rb → delete_upload200_response_data_spec.rb} +6 -6
  331. data/spec/models/{operations_id_get_response_spec.rb → delete_upload200_response_spec.rb} +6 -6
  332. data/spec/models/delete_workspace_workflow200_response_spec.rb +48 -0
  333. data/spec/models/design_defaults_response_spec.rb +48 -0
  334. data/spec/models/editor_session_spec.rb +1 -1
  335. data/spec/models/get_operation_response_data_metadata_spec.rb +58 -0
  336. data/spec/models/{operations_id_get_response_data_spec.rb → get_operation_response_data_spec.rb} +6 -6
  337. data/spec/models/get_operation_response_spec.rb +48 -0
  338. data/spec/models/get_public_composition_embed200_response_adapters_captcha_spec.rb +36 -0
  339. data/spec/models/get_public_composition_embed200_response_adapters_spec.rb +42 -0
  340. data/spec/models/get_public_composition_embed200_response_entries_spec.rb +42 -0
  341. data/spec/models/get_public_composition_embed200_response_media_spec.rb +36 -0
  342. data/spec/models/get_public_composition_embed200_response_spec.rb +18 -0
  343. data/spec/models/{get_user_adapter_connections200_response_spec.rb → get_workspace_workflow_stats200_response_spec.rb} +6 -6
  344. data/spec/models/{remove_user_adapter_connection200_response_spec.rb → get_workspace_workflow_version200_response_spec.rb} +6 -6
  345. data/spec/models/list_partner_workflow_presets200_response_spec.rb +48 -0
  346. data/spec/models/list_uploads200_response_spec.rb +48 -0
  347. data/spec/models/{create_composition_database_record201_response_spec.rb → list_workspace_workflow_composition_options200_response_spec.rb} +6 -6
  348. data/spec/models/{get_partner_credit_transactions200_response_spec.rb → list_workspace_workflow_presets200_response_spec.rb} +6 -6
  349. data/spec/models/{add_ai_answers_knowledge_document201_response_spec.rb → list_workspace_workflow_versions200_response_spec.rb} +6 -6
  350. data/spec/models/list_workspace_workflows200_response_spec.rb +48 -0
  351. data/spec/models/managed_user_limits_response_spec.rb +48 -0
  352. data/spec/models/{uploads_id_delete200_response_spec.rb → managed_user_removal_response_spec.rb} +6 -6
  353. data/spec/models/new_editor_session_spec.rb +1 -1
  354. data/spec/models/offer_workflow_preset_request_spec.rb +54 -0
  355. data/spec/models/offered_workflow_preset_list_spec.rb +36 -0
  356. data/spec/models/offered_workflow_preset_spec.rb +106 -0
  357. data/spec/models/offered_workflow_preset_widget_spec.rb +48 -0
  358. data/spec/models/patch_brand_kit_asset_request_spec.rb +62 -0
  359. data/spec/models/patch_brand_kit_request_fonts_spec.rb +54 -0
  360. data/spec/models/patch_brand_kit_request_spacing_spec.rb +78 -0
  361. data/spec/models/patch_brand_kit_request_spec.rb +72 -0
  362. data/spec/models/post_brand_kit_icon_request_spec.rb +42 -0
  363. data/spec/models/public_workflow_events_accepted_spec.rb +48 -0
  364. data/spec/models/public_workflow_events_request_events_inner_spec.rb +62 -0
  365. data/spec/models/public_workflow_events_request_heights_inner_spec.rb +42 -0
  366. data/spec/models/public_workflow_events_request_spec.rb +54 -0
  367. data/spec/models/public_workflow_response_spec.rb +48 -0
  368. data/spec/models/public_workflow_spec.rb +94 -0
  369. data/spec/models/public_workflow_translation_spec.rb +42 -0
  370. data/spec/models/{get_partner_design_defaults200_response_spec.rb → publish_workspace_workflow200_response_spec.rb} +6 -6
  371. data/spec/models/publish_workspace_workflow_request_spec.rb +36 -0
  372. data/spec/models/put_brand_kit_request_spec.rb +48 -0
  373. data/spec/models/{create_composition_from_widget201_response_spec.rb → remove_partner_workflow_preset200_response_spec.rb} +6 -6
  374. data/spec/models/report_public_workflow_events200_response_spec.rb +48 -0
  375. data/spec/models/save_workspace_workflow_request_spec.rb +54 -0
  376. data/spec/models/{set_user_adapter_connection200_response_spec.rb → set_partner_workflow_preset200_response_spec.rb} +6 -6
  377. data/spec/models/widget_clarification_option_spec.rb +48 -0
  378. data/spec/models/widget_clarification_question_spec.rb +60 -0
  379. data/spec/models/widget_clarification_spec.rb +48 -0
  380. data/spec/models/widget_next_step_spec.rb +58 -0
  381. data/spec/models/widget_plan_decisions_adapters_inner_spec.rb +42 -0
  382. data/spec/models/widget_plan_decisions_libraries_inner_spec.rb +48 -0
  383. data/spec/models/widget_plan_decisions_responsive_spec.rb +48 -0
  384. data/spec/models/widget_plan_decisions_spec.rb +78 -0
  385. data/spec/models/widget_plan_spec.rb +60 -0
  386. data/spec/models/widget_plan_task_spec.rb +62 -0
  387. data/spec/models/widget_spec.rb +1 -7
  388. data/spec/models/workflow_composition_action_spec.rb +54 -0
  389. data/spec/models/workflow_composition_field_spec.rb +58 -0
  390. data/spec/models/workflow_composition_option_actions_spec.rb +52 -0
  391. data/spec/models/workflow_composition_option_inputs_spec.rb +58 -0
  392. data/spec/models/workflow_composition_option_spec.rb +72 -0
  393. data/spec/models/workflow_composition_options_spec.rb +54 -0
  394. data/spec/models/workflow_condition_case_spec.rb +58 -0
  395. data/spec/models/workflow_condition_test_spec.rb +52 -0
  396. data/spec/models/workflow_counter_spec.rb +42 -0
  397. data/spec/models/workflow_detail_all_of_last_edited_by_spec.rb +42 -0
  398. data/spec/models/workflow_detail_response_spec.rb +48 -0
  399. data/spec/models/workflow_detail_spec.rb +162 -0
  400. data/spec/models/workflow_edge_spec.rb +54 -0
  401. data/spec/models/workflow_failure_reason_counter_spec.rb +48 -0
  402. data/spec/models/workflow_failure_reason_spec.rb +30 -0
  403. data/spec/models/workflow_field_reference_spec.rb +56 -0
  404. data/spec/models/workflow_graph_spec.rb +52 -0
  405. data/spec/models/workflow_issue_spec.rb +70 -0
  406. data/spec/models/{create_composition_content_item201_response_spec.rb → workflow_list_spec.rb} +15 -9
  407. data/spec/models/workflow_node_position_spec.rb +42 -0
  408. data/spec/models/workflow_node_spec.rb +76 -0
  409. data/spec/models/workflow_preset_choice_spec.rb +60 -0
  410. data/spec/models/workflow_preset_choices_spec.rb +36 -0
  411. data/spec/models/workflow_preset_removal_spec.rb +36 -0
  412. data/spec/models/workflow_preset_widget_spec.rb +42 -0
  413. data/spec/models/workflow_publish_result_spec.rb +48 -0
  414. data/spec/models/workflow_removed_spec.rb +36 -0
  415. data/spec/models/workflow_response_spec.rb +48 -0
  416. data/spec/models/workflow_schedule_spec.rb +62 -0
  417. data/spec/models/workflow_spec.rb +132 -0
  418. data/spec/models/workflow_stats_spec.rb +84 -0
  419. data/spec/models/workflow_status_spec.rb +30 -0
  420. data/spec/models/workflow_trigger_spec.rb +70 -0
  421. data/spec/models/workflow_trigger_values_inner_spec.rb +46 -0
  422. data/spec/models/workflow_version_detail_spec.rb +78 -0
  423. data/spec/models/workflow_version_list_spec.rb +36 -0
  424. data/spec/models/workflow_version_published_by_spec.rb +42 -0
  425. data/spec/models/workflow_version_spec.rb +66 -0
  426. metadata +476 -80
  427. data/docs/PartnerApi.md +0 -9892
  428. data/docs/UploadsIdDelete200Response.md +0 -22
  429. data/lib/api-sdk-rb/api/partner_api.rb +0 -10693
  430. data/spec/api/partner_api_spec.rb +0 -1895
@@ -0,0 +1,1527 @@
1
+ # ApiSdkRb::WorkflowsApi
2
+
3
+ All URIs are relative to *https://api.widgetic.com/v1*
4
+
5
+ | Method | HTTP request | Description |
6
+ | ------ | ------------ | ----------- |
7
+ | [**archive_workspace_workflow**](WorkflowsApi.md#archive_workspace_workflow) | **POST** /workspaces/{workspaceId}/workflows/{workflowId}/archive | Archive a Workflow |
8
+ | [**create_workspace_workflow**](WorkflowsApi.md#create_workspace_workflow) | **POST** /workspaces/{workspaceId}/workflows | Create a Workflow |
9
+ | [**create_workspace_workflow_from_preset**](WorkflowsApi.md#create_workspace_workflow_from_preset) | **POST** /workspaces/{workspaceId}/workflows/from-preset | Start a Workflow from a starting point |
10
+ | [**delete_workspace_workflow**](WorkflowsApi.md#delete_workspace_workflow) | **DELETE** /workspaces/{workspaceId}/workflows/{workflowId} | Delete a Workflow |
11
+ | [**discard_workspace_workflow_changes**](WorkflowsApi.md#discard_workspace_workflow_changes) | **POST** /workspaces/{workspaceId}/workflows/{workflowId}/discard | Discard the Unpublished Changes of a Workflow |
12
+ | [**duplicate_workspace_workflow**](WorkflowsApi.md#duplicate_workspace_workflow) | **POST** /workspaces/{workspaceId}/workflows/{workflowId}/duplicate | Duplicate a Workflow |
13
+ | [**get_workspace_workflow**](WorkflowsApi.md#get_workspace_workflow) | **GET** /workspaces/{workspaceId}/workflows/{workflowId} | Get a Workflow |
14
+ | [**get_workspace_workflow_stats**](WorkflowsApi.md#get_workspace_workflow_stats) | **GET** /workspaces/{workspaceId}/workflows/{workflowId}/stats | Get what Visitors Did in a Workflow |
15
+ | [**get_workspace_workflow_version**](WorkflowsApi.md#get_workspace_workflow_version) | **GET** /workspaces/{workspaceId}/workflows/{workflowId}/versions/{versionId} | Get a Published Version of a Workflow |
16
+ | [**list_workspace_workflow_composition_options**](WorkflowsApi.md#list_workspace_workflow_composition_options) | **GET** /workspaces/{workspaceId}/workflows/composition-options | List the compositions a workflow can show, and what each can do |
17
+ | [**list_workspace_workflow_presets**](WorkflowsApi.md#list_workspace_workflow_presets) | **GET** /workspaces/{workspaceId}/workflows/presets | List the starting points for a new Workflow |
18
+ | [**list_workspace_workflow_versions**](WorkflowsApi.md#list_workspace_workflow_versions) | **GET** /workspaces/{workspaceId}/workflows/{workflowId}/versions | List the Published Versions of a Workflow |
19
+ | [**list_workspace_workflows**](WorkflowsApi.md#list_workspace_workflows) | **GET** /workspaces/{workspaceId}/workflows | List the Workflows of a Workspace |
20
+ | [**pause_workspace_workflow**](WorkflowsApi.md#pause_workspace_workflow) | **POST** /workspaces/{workspaceId}/workflows/{workflowId}/pause | Pause a Workflow |
21
+ | [**publish_workspace_workflow**](WorkflowsApi.md#publish_workspace_workflow) | **POST** /workspaces/{workspaceId}/workflows/{workflowId}/publish | Publish the Draft of a Workflow |
22
+ | [**restore_workspace_workflow_version**](WorkflowsApi.md#restore_workspace_workflow_version) | **POST** /workspaces/{workspaceId}/workflows/{workflowId}/versions/{versionId}/restore | Restore a Version of a Workflow into the Draft |
23
+ | [**resume_workspace_workflow**](WorkflowsApi.md#resume_workspace_workflow) | **POST** /workspaces/{workspaceId}/workflows/{workflowId}/resume | Resume a Paused Workflow |
24
+ | [**save_workspace_workflow**](WorkflowsApi.md#save_workspace_workflow) | **PUT** /workspaces/{workspaceId}/workflows/{workflowId} | Save the Draft of a Workflow |
25
+ | [**unarchive_workspace_workflow**](WorkflowsApi.md#unarchive_workspace_workflow) | **POST** /workspaces/{workspaceId}/workflows/{workflowId}/unarchive | Unarchive a Workflow |
26
+
27
+
28
+ ## archive_workspace_workflow
29
+
30
+ > <WorkflowResponse> archive_workspace_workflow(workspace_id, workflow_id, opts)
31
+
32
+ Archive a Workflow
33
+
34
+ Takes a workflow out of the default list and stops it serving: its embeds show only their first composition, as when paused. It is kept, with its versions and counts, until it is deleted. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can archive.
35
+
36
+ ### Examples
37
+
38
+ ```ruby
39
+ require 'time'
40
+ require 'api-sdk-rb'
41
+ # setup authorization
42
+ ApiSdkRb.configure do |config|
43
+ # Configure Bearer authorization (JWT): apiKeyAuth
44
+ config.access_token = 'YOUR_BEARER_TOKEN'
45
+ end
46
+
47
+ api_instance = ApiSdkRb::WorkflowsApi.new
48
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
49
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
50
+ opts = {
51
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
52
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
53
+ }
54
+
55
+ begin
56
+ # Archive a Workflow
57
+ result = api_instance.archive_workspace_workflow(workspace_id, workflow_id, opts)
58
+ p result
59
+ rescue ApiSdkRb::ApiError => e
60
+ puts "Error when calling WorkflowsApi->archive_workspace_workflow: #{e}"
61
+ end
62
+ ```
63
+
64
+ #### Using the archive_workspace_workflow_with_http_info variant
65
+
66
+ This returns an Array which contains the response data, status code and headers.
67
+
68
+ > <Array(<WorkflowResponse>, Integer, Hash)> archive_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
69
+
70
+ ```ruby
71
+ begin
72
+ # Archive a Workflow
73
+ data, status_code, headers = api_instance.archive_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
74
+ p status_code # => 2xx
75
+ p headers # => { ... }
76
+ p data # => <WorkflowResponse>
77
+ rescue ApiSdkRb::ApiError => e
78
+ puts "Error when calling WorkflowsApi->archive_workspace_workflow_with_http_info: #{e}"
79
+ end
80
+ ```
81
+
82
+ ### Parameters
83
+
84
+ | Name | Type | Description | Notes |
85
+ | ---- | ---- | ----------- | ----- |
86
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
87
+ | **workflow_id** | **String** | The workflow&#39;s id | |
88
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
89
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
90
+
91
+ ### Return type
92
+
93
+ [**WorkflowResponse**](WorkflowResponse.md)
94
+
95
+ ### Authorization
96
+
97
+ [apiKeyAuth](../README.md#apiKeyAuth)
98
+
99
+ ### HTTP request headers
100
+
101
+ - **Content-Type**: Not defined
102
+ - **Accept**: application/json
103
+
104
+
105
+ ## create_workspace_workflow
106
+
107
+ > <WorkflowDetailResponse> create_workspace_workflow(workspace_id, idempotency_key, create_workspace_workflow_request, opts)
108
+
109
+ Create a Workflow
110
+
111
+ Makes a draft workflow. Give it a composition and the workflow is born with one block, which starts it; without one it starts empty. A workspace holds up to 500 workflows. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can create one.
112
+
113
+ ### Examples
114
+
115
+ ```ruby
116
+ require 'time'
117
+ require 'api-sdk-rb'
118
+ # setup authorization
119
+ ApiSdkRb.configure do |config|
120
+ # Configure Bearer authorization (JWT): apiKeyAuth
121
+ config.access_token = 'YOUR_BEARER_TOKEN'
122
+ end
123
+
124
+ api_instance = ApiSdkRb::WorkflowsApi.new
125
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
126
+ idempotency_key = '9b2d6f0a-3c41-4e5a-8d77-1f2e3a4b5c6d' # String | Required: a call without it is refused with `400`. A key of your own that names this one request; a UUID is ideal. It is 8 to 50 characters of letters, digits, `-` and `_`. Send the same key again when you retry (after a timeout, a dropped connection or a `5xx`) and the call is carried out once: the retry gets the first answer back, marked `X-Idempotency-Cached: true`. The same key with a different body is refused with `422`, and a retry that arrives while the first call is still running with `409` (see `Retry-After`).
127
+ create_workspace_workflow_request = ApiSdkRb::CreateWorkspaceWorkflowRequest.new({name: 'Welcome journey'}) # CreateWorkspaceWorkflowRequest |
128
+ opts = {
129
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
130
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
131
+ }
132
+
133
+ begin
134
+ # Create a Workflow
135
+ result = api_instance.create_workspace_workflow(workspace_id, idempotency_key, create_workspace_workflow_request, opts)
136
+ p result
137
+ rescue ApiSdkRb::ApiError => e
138
+ puts "Error when calling WorkflowsApi->create_workspace_workflow: #{e}"
139
+ end
140
+ ```
141
+
142
+ #### Using the create_workspace_workflow_with_http_info variant
143
+
144
+ This returns an Array which contains the response data, status code and headers.
145
+
146
+ > <Array(<WorkflowDetailResponse>, Integer, Hash)> create_workspace_workflow_with_http_info(workspace_id, idempotency_key, create_workspace_workflow_request, opts)
147
+
148
+ ```ruby
149
+ begin
150
+ # Create a Workflow
151
+ data, status_code, headers = api_instance.create_workspace_workflow_with_http_info(workspace_id, idempotency_key, create_workspace_workflow_request, opts)
152
+ p status_code # => 2xx
153
+ p headers # => { ... }
154
+ p data # => <WorkflowDetailResponse>
155
+ rescue ApiSdkRb::ApiError => e
156
+ puts "Error when calling WorkflowsApi->create_workspace_workflow_with_http_info: #{e}"
157
+ end
158
+ ```
159
+
160
+ ### Parameters
161
+
162
+ | Name | Type | Description | Notes |
163
+ | ---- | ---- | ----------- | ----- |
164
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
165
+ | **idempotency_key** | **String** | Required: a call without it is refused with &#x60;400&#x60;. A key of your own that names this one request; a UUID is ideal. It is 8 to 50 characters of letters, digits, &#x60;-&#x60; and &#x60;_&#x60;. Send the same key again when you retry (after a timeout, a dropped connection or a &#x60;5xx&#x60;) and the call is carried out once: the retry gets the first answer back, marked &#x60;X-Idempotency-Cached: true&#x60;. The same key with a different body is refused with &#x60;422&#x60;, and a retry that arrives while the first call is still running with &#x60;409&#x60; (see &#x60;Retry-After&#x60;). | |
166
+ | **create_workspace_workflow_request** | [**CreateWorkspaceWorkflowRequest**](CreateWorkspaceWorkflowRequest.md) | | |
167
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
168
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
169
+
170
+ ### Return type
171
+
172
+ [**WorkflowDetailResponse**](WorkflowDetailResponse.md)
173
+
174
+ ### Authorization
175
+
176
+ [apiKeyAuth](../README.md#apiKeyAuth)
177
+
178
+ ### HTTP request headers
179
+
180
+ - **Content-Type**: application/json
181
+ - **Accept**: application/json
182
+
183
+
184
+ ## create_workspace_workflow_from_preset
185
+
186
+ > <WorkflowDetailResponse> create_workspace_workflow_from_preset(workspace_id, idempotency_key, create_workspace_workflow_from_preset_request, opts)
187
+
188
+ Start a Workflow from a starting point
189
+
190
+ Makes your own copy of a starting point (`listWorkspaceWorkflowPresets`): a copy of every widget it chains (an ordinary private widget that serves the starting point's published code), a composition of your own on each copy (a draft, with the content, design, embed settings and tables of the original), and a draft workflow wired like the starting point's live version. The workflow is named as you ask, or after the starting point. Nothing you do to the copy reaches the starting point, and nothing its offerer changes afterwards reaches your copy. The workflow stays a draft: publish it when it is ready. A start takes a few seconds, because each widget is copied. Send an `Idempotency-Key` so that asking again after a timeout makes one copy. When a start fails (503 with `details.reason` `preset_copy_failed`) the compositions it made are removed again, so asking again is safe; the widget copies it made stay in the workspace as ordinary widgets. The workspace's limit of workflows is checked before anything is copied. A starting point that is not offered to you, or that can no longer be started, is 404. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can start one.
191
+
192
+ ### Examples
193
+
194
+ ```ruby
195
+ require 'time'
196
+ require 'api-sdk-rb'
197
+ # setup authorization
198
+ ApiSdkRb.configure do |config|
199
+ # Configure Bearer authorization (JWT): apiKeyAuth
200
+ config.access_token = 'YOUR_BEARER_TOKEN'
201
+ end
202
+
203
+ api_instance = ApiSdkRb::WorkflowsApi.new
204
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
205
+ idempotency_key = '9b2d6f0a-3c41-4e5a-8d77-1f2e3a4b5c6d' # String | Required: a call without it is refused with `400`. A key of your own that names this one request; a UUID is ideal. It is 8 to 50 characters of letters, digits, `-` and `_`. Send the same key again when you retry (after a timeout, a dropped connection or a `5xx`) and the call is carried out once: the retry gets the first answer back, marked `X-Idempotency-Cached: true`. The same key with a different body is refused with `422`, and a retry that arrives while the first call is still running with `409` (see `Retry-After`).
206
+ create_workspace_workflow_from_preset_request = ApiSdkRb::CreateWorkspaceWorkflowFromPresetRequest.new({key: 'welcome-then-offer'}) # CreateWorkspaceWorkflowFromPresetRequest |
207
+ opts = {
208
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
209
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
210
+ }
211
+
212
+ begin
213
+ # Start a Workflow from a starting point
214
+ result = api_instance.create_workspace_workflow_from_preset(workspace_id, idempotency_key, create_workspace_workflow_from_preset_request, opts)
215
+ p result
216
+ rescue ApiSdkRb::ApiError => e
217
+ puts "Error when calling WorkflowsApi->create_workspace_workflow_from_preset: #{e}"
218
+ end
219
+ ```
220
+
221
+ #### Using the create_workspace_workflow_from_preset_with_http_info variant
222
+
223
+ This returns an Array which contains the response data, status code and headers.
224
+
225
+ > <Array(<WorkflowDetailResponse>, Integer, Hash)> create_workspace_workflow_from_preset_with_http_info(workspace_id, idempotency_key, create_workspace_workflow_from_preset_request, opts)
226
+
227
+ ```ruby
228
+ begin
229
+ # Start a Workflow from a starting point
230
+ data, status_code, headers = api_instance.create_workspace_workflow_from_preset_with_http_info(workspace_id, idempotency_key, create_workspace_workflow_from_preset_request, opts)
231
+ p status_code # => 2xx
232
+ p headers # => { ... }
233
+ p data # => <WorkflowDetailResponse>
234
+ rescue ApiSdkRb::ApiError => e
235
+ puts "Error when calling WorkflowsApi->create_workspace_workflow_from_preset_with_http_info: #{e}"
236
+ end
237
+ ```
238
+
239
+ ### Parameters
240
+
241
+ | Name | Type | Description | Notes |
242
+ | ---- | ---- | ----------- | ----- |
243
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
244
+ | **idempotency_key** | **String** | Required: a call without it is refused with &#x60;400&#x60;. A key of your own that names this one request; a UUID is ideal. It is 8 to 50 characters of letters, digits, &#x60;-&#x60; and &#x60;_&#x60;. Send the same key again when you retry (after a timeout, a dropped connection or a &#x60;5xx&#x60;) and the call is carried out once: the retry gets the first answer back, marked &#x60;X-Idempotency-Cached: true&#x60;. The same key with a different body is refused with &#x60;422&#x60;, and a retry that arrives while the first call is still running with &#x60;409&#x60; (see &#x60;Retry-After&#x60;). | |
245
+ | **create_workspace_workflow_from_preset_request** | [**CreateWorkspaceWorkflowFromPresetRequest**](CreateWorkspaceWorkflowFromPresetRequest.md) | | |
246
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
247
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
248
+
249
+ ### Return type
250
+
251
+ [**WorkflowDetailResponse**](WorkflowDetailResponse.md)
252
+
253
+ ### Authorization
254
+
255
+ [apiKeyAuth](../README.md#apiKeyAuth)
256
+
257
+ ### HTTP request headers
258
+
259
+ - **Content-Type**: application/json
260
+ - **Accept**: application/json
261
+
262
+
263
+ ## delete_workspace_workflow
264
+
265
+ > <DeleteWorkspaceWorkflow200Response> delete_workspace_workflow(workspace_id, workflow_id, opts)
266
+
267
+ Delete a Workflow
268
+
269
+ Deletes a workflow, in whatever state it is in (draft, live, paused or archived), with all its versions and counts. It cannot be undone: archive the workflow instead to keep it. The compositions it chained are not touched, and a page whose embed still names the workflow shows the embed's first composition, as for a paused one. Asking for a workflow that is already gone is \"not found\". For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can delete.
270
+
271
+ ### Examples
272
+
273
+ ```ruby
274
+ require 'time'
275
+ require 'api-sdk-rb'
276
+ # setup authorization
277
+ ApiSdkRb.configure do |config|
278
+ # Configure Bearer authorization (JWT): apiKeyAuth
279
+ config.access_token = 'YOUR_BEARER_TOKEN'
280
+ end
281
+
282
+ api_instance = ApiSdkRb::WorkflowsApi.new
283
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
284
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
285
+ opts = {
286
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
287
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
288
+ }
289
+
290
+ begin
291
+ # Delete a Workflow
292
+ result = api_instance.delete_workspace_workflow(workspace_id, workflow_id, opts)
293
+ p result
294
+ rescue ApiSdkRb::ApiError => e
295
+ puts "Error when calling WorkflowsApi->delete_workspace_workflow: #{e}"
296
+ end
297
+ ```
298
+
299
+ #### Using the delete_workspace_workflow_with_http_info variant
300
+
301
+ This returns an Array which contains the response data, status code and headers.
302
+
303
+ > <Array(<DeleteWorkspaceWorkflow200Response>, Integer, Hash)> delete_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
304
+
305
+ ```ruby
306
+ begin
307
+ # Delete a Workflow
308
+ data, status_code, headers = api_instance.delete_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
309
+ p status_code # => 2xx
310
+ p headers # => { ... }
311
+ p data # => <DeleteWorkspaceWorkflow200Response>
312
+ rescue ApiSdkRb::ApiError => e
313
+ puts "Error when calling WorkflowsApi->delete_workspace_workflow_with_http_info: #{e}"
314
+ end
315
+ ```
316
+
317
+ ### Parameters
318
+
319
+ | Name | Type | Description | Notes |
320
+ | ---- | ---- | ----------- | ----- |
321
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
322
+ | **workflow_id** | **String** | The workflow&#39;s id | |
323
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
324
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
325
+
326
+ ### Return type
327
+
328
+ [**DeleteWorkspaceWorkflow200Response**](DeleteWorkspaceWorkflow200Response.md)
329
+
330
+ ### Authorization
331
+
332
+ [apiKeyAuth](../README.md#apiKeyAuth)
333
+
334
+ ### HTTP request headers
335
+
336
+ - **Content-Type**: Not defined
337
+ - **Accept**: application/json
338
+
339
+
340
+ ## discard_workspace_workflow_changes
341
+
342
+ > <WorkflowDetailResponse> discard_workspace_workflow_changes(workspace_id, workflow_id, publish_workspace_workflow_request, opts)
343
+
344
+ Discard the Unpublished Changes of a Workflow
345
+
346
+ Puts the draft back to the live version (its graph and its time zone). Only for a workflow that has been published; one that never was has no live version to go back to. Names the `revision` the editor read. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can discard.
347
+
348
+ ### Examples
349
+
350
+ ```ruby
351
+ require 'time'
352
+ require 'api-sdk-rb'
353
+ # setup authorization
354
+ ApiSdkRb.configure do |config|
355
+ # Configure Bearer authorization (JWT): apiKeyAuth
356
+ config.access_token = 'YOUR_BEARER_TOKEN'
357
+ end
358
+
359
+ api_instance = ApiSdkRb::WorkflowsApi.new
360
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
361
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
362
+ publish_workspace_workflow_request = ApiSdkRb::PublishWorkspaceWorkflowRequest.new({revision: 37}) # PublishWorkspaceWorkflowRequest |
363
+ opts = {
364
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
365
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
366
+ }
367
+
368
+ begin
369
+ # Discard the Unpublished Changes of a Workflow
370
+ result = api_instance.discard_workspace_workflow_changes(workspace_id, workflow_id, publish_workspace_workflow_request, opts)
371
+ p result
372
+ rescue ApiSdkRb::ApiError => e
373
+ puts "Error when calling WorkflowsApi->discard_workspace_workflow_changes: #{e}"
374
+ end
375
+ ```
376
+
377
+ #### Using the discard_workspace_workflow_changes_with_http_info variant
378
+
379
+ This returns an Array which contains the response data, status code and headers.
380
+
381
+ > <Array(<WorkflowDetailResponse>, Integer, Hash)> discard_workspace_workflow_changes_with_http_info(workspace_id, workflow_id, publish_workspace_workflow_request, opts)
382
+
383
+ ```ruby
384
+ begin
385
+ # Discard the Unpublished Changes of a Workflow
386
+ data, status_code, headers = api_instance.discard_workspace_workflow_changes_with_http_info(workspace_id, workflow_id, publish_workspace_workflow_request, opts)
387
+ p status_code # => 2xx
388
+ p headers # => { ... }
389
+ p data # => <WorkflowDetailResponse>
390
+ rescue ApiSdkRb::ApiError => e
391
+ puts "Error when calling WorkflowsApi->discard_workspace_workflow_changes_with_http_info: #{e}"
392
+ end
393
+ ```
394
+
395
+ ### Parameters
396
+
397
+ | Name | Type | Description | Notes |
398
+ | ---- | ---- | ----------- | ----- |
399
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
400
+ | **workflow_id** | **String** | The workflow&#39;s id | |
401
+ | **publish_workspace_workflow_request** | [**PublishWorkspaceWorkflowRequest**](PublishWorkspaceWorkflowRequest.md) | | |
402
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
403
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
404
+
405
+ ### Return type
406
+
407
+ [**WorkflowDetailResponse**](WorkflowDetailResponse.md)
408
+
409
+ ### Authorization
410
+
411
+ [apiKeyAuth](../README.md#apiKeyAuth)
412
+
413
+ ### HTTP request headers
414
+
415
+ - **Content-Type**: application/json
416
+ - **Accept**: application/json
417
+
418
+
419
+ ## duplicate_workspace_workflow
420
+
421
+ > <WorkflowDetailResponse> duplicate_workspace_workflow(workspace_id, workflow_id, idempotency_key, opts)
422
+
423
+ Duplicate a Workflow
424
+
425
+ Makes a draft copy of a workflow (its draft graph, not its versions or counts), named \"<name> (copy)\". For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can duplicate.
426
+
427
+ ### Examples
428
+
429
+ ```ruby
430
+ require 'time'
431
+ require 'api-sdk-rb'
432
+ # setup authorization
433
+ ApiSdkRb.configure do |config|
434
+ # Configure Bearer authorization (JWT): apiKeyAuth
435
+ config.access_token = 'YOUR_BEARER_TOKEN'
436
+ end
437
+
438
+ api_instance = ApiSdkRb::WorkflowsApi.new
439
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
440
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
441
+ idempotency_key = '9b2d6f0a-3c41-4e5a-8d77-1f2e3a4b5c6d' # String | Required: a call without it is refused with `400`. A key of your own that names this one request; a UUID is ideal. It is 8 to 50 characters of letters, digits, `-` and `_`. Send the same key again when you retry (after a timeout, a dropped connection or a `5xx`) and the call is carried out once: the retry gets the first answer back, marked `X-Idempotency-Cached: true`. The same key with a different body is refused with `422`, and a retry that arrives while the first call is still running with `409` (see `Retry-After`).
442
+ opts = {
443
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
444
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
445
+ }
446
+
447
+ begin
448
+ # Duplicate a Workflow
449
+ result = api_instance.duplicate_workspace_workflow(workspace_id, workflow_id, idempotency_key, opts)
450
+ p result
451
+ rescue ApiSdkRb::ApiError => e
452
+ puts "Error when calling WorkflowsApi->duplicate_workspace_workflow: #{e}"
453
+ end
454
+ ```
455
+
456
+ #### Using the duplicate_workspace_workflow_with_http_info variant
457
+
458
+ This returns an Array which contains the response data, status code and headers.
459
+
460
+ > <Array(<WorkflowDetailResponse>, Integer, Hash)> duplicate_workspace_workflow_with_http_info(workspace_id, workflow_id, idempotency_key, opts)
461
+
462
+ ```ruby
463
+ begin
464
+ # Duplicate a Workflow
465
+ data, status_code, headers = api_instance.duplicate_workspace_workflow_with_http_info(workspace_id, workflow_id, idempotency_key, opts)
466
+ p status_code # => 2xx
467
+ p headers # => { ... }
468
+ p data # => <WorkflowDetailResponse>
469
+ rescue ApiSdkRb::ApiError => e
470
+ puts "Error when calling WorkflowsApi->duplicate_workspace_workflow_with_http_info: #{e}"
471
+ end
472
+ ```
473
+
474
+ ### Parameters
475
+
476
+ | Name | Type | Description | Notes |
477
+ | ---- | ---- | ----------- | ----- |
478
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
479
+ | **workflow_id** | **String** | The workflow&#39;s id | |
480
+ | **idempotency_key** | **String** | Required: a call without it is refused with &#x60;400&#x60;. A key of your own that names this one request; a UUID is ideal. It is 8 to 50 characters of letters, digits, &#x60;-&#x60; and &#x60;_&#x60;. Send the same key again when you retry (after a timeout, a dropped connection or a &#x60;5xx&#x60;) and the call is carried out once: the retry gets the first answer back, marked &#x60;X-Idempotency-Cached: true&#x60;. The same key with a different body is refused with &#x60;422&#x60;, and a retry that arrives while the first call is still running with &#x60;409&#x60; (see &#x60;Retry-After&#x60;). | |
481
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
482
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
483
+
484
+ ### Return type
485
+
486
+ [**WorkflowDetailResponse**](WorkflowDetailResponse.md)
487
+
488
+ ### Authorization
489
+
490
+ [apiKeyAuth](../README.md#apiKeyAuth)
491
+
492
+ ### HTTP request headers
493
+
494
+ - **Content-Type**: Not defined
495
+ - **Accept**: application/json
496
+
497
+
498
+ ## get_workspace_workflow
499
+
500
+ > <WorkflowDetailResponse> get_workspace_workflow(workspace_id, workflow_id, opts)
501
+
502
+ Get a Workflow
503
+
504
+ Reads a workflow with its draft graph and the version that is live. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can read it.
505
+
506
+ ### Examples
507
+
508
+ ```ruby
509
+ require 'time'
510
+ require 'api-sdk-rb'
511
+ # setup authorization
512
+ ApiSdkRb.configure do |config|
513
+ # Configure Bearer authorization (JWT): apiKeyAuth
514
+ config.access_token = 'YOUR_BEARER_TOKEN'
515
+ end
516
+
517
+ api_instance = ApiSdkRb::WorkflowsApi.new
518
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
519
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
520
+ opts = {
521
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
522
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
523
+ }
524
+
525
+ begin
526
+ # Get a Workflow
527
+ result = api_instance.get_workspace_workflow(workspace_id, workflow_id, opts)
528
+ p result
529
+ rescue ApiSdkRb::ApiError => e
530
+ puts "Error when calling WorkflowsApi->get_workspace_workflow: #{e}"
531
+ end
532
+ ```
533
+
534
+ #### Using the get_workspace_workflow_with_http_info variant
535
+
536
+ This returns an Array which contains the response data, status code and headers.
537
+
538
+ > <Array(<WorkflowDetailResponse>, Integer, Hash)> get_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
539
+
540
+ ```ruby
541
+ begin
542
+ # Get a Workflow
543
+ data, status_code, headers = api_instance.get_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
544
+ p status_code # => 2xx
545
+ p headers # => { ... }
546
+ p data # => <WorkflowDetailResponse>
547
+ rescue ApiSdkRb::ApiError => e
548
+ puts "Error when calling WorkflowsApi->get_workspace_workflow_with_http_info: #{e}"
549
+ end
550
+ ```
551
+
552
+ ### Parameters
553
+
554
+ | Name | Type | Description | Notes |
555
+ | ---- | ---- | ----------- | ----- |
556
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
557
+ | **workflow_id** | **String** | The workflow&#39;s id | |
558
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
559
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
560
+
561
+ ### Return type
562
+
563
+ [**WorkflowDetailResponse**](WorkflowDetailResponse.md)
564
+
565
+ ### Authorization
566
+
567
+ [apiKeyAuth](../README.md#apiKeyAuth)
568
+
569
+ ### HTTP request headers
570
+
571
+ - **Content-Type**: Not defined
572
+ - **Accept**: application/json
573
+
574
+
575
+ ## get_workspace_workflow_stats
576
+
577
+ > <GetWorkspaceWorkflowStats200Response> get_workspace_workflow_stats(workspace_id, workflow_id, opts)
578
+
579
+ Get what Visitors Did in a Workflow
580
+
581
+ Counts per block and per connection over a range of UTC days (the last 30 days when not given, up to 366), for one version or for all of them. Only counts: how many visitors reached a block, took a connection, or could not be moved on, and, where the visitor's browser said why a block could not be shown, how many of those failures had each reason (`failedReasons`: a timeout, an error of the widget, a build that failed, or another reason). No visitor and no value a visitor typed is ever stored. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can read.
582
+
583
+ ### Examples
584
+
585
+ ```ruby
586
+ require 'time'
587
+ require 'api-sdk-rb'
588
+ # setup authorization
589
+ ApiSdkRb.configure do |config|
590
+ # Configure Bearer authorization (JWT): apiKeyAuth
591
+ config.access_token = 'YOUR_BEARER_TOKEN'
592
+ end
593
+
594
+ api_instance = ApiSdkRb::WorkflowsApi.new
595
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
596
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
597
+ opts = {
598
+ version_id: '38400000-8cf0-11bd-b23e-10b96e4ef00d', # String | Count one version only
599
+ from: '2026-10-01', # String | First UTC day (YYYY-MM-DD)
600
+ to: '2026-10-27', # String | Last UTC day (YYYY-MM-DD)
601
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
602
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
603
+ }
604
+
605
+ begin
606
+ # Get what Visitors Did in a Workflow
607
+ result = api_instance.get_workspace_workflow_stats(workspace_id, workflow_id, opts)
608
+ p result
609
+ rescue ApiSdkRb::ApiError => e
610
+ puts "Error when calling WorkflowsApi->get_workspace_workflow_stats: #{e}"
611
+ end
612
+ ```
613
+
614
+ #### Using the get_workspace_workflow_stats_with_http_info variant
615
+
616
+ This returns an Array which contains the response data, status code and headers.
617
+
618
+ > <Array(<GetWorkspaceWorkflowStats200Response>, Integer, Hash)> get_workspace_workflow_stats_with_http_info(workspace_id, workflow_id, opts)
619
+
620
+ ```ruby
621
+ begin
622
+ # Get what Visitors Did in a Workflow
623
+ data, status_code, headers = api_instance.get_workspace_workflow_stats_with_http_info(workspace_id, workflow_id, opts)
624
+ p status_code # => 2xx
625
+ p headers # => { ... }
626
+ p data # => <GetWorkspaceWorkflowStats200Response>
627
+ rescue ApiSdkRb::ApiError => e
628
+ puts "Error when calling WorkflowsApi->get_workspace_workflow_stats_with_http_info: #{e}"
629
+ end
630
+ ```
631
+
632
+ ### Parameters
633
+
634
+ | Name | Type | Description | Notes |
635
+ | ---- | ---- | ----------- | ----- |
636
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
637
+ | **workflow_id** | **String** | The workflow&#39;s id | |
638
+ | **version_id** | **String** | Count one version only | [optional] |
639
+ | **from** | **String** | First UTC day (YYYY-MM-DD) | [optional] |
640
+ | **to** | **String** | Last UTC day (YYYY-MM-DD) | [optional] |
641
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
642
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
643
+
644
+ ### Return type
645
+
646
+ [**GetWorkspaceWorkflowStats200Response**](GetWorkspaceWorkflowStats200Response.md)
647
+
648
+ ### Authorization
649
+
650
+ [apiKeyAuth](../README.md#apiKeyAuth)
651
+
652
+ ### HTTP request headers
653
+
654
+ - **Content-Type**: Not defined
655
+ - **Accept**: application/json
656
+
657
+
658
+ ## get_workspace_workflow_version
659
+
660
+ > <GetWorkspaceWorkflowVersion200Response> get_workspace_workflow_version(workspace_id, workflow_id, version_id, opts)
661
+
662
+ Get a Published Version of a Workflow
663
+
664
+ One published version with its graph, for the read-only preview and for the Runs view. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can read.
665
+
666
+ ### Examples
667
+
668
+ ```ruby
669
+ require 'time'
670
+ require 'api-sdk-rb'
671
+ # setup authorization
672
+ ApiSdkRb.configure do |config|
673
+ # Configure Bearer authorization (JWT): apiKeyAuth
674
+ config.access_token = 'YOUR_BEARER_TOKEN'
675
+ end
676
+
677
+ api_instance = ApiSdkRb::WorkflowsApi.new
678
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
679
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
680
+ version_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The id of a published version of the workflow
681
+ opts = {
682
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
683
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
684
+ }
685
+
686
+ begin
687
+ # Get a Published Version of a Workflow
688
+ result = api_instance.get_workspace_workflow_version(workspace_id, workflow_id, version_id, opts)
689
+ p result
690
+ rescue ApiSdkRb::ApiError => e
691
+ puts "Error when calling WorkflowsApi->get_workspace_workflow_version: #{e}"
692
+ end
693
+ ```
694
+
695
+ #### Using the get_workspace_workflow_version_with_http_info variant
696
+
697
+ This returns an Array which contains the response data, status code and headers.
698
+
699
+ > <Array(<GetWorkspaceWorkflowVersion200Response>, Integer, Hash)> get_workspace_workflow_version_with_http_info(workspace_id, workflow_id, version_id, opts)
700
+
701
+ ```ruby
702
+ begin
703
+ # Get a Published Version of a Workflow
704
+ data, status_code, headers = api_instance.get_workspace_workflow_version_with_http_info(workspace_id, workflow_id, version_id, opts)
705
+ p status_code # => 2xx
706
+ p headers # => { ... }
707
+ p data # => <GetWorkspaceWorkflowVersion200Response>
708
+ rescue ApiSdkRb::ApiError => e
709
+ puts "Error when calling WorkflowsApi->get_workspace_workflow_version_with_http_info: #{e}"
710
+ end
711
+ ```
712
+
713
+ ### Parameters
714
+
715
+ | Name | Type | Description | Notes |
716
+ | ---- | ---- | ----------- | ----- |
717
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
718
+ | **workflow_id** | **String** | The workflow&#39;s id | |
719
+ | **version_id** | **String** | The id of a published version of the workflow | |
720
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
721
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
722
+
723
+ ### Return type
724
+
725
+ [**GetWorkspaceWorkflowVersion200Response**](GetWorkspaceWorkflowVersion200Response.md)
726
+
727
+ ### Authorization
728
+
729
+ [apiKeyAuth](../README.md#apiKeyAuth)
730
+
731
+ ### HTTP request headers
732
+
733
+ - **Content-Type**: Not defined
734
+ - **Accept**: application/json
735
+
736
+
737
+ ## list_workspace_workflow_composition_options
738
+
739
+ > <ListWorkspaceWorkflowCompositionOptions200Response> list_workspace_workflow_composition_options(workspace_id, opts)
740
+
741
+ List the compositions a workflow can show, and what each can do
742
+
743
+ The workspace's compositions as the workflow editor offers them, newest first. For each one: whether it can be shown (its widget has a published version), the websites it may be embedded on, and which triggers it supports. - **Input added** (`inputs`) is enabled only for a composition that declares at least one table a visitor's entries can be written to. Its `tables` are all of them; its `fields` are the columns a rule may read (not `id` and `created_at`, not a column that is not text, a number or yes/no, and not one whose name says it holds a person's private details, such as an email or a phone number). - **Action in the widget** (`actions`) is enabled only when the published widget version declares at least one goal. Its `items` are the goals a trigger can wait for. When one of them is not enabled, `reason` says why (`widget_keeps_no_data`, `widget_reports_no_actions` or `widget_not_published`), so the editor can show the trigger disabled with an explanation. Publishing checks every reference again against what the composition can do at that moment. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can read it.
744
+
745
+ ### Examples
746
+
747
+ ```ruby
748
+ require 'time'
749
+ require 'api-sdk-rb'
750
+ # setup authorization
751
+ ApiSdkRb.configure do |config|
752
+ # Configure Bearer authorization (JWT): apiKeyAuth
753
+ config.access_token = 'YOUR_BEARER_TOKEN'
754
+ end
755
+
756
+ api_instance = ApiSdkRb::WorkflowsApi.new
757
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
758
+ opts = {
759
+ search: 'search_example', # String | Text the composition's name must contain
760
+ ids: 'ids_example', # String | Only these compositions (comma-separated ids, at most 50), those of them you may see. Ask for the compositions a workflow shows with this, so each is found whatever page it would be on. An id you may not see is left out, as one that does not exist is.
761
+ limit: 56, # Integer | Page size (1-100, 50 when not given)
762
+ offset: 56, # Integer | How many to skip (0 when not given)
763
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
764
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
765
+ }
766
+
767
+ begin
768
+ # List the compositions a workflow can show, and what each can do
769
+ result = api_instance.list_workspace_workflow_composition_options(workspace_id, opts)
770
+ p result
771
+ rescue ApiSdkRb::ApiError => e
772
+ puts "Error when calling WorkflowsApi->list_workspace_workflow_composition_options: #{e}"
773
+ end
774
+ ```
775
+
776
+ #### Using the list_workspace_workflow_composition_options_with_http_info variant
777
+
778
+ This returns an Array which contains the response data, status code and headers.
779
+
780
+ > <Array(<ListWorkspaceWorkflowCompositionOptions200Response>, Integer, Hash)> list_workspace_workflow_composition_options_with_http_info(workspace_id, opts)
781
+
782
+ ```ruby
783
+ begin
784
+ # List the compositions a workflow can show, and what each can do
785
+ data, status_code, headers = api_instance.list_workspace_workflow_composition_options_with_http_info(workspace_id, opts)
786
+ p status_code # => 2xx
787
+ p headers # => { ... }
788
+ p data # => <ListWorkspaceWorkflowCompositionOptions200Response>
789
+ rescue ApiSdkRb::ApiError => e
790
+ puts "Error when calling WorkflowsApi->list_workspace_workflow_composition_options_with_http_info: #{e}"
791
+ end
792
+ ```
793
+
794
+ ### Parameters
795
+
796
+ | Name | Type | Description | Notes |
797
+ | ---- | ---- | ----------- | ----- |
798
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
799
+ | **search** | **String** | Text the composition&#39;s name must contain | [optional] |
800
+ | **ids** | **String** | Only these compositions (comma-separated ids, at most 50), those of them you may see. Ask for the compositions a workflow shows with this, so each is found whatever page it would be on. An id you may not see is left out, as one that does not exist is. | [optional] |
801
+ | **limit** | **Integer** | Page size (1-100, 50 when not given) | [optional] |
802
+ | **offset** | **Integer** | How many to skip (0 when not given) | [optional] |
803
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
804
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
805
+
806
+ ### Return type
807
+
808
+ [**ListWorkspaceWorkflowCompositionOptions200Response**](ListWorkspaceWorkflowCompositionOptions200Response.md)
809
+
810
+ ### Authorization
811
+
812
+ [apiKeyAuth](../README.md#apiKeyAuth)
813
+
814
+ ### HTTP request headers
815
+
816
+ - **Content-Type**: Not defined
817
+ - **Accept**: application/json
818
+
819
+
820
+ ## list_workspace_workflow_presets
821
+
822
+ > <ListWorkspaceWorkflowPresets200Response> list_workspace_workflow_presets(workspace_id, opts)
823
+
824
+ List the starting points for a new Workflow
825
+
826
+ The workflows you can start from in this workspace: published workflows that Widgetic offers or, for one of a partner's managed users, that the partner offers (a managed user is never shown Widgetic's, and a person is never shown a partner's). Only what can be started now is listed, in the order the offerer set (smallest `position` first, then by `key`). Each shows what you would get, and none shows who made it or any id of its own. Start from one with `createWorkspaceWorkflowFromPreset`. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can read the list.
827
+
828
+ ### Examples
829
+
830
+ ```ruby
831
+ require 'time'
832
+ require 'api-sdk-rb'
833
+ # setup authorization
834
+ ApiSdkRb.configure do |config|
835
+ # Configure Bearer authorization (JWT): apiKeyAuth
836
+ config.access_token = 'YOUR_BEARER_TOKEN'
837
+ end
838
+
839
+ api_instance = ApiSdkRb::WorkflowsApi.new
840
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
841
+ opts = {
842
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
843
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
844
+ }
845
+
846
+ begin
847
+ # List the starting points for a new Workflow
848
+ result = api_instance.list_workspace_workflow_presets(workspace_id, opts)
849
+ p result
850
+ rescue ApiSdkRb::ApiError => e
851
+ puts "Error when calling WorkflowsApi->list_workspace_workflow_presets: #{e}"
852
+ end
853
+ ```
854
+
855
+ #### Using the list_workspace_workflow_presets_with_http_info variant
856
+
857
+ This returns an Array which contains the response data, status code and headers.
858
+
859
+ > <Array(<ListWorkspaceWorkflowPresets200Response>, Integer, Hash)> list_workspace_workflow_presets_with_http_info(workspace_id, opts)
860
+
861
+ ```ruby
862
+ begin
863
+ # List the starting points for a new Workflow
864
+ data, status_code, headers = api_instance.list_workspace_workflow_presets_with_http_info(workspace_id, opts)
865
+ p status_code # => 2xx
866
+ p headers # => { ... }
867
+ p data # => <ListWorkspaceWorkflowPresets200Response>
868
+ rescue ApiSdkRb::ApiError => e
869
+ puts "Error when calling WorkflowsApi->list_workspace_workflow_presets_with_http_info: #{e}"
870
+ end
871
+ ```
872
+
873
+ ### Parameters
874
+
875
+ | Name | Type | Description | Notes |
876
+ | ---- | ---- | ----------- | ----- |
877
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
878
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
879
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
880
+
881
+ ### Return type
882
+
883
+ [**ListWorkspaceWorkflowPresets200Response**](ListWorkspaceWorkflowPresets200Response.md)
884
+
885
+ ### Authorization
886
+
887
+ [apiKeyAuth](../README.md#apiKeyAuth)
888
+
889
+ ### HTTP request headers
890
+
891
+ - **Content-Type**: Not defined
892
+ - **Accept**: application/json
893
+
894
+
895
+ ## list_workspace_workflow_versions
896
+
897
+ > <ListWorkspaceWorkflowVersions200Response> list_workspace_workflow_versions(workspace_id, workflow_id, opts)
898
+
899
+ List the Published Versions of a Workflow
900
+
901
+ Every version the workflow has had, newest first, with who published it and when. The one visitors get is marked `isLive`. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can read.
902
+
903
+ ### Examples
904
+
905
+ ```ruby
906
+ require 'time'
907
+ require 'api-sdk-rb'
908
+ # setup authorization
909
+ ApiSdkRb.configure do |config|
910
+ # Configure Bearer authorization (JWT): apiKeyAuth
911
+ config.access_token = 'YOUR_BEARER_TOKEN'
912
+ end
913
+
914
+ api_instance = ApiSdkRb::WorkflowsApi.new
915
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
916
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
917
+ opts = {
918
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
919
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
920
+ }
921
+
922
+ begin
923
+ # List the Published Versions of a Workflow
924
+ result = api_instance.list_workspace_workflow_versions(workspace_id, workflow_id, opts)
925
+ p result
926
+ rescue ApiSdkRb::ApiError => e
927
+ puts "Error when calling WorkflowsApi->list_workspace_workflow_versions: #{e}"
928
+ end
929
+ ```
930
+
931
+ #### Using the list_workspace_workflow_versions_with_http_info variant
932
+
933
+ This returns an Array which contains the response data, status code and headers.
934
+
935
+ > <Array(<ListWorkspaceWorkflowVersions200Response>, Integer, Hash)> list_workspace_workflow_versions_with_http_info(workspace_id, workflow_id, opts)
936
+
937
+ ```ruby
938
+ begin
939
+ # List the Published Versions of a Workflow
940
+ data, status_code, headers = api_instance.list_workspace_workflow_versions_with_http_info(workspace_id, workflow_id, opts)
941
+ p status_code # => 2xx
942
+ p headers # => { ... }
943
+ p data # => <ListWorkspaceWorkflowVersions200Response>
944
+ rescue ApiSdkRb::ApiError => e
945
+ puts "Error when calling WorkflowsApi->list_workspace_workflow_versions_with_http_info: #{e}"
946
+ end
947
+ ```
948
+
949
+ ### Parameters
950
+
951
+ | Name | Type | Description | Notes |
952
+ | ---- | ---- | ----------- | ----- |
953
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
954
+ | **workflow_id** | **String** | The workflow&#39;s id | |
955
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
956
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
957
+
958
+ ### Return type
959
+
960
+ [**ListWorkspaceWorkflowVersions200Response**](ListWorkspaceWorkflowVersions200Response.md)
961
+
962
+ ### Authorization
963
+
964
+ [apiKeyAuth](../README.md#apiKeyAuth)
965
+
966
+ ### HTTP request headers
967
+
968
+ - **Content-Type**: Not defined
969
+ - **Accept**: application/json
970
+
971
+
972
+ ## list_workspace_workflows
973
+
974
+ > <ListWorkspaceWorkflows200Response> list_workspace_workflows(workspace_id, opts)
975
+
976
+ List the Workflows of a Workspace
977
+
978
+ Lists the workspace's workflows, newest first unless `sort` says otherwise. Archived workflows are left out unless `status` asks for them (`archived`, or `all`). For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can read the list.
979
+
980
+ ### Examples
981
+
982
+ ```ruby
983
+ require 'time'
984
+ require 'api-sdk-rb'
985
+ # setup authorization
986
+ ApiSdkRb.configure do |config|
987
+ # Configure Bearer authorization (JWT): apiKeyAuth
988
+ config.access_token = 'YOUR_BEARER_TOKEN'
989
+ end
990
+
991
+ api_instance = ApiSdkRb::WorkflowsApi.new
992
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
993
+ opts = {
994
+ search: 'search_example', # String | Text the workflow's name must contain
995
+ status: 'draft', # String | One state to list (`draft`, `live`, `paused`, `archived`), or `all` for every state. Without it, the ones in use (draft, live and paused).
996
+ sort: 'runsCount:desc', # String | `<field>:<asc|desc>` where field is createdAt, lastPublishedAt, runsCount or name (or just asc / desc for createdAt). Newest first when not given.
997
+ limit: 56, # Integer | Page size (1-100, 50 when not given)
998
+ offset: 56, # Integer | How many to skip (0 when not given)
999
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1000
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1001
+ }
1002
+
1003
+ begin
1004
+ # List the Workflows of a Workspace
1005
+ result = api_instance.list_workspace_workflows(workspace_id, opts)
1006
+ p result
1007
+ rescue ApiSdkRb::ApiError => e
1008
+ puts "Error when calling WorkflowsApi->list_workspace_workflows: #{e}"
1009
+ end
1010
+ ```
1011
+
1012
+ #### Using the list_workspace_workflows_with_http_info variant
1013
+
1014
+ This returns an Array which contains the response data, status code and headers.
1015
+
1016
+ > <Array(<ListWorkspaceWorkflows200Response>, Integer, Hash)> list_workspace_workflows_with_http_info(workspace_id, opts)
1017
+
1018
+ ```ruby
1019
+ begin
1020
+ # List the Workflows of a Workspace
1021
+ data, status_code, headers = api_instance.list_workspace_workflows_with_http_info(workspace_id, opts)
1022
+ p status_code # => 2xx
1023
+ p headers # => { ... }
1024
+ p data # => <ListWorkspaceWorkflows200Response>
1025
+ rescue ApiSdkRb::ApiError => e
1026
+ puts "Error when calling WorkflowsApi->list_workspace_workflows_with_http_info: #{e}"
1027
+ end
1028
+ ```
1029
+
1030
+ ### Parameters
1031
+
1032
+ | Name | Type | Description | Notes |
1033
+ | ---- | ---- | ----------- | ----- |
1034
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
1035
+ | **search** | **String** | Text the workflow&#39;s name must contain | [optional] |
1036
+ | **status** | **String** | One state to list (&#x60;draft&#x60;, &#x60;live&#x60;, &#x60;paused&#x60;, &#x60;archived&#x60;), or &#x60;all&#x60; for every state. Without it, the ones in use (draft, live and paused). | [optional] |
1037
+ | **sort** | **String** | &#x60;&lt;field&gt;:&lt;asc|desc&gt;&#x60; where field is createdAt, lastPublishedAt, runsCount or name (or just asc / desc for createdAt). Newest first when not given. | [optional] |
1038
+ | **limit** | **Integer** | Page size (1-100, 50 when not given) | [optional] |
1039
+ | **offset** | **Integer** | How many to skip (0 when not given) | [optional] |
1040
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1041
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1042
+
1043
+ ### Return type
1044
+
1045
+ [**ListWorkspaceWorkflows200Response**](ListWorkspaceWorkflows200Response.md)
1046
+
1047
+ ### Authorization
1048
+
1049
+ [apiKeyAuth](../README.md#apiKeyAuth)
1050
+
1051
+ ### HTTP request headers
1052
+
1053
+ - **Content-Type**: Not defined
1054
+ - **Accept**: application/json
1055
+
1056
+
1057
+ ## pause_workspace_workflow
1058
+
1059
+ > <WorkflowResponse> pause_workspace_workflow(workspace_id, workflow_id, opts)
1060
+
1061
+ Pause a Workflow
1062
+
1063
+ While a workflow is paused, its embeds show only their first composition (the `composition-id` of the embed) and no visitor moves on. The live version is kept, and visitors partway through carry on from where they were when it is resumed. Only a live workflow can be paused. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can pause.
1064
+
1065
+ ### Examples
1066
+
1067
+ ```ruby
1068
+ require 'time'
1069
+ require 'api-sdk-rb'
1070
+ # setup authorization
1071
+ ApiSdkRb.configure do |config|
1072
+ # Configure Bearer authorization (JWT): apiKeyAuth
1073
+ config.access_token = 'YOUR_BEARER_TOKEN'
1074
+ end
1075
+
1076
+ api_instance = ApiSdkRb::WorkflowsApi.new
1077
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
1078
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
1079
+ opts = {
1080
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1081
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1082
+ }
1083
+
1084
+ begin
1085
+ # Pause a Workflow
1086
+ result = api_instance.pause_workspace_workflow(workspace_id, workflow_id, opts)
1087
+ p result
1088
+ rescue ApiSdkRb::ApiError => e
1089
+ puts "Error when calling WorkflowsApi->pause_workspace_workflow: #{e}"
1090
+ end
1091
+ ```
1092
+
1093
+ #### Using the pause_workspace_workflow_with_http_info variant
1094
+
1095
+ This returns an Array which contains the response data, status code and headers.
1096
+
1097
+ > <Array(<WorkflowResponse>, Integer, Hash)> pause_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
1098
+
1099
+ ```ruby
1100
+ begin
1101
+ # Pause a Workflow
1102
+ data, status_code, headers = api_instance.pause_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
1103
+ p status_code # => 2xx
1104
+ p headers # => { ... }
1105
+ p data # => <WorkflowResponse>
1106
+ rescue ApiSdkRb::ApiError => e
1107
+ puts "Error when calling WorkflowsApi->pause_workspace_workflow_with_http_info: #{e}"
1108
+ end
1109
+ ```
1110
+
1111
+ ### Parameters
1112
+
1113
+ | Name | Type | Description | Notes |
1114
+ | ---- | ---- | ----------- | ----- |
1115
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
1116
+ | **workflow_id** | **String** | The workflow&#39;s id | |
1117
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1118
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1119
+
1120
+ ### Return type
1121
+
1122
+ [**WorkflowResponse**](WorkflowResponse.md)
1123
+
1124
+ ### Authorization
1125
+
1126
+ [apiKeyAuth](../README.md#apiKeyAuth)
1127
+
1128
+ ### HTTP request headers
1129
+
1130
+ - **Content-Type**: Not defined
1131
+ - **Accept**: application/json
1132
+
1133
+
1134
+ ## publish_workspace_workflow
1135
+
1136
+ > <PublishWorkspaceWorkflow200Response> publish_workspace_workflow(workspace_id, workflow_id, idempotency_key, publish_workspace_workflow_request, opts)
1137
+
1138
+ Publish the Draft of a Workflow
1139
+
1140
+ Checks the draft and, when nothing stops it, makes it the next version and the one new visitors get. Versions never change once published. A visitor already partway through keeps the version they started on (for up to 30 days). The check reads what each composition can do right now (a table the visitor adds to, a goal the widget reports, the websites it may be embedded on), so a workflow never goes live pointing at something that has gone. It is refused with 422 (`BUSINESS_OPERATION_INVALID`) when the draft has errors; the `issues` in the error's `details` name the blocks to fix: an unconnected trigger, a condition without rules, a composition that is not published, a field or action that is gone, a composition whose allowed websites exclude the site the workflow starts on. Nothing is published when the draft has no changes since the live version. The `revision` is the one the editor read, and a publish of a draft that has moved on is refused with 409. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can publish.
1141
+
1142
+ ### Examples
1143
+
1144
+ ```ruby
1145
+ require 'time'
1146
+ require 'api-sdk-rb'
1147
+ # setup authorization
1148
+ ApiSdkRb.configure do |config|
1149
+ # Configure Bearer authorization (JWT): apiKeyAuth
1150
+ config.access_token = 'YOUR_BEARER_TOKEN'
1151
+ end
1152
+
1153
+ api_instance = ApiSdkRb::WorkflowsApi.new
1154
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
1155
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
1156
+ idempotency_key = '9b2d6f0a-3c41-4e5a-8d77-1f2e3a4b5c6d' # String | Required: a call without it is refused with `400`. A key of your own that names this one request; a UUID is ideal. It is 8 to 50 characters of letters, digits, `-` and `_`. Send the same key again when you retry (after a timeout, a dropped connection or a `5xx`) and the call is carried out once: the retry gets the first answer back, marked `X-Idempotency-Cached: true`. The same key with a different body is refused with `422`, and a retry that arrives while the first call is still running with `409` (see `Retry-After`).
1157
+ publish_workspace_workflow_request = ApiSdkRb::PublishWorkspaceWorkflowRequest.new({revision: 37}) # PublishWorkspaceWorkflowRequest |
1158
+ opts = {
1159
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1160
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1161
+ }
1162
+
1163
+ begin
1164
+ # Publish the Draft of a Workflow
1165
+ result = api_instance.publish_workspace_workflow(workspace_id, workflow_id, idempotency_key, publish_workspace_workflow_request, opts)
1166
+ p result
1167
+ rescue ApiSdkRb::ApiError => e
1168
+ puts "Error when calling WorkflowsApi->publish_workspace_workflow: #{e}"
1169
+ end
1170
+ ```
1171
+
1172
+ #### Using the publish_workspace_workflow_with_http_info variant
1173
+
1174
+ This returns an Array which contains the response data, status code and headers.
1175
+
1176
+ > <Array(<PublishWorkspaceWorkflow200Response>, Integer, Hash)> publish_workspace_workflow_with_http_info(workspace_id, workflow_id, idempotency_key, publish_workspace_workflow_request, opts)
1177
+
1178
+ ```ruby
1179
+ begin
1180
+ # Publish the Draft of a Workflow
1181
+ data, status_code, headers = api_instance.publish_workspace_workflow_with_http_info(workspace_id, workflow_id, idempotency_key, publish_workspace_workflow_request, opts)
1182
+ p status_code # => 2xx
1183
+ p headers # => { ... }
1184
+ p data # => <PublishWorkspaceWorkflow200Response>
1185
+ rescue ApiSdkRb::ApiError => e
1186
+ puts "Error when calling WorkflowsApi->publish_workspace_workflow_with_http_info: #{e}"
1187
+ end
1188
+ ```
1189
+
1190
+ ### Parameters
1191
+
1192
+ | Name | Type | Description | Notes |
1193
+ | ---- | ---- | ----------- | ----- |
1194
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
1195
+ | **workflow_id** | **String** | The workflow&#39;s id | |
1196
+ | **idempotency_key** | **String** | Required: a call without it is refused with &#x60;400&#x60;. A key of your own that names this one request; a UUID is ideal. It is 8 to 50 characters of letters, digits, &#x60;-&#x60; and &#x60;_&#x60;. Send the same key again when you retry (after a timeout, a dropped connection or a &#x60;5xx&#x60;) and the call is carried out once: the retry gets the first answer back, marked &#x60;X-Idempotency-Cached: true&#x60;. The same key with a different body is refused with &#x60;422&#x60;, and a retry that arrives while the first call is still running with &#x60;409&#x60; (see &#x60;Retry-After&#x60;). | |
1197
+ | **publish_workspace_workflow_request** | [**PublishWorkspaceWorkflowRequest**](PublishWorkspaceWorkflowRequest.md) | | |
1198
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1199
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1200
+
1201
+ ### Return type
1202
+
1203
+ [**PublishWorkspaceWorkflow200Response**](PublishWorkspaceWorkflow200Response.md)
1204
+
1205
+ ### Authorization
1206
+
1207
+ [apiKeyAuth](../README.md#apiKeyAuth)
1208
+
1209
+ ### HTTP request headers
1210
+
1211
+ - **Content-Type**: application/json
1212
+ - **Accept**: application/json
1213
+
1214
+
1215
+ ## restore_workspace_workflow_version
1216
+
1217
+ > <WorkflowDetailResponse> restore_workspace_workflow_version(workspace_id, workflow_id, version_id, publish_workspace_workflow_request, opts)
1218
+
1219
+ Restore a Version of a Workflow into the Draft
1220
+
1221
+ Copies a published version into the draft, so it can be changed and published again. Nothing is published and nothing visitors see changes: the version stays in the history as it was. Names the `revision` the editor read. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can restore.
1222
+
1223
+ ### Examples
1224
+
1225
+ ```ruby
1226
+ require 'time'
1227
+ require 'api-sdk-rb'
1228
+ # setup authorization
1229
+ ApiSdkRb.configure do |config|
1230
+ # Configure Bearer authorization (JWT): apiKeyAuth
1231
+ config.access_token = 'YOUR_BEARER_TOKEN'
1232
+ end
1233
+
1234
+ api_instance = ApiSdkRb::WorkflowsApi.new
1235
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
1236
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
1237
+ version_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The id of a published version of the workflow
1238
+ publish_workspace_workflow_request = ApiSdkRb::PublishWorkspaceWorkflowRequest.new({revision: 37}) # PublishWorkspaceWorkflowRequest |
1239
+ opts = {
1240
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1241
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1242
+ }
1243
+
1244
+ begin
1245
+ # Restore a Version of a Workflow into the Draft
1246
+ result = api_instance.restore_workspace_workflow_version(workspace_id, workflow_id, version_id, publish_workspace_workflow_request, opts)
1247
+ p result
1248
+ rescue ApiSdkRb::ApiError => e
1249
+ puts "Error when calling WorkflowsApi->restore_workspace_workflow_version: #{e}"
1250
+ end
1251
+ ```
1252
+
1253
+ #### Using the restore_workspace_workflow_version_with_http_info variant
1254
+
1255
+ This returns an Array which contains the response data, status code and headers.
1256
+
1257
+ > <Array(<WorkflowDetailResponse>, Integer, Hash)> restore_workspace_workflow_version_with_http_info(workspace_id, workflow_id, version_id, publish_workspace_workflow_request, opts)
1258
+
1259
+ ```ruby
1260
+ begin
1261
+ # Restore a Version of a Workflow into the Draft
1262
+ data, status_code, headers = api_instance.restore_workspace_workflow_version_with_http_info(workspace_id, workflow_id, version_id, publish_workspace_workflow_request, opts)
1263
+ p status_code # => 2xx
1264
+ p headers # => { ... }
1265
+ p data # => <WorkflowDetailResponse>
1266
+ rescue ApiSdkRb::ApiError => e
1267
+ puts "Error when calling WorkflowsApi->restore_workspace_workflow_version_with_http_info: #{e}"
1268
+ end
1269
+ ```
1270
+
1271
+ ### Parameters
1272
+
1273
+ | Name | Type | Description | Notes |
1274
+ | ---- | ---- | ----------- | ----- |
1275
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
1276
+ | **workflow_id** | **String** | The workflow&#39;s id | |
1277
+ | **version_id** | **String** | The id of a published version of the workflow | |
1278
+ | **publish_workspace_workflow_request** | [**PublishWorkspaceWorkflowRequest**](PublishWorkspaceWorkflowRequest.md) | | |
1279
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1280
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1281
+
1282
+ ### Return type
1283
+
1284
+ [**WorkflowDetailResponse**](WorkflowDetailResponse.md)
1285
+
1286
+ ### Authorization
1287
+
1288
+ [apiKeyAuth](../README.md#apiKeyAuth)
1289
+
1290
+ ### HTTP request headers
1291
+
1292
+ - **Content-Type**: application/json
1293
+ - **Accept**: application/json
1294
+
1295
+
1296
+ ## resume_workspace_workflow
1297
+
1298
+ > <WorkflowResponse> resume_workspace_workflow(workspace_id, workflow_id, opts)
1299
+
1300
+ Resume a Paused Workflow
1301
+
1302
+ Makes a paused workflow live again, on the version that was live when it was paused. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can resume.
1303
+
1304
+ ### Examples
1305
+
1306
+ ```ruby
1307
+ require 'time'
1308
+ require 'api-sdk-rb'
1309
+ # setup authorization
1310
+ ApiSdkRb.configure do |config|
1311
+ # Configure Bearer authorization (JWT): apiKeyAuth
1312
+ config.access_token = 'YOUR_BEARER_TOKEN'
1313
+ end
1314
+
1315
+ api_instance = ApiSdkRb::WorkflowsApi.new
1316
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
1317
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
1318
+ opts = {
1319
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1320
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1321
+ }
1322
+
1323
+ begin
1324
+ # Resume a Paused Workflow
1325
+ result = api_instance.resume_workspace_workflow(workspace_id, workflow_id, opts)
1326
+ p result
1327
+ rescue ApiSdkRb::ApiError => e
1328
+ puts "Error when calling WorkflowsApi->resume_workspace_workflow: #{e}"
1329
+ end
1330
+ ```
1331
+
1332
+ #### Using the resume_workspace_workflow_with_http_info variant
1333
+
1334
+ This returns an Array which contains the response data, status code and headers.
1335
+
1336
+ > <Array(<WorkflowResponse>, Integer, Hash)> resume_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
1337
+
1338
+ ```ruby
1339
+ begin
1340
+ # Resume a Paused Workflow
1341
+ data, status_code, headers = api_instance.resume_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
1342
+ p status_code # => 2xx
1343
+ p headers # => { ... }
1344
+ p data # => <WorkflowResponse>
1345
+ rescue ApiSdkRb::ApiError => e
1346
+ puts "Error when calling WorkflowsApi->resume_workspace_workflow_with_http_info: #{e}"
1347
+ end
1348
+ ```
1349
+
1350
+ ### Parameters
1351
+
1352
+ | Name | Type | Description | Notes |
1353
+ | ---- | ---- | ----------- | ----- |
1354
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
1355
+ | **workflow_id** | **String** | The workflow&#39;s id | |
1356
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1357
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1358
+
1359
+ ### Return type
1360
+
1361
+ [**WorkflowResponse**](WorkflowResponse.md)
1362
+
1363
+ ### Authorization
1364
+
1365
+ [apiKeyAuth](../README.md#apiKeyAuth)
1366
+
1367
+ ### HTTP request headers
1368
+
1369
+ - **Content-Type**: Not defined
1370
+ - **Accept**: application/json
1371
+
1372
+
1373
+ ## save_workspace_workflow
1374
+
1375
+ > <WorkflowResponse> save_workspace_workflow(workspace_id, workflow_id, save_workspace_workflow_request, opts)
1376
+
1377
+ Save the Draft of a Workflow
1378
+
1379
+ Saves the name, the time zone and/or the graph of the draft. Send at least one. The save names the `revision` the editor started from and is refused with 409 (`BUSINESS_STATE_CONFLICT`) when the draft has moved on, so two people editing do not overwrite each other without knowing; read the workflow again and apply the change to it. A save is never refused for what is wrong with the graph (a block with no connection yet is normal in a draft): only the shape is judged here, and what stops a workflow going live is told when it is published. A graph larger than 200,000 bytes, or with more than 100 blocks or 300 connections, is refused. An archived workflow cannot be saved. Saving a live workflow changes the draft only: visitors keep getting the published version until the changes are published. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can save.
1380
+
1381
+ ### Examples
1382
+
1383
+ ```ruby
1384
+ require 'time'
1385
+ require 'api-sdk-rb'
1386
+ # setup authorization
1387
+ ApiSdkRb.configure do |config|
1388
+ # Configure Bearer authorization (JWT): apiKeyAuth
1389
+ config.access_token = 'YOUR_BEARER_TOKEN'
1390
+ end
1391
+
1392
+ api_instance = ApiSdkRb::WorkflowsApi.new
1393
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
1394
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
1395
+ save_workspace_workflow_request = ApiSdkRb::SaveWorkspaceWorkflowRequest.new({revision: 37}) # SaveWorkspaceWorkflowRequest |
1396
+ opts = {
1397
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1398
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1399
+ }
1400
+
1401
+ begin
1402
+ # Save the Draft of a Workflow
1403
+ result = api_instance.save_workspace_workflow(workspace_id, workflow_id, save_workspace_workflow_request, opts)
1404
+ p result
1405
+ rescue ApiSdkRb::ApiError => e
1406
+ puts "Error when calling WorkflowsApi->save_workspace_workflow: #{e}"
1407
+ end
1408
+ ```
1409
+
1410
+ #### Using the save_workspace_workflow_with_http_info variant
1411
+
1412
+ This returns an Array which contains the response data, status code and headers.
1413
+
1414
+ > <Array(<WorkflowResponse>, Integer, Hash)> save_workspace_workflow_with_http_info(workspace_id, workflow_id, save_workspace_workflow_request, opts)
1415
+
1416
+ ```ruby
1417
+ begin
1418
+ # Save the Draft of a Workflow
1419
+ data, status_code, headers = api_instance.save_workspace_workflow_with_http_info(workspace_id, workflow_id, save_workspace_workflow_request, opts)
1420
+ p status_code # => 2xx
1421
+ p headers # => { ... }
1422
+ p data # => <WorkflowResponse>
1423
+ rescue ApiSdkRb::ApiError => e
1424
+ puts "Error when calling WorkflowsApi->save_workspace_workflow_with_http_info: #{e}"
1425
+ end
1426
+ ```
1427
+
1428
+ ### Parameters
1429
+
1430
+ | Name | Type | Description | Notes |
1431
+ | ---- | ---- | ----------- | ----- |
1432
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
1433
+ | **workflow_id** | **String** | The workflow&#39;s id | |
1434
+ | **save_workspace_workflow_request** | [**SaveWorkspaceWorkflowRequest**](SaveWorkspaceWorkflowRequest.md) | | |
1435
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1436
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1437
+
1438
+ ### Return type
1439
+
1440
+ [**WorkflowResponse**](WorkflowResponse.md)
1441
+
1442
+ ### Authorization
1443
+
1444
+ [apiKeyAuth](../README.md#apiKeyAuth)
1445
+
1446
+ ### HTTP request headers
1447
+
1448
+ - **Content-Type**: application/json
1449
+ - **Accept**: application/json
1450
+
1451
+
1452
+ ## unarchive_workspace_workflow
1453
+
1454
+ > <WorkflowResponse> unarchive_workspace_workflow(workspace_id, workflow_id, opts)
1455
+
1456
+ Unarchive a Workflow
1457
+
1458
+ Brings an archived workflow back into the list: as paused when it was ever published (resume it to serve visitors again), as a draft when it never was. For personal workspace, use 'personal' as workspaceId. For organization workspace, use the organization UUID as workspaceId. Any active member can unarchive.
1459
+
1460
+ ### Examples
1461
+
1462
+ ```ruby
1463
+ require 'time'
1464
+ require 'api-sdk-rb'
1465
+ # setup authorization
1466
+ ApiSdkRb.configure do |config|
1467
+ # Configure Bearer authorization (JWT): apiKeyAuth
1468
+ config.access_token = 'YOUR_BEARER_TOKEN'
1469
+ end
1470
+
1471
+ api_instance = ApiSdkRb::WorkflowsApi.new
1472
+ workspace_id = 'personal' # String | The workspace: 'personal' for your own workspace, or the UUID of an organization. A call made for one of your managed users (`X-Managed-User-Id`) always uses 'personal': a managed user has no other workspace, and a call that names an organization is refused with 403.
1473
+ workflow_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String | The workflow's id
1474
+ opts = {
1475
+ x_managed_user_id: '3f2b8c1e-7a4d-4e0b-9c55-2d1a6b7e8f90', # String | The id Widgetic gave the managed user (`POST /managed-users`). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1476
+ x_managed_user_external_id: 'customer-1042' # String | Your own id for the managed user (its `externalId`), when you do not keep Widgetic's. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer's work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user's compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers `404` (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers `404` with `MANAGED_USER_NOT_FOUND`. An empty, repeated or malformed header is `400` with `MANAGED_USER_SCOPE_INVALID`; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with `403` and `MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE`: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer's browser holds, use an editor session. An `Idempotency-Key` is kept apart for each managed user.
1477
+ }
1478
+
1479
+ begin
1480
+ # Unarchive a Workflow
1481
+ result = api_instance.unarchive_workspace_workflow(workspace_id, workflow_id, opts)
1482
+ p result
1483
+ rescue ApiSdkRb::ApiError => e
1484
+ puts "Error when calling WorkflowsApi->unarchive_workspace_workflow: #{e}"
1485
+ end
1486
+ ```
1487
+
1488
+ #### Using the unarchive_workspace_workflow_with_http_info variant
1489
+
1490
+ This returns an Array which contains the response data, status code and headers.
1491
+
1492
+ > <Array(<WorkflowResponse>, Integer, Hash)> unarchive_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
1493
+
1494
+ ```ruby
1495
+ begin
1496
+ # Unarchive a Workflow
1497
+ data, status_code, headers = api_instance.unarchive_workspace_workflow_with_http_info(workspace_id, workflow_id, opts)
1498
+ p status_code # => 2xx
1499
+ p headers # => { ... }
1500
+ p data # => <WorkflowResponse>
1501
+ rescue ApiSdkRb::ApiError => e
1502
+ puts "Error when calling WorkflowsApi->unarchive_workspace_workflow_with_http_info: #{e}"
1503
+ end
1504
+ ```
1505
+
1506
+ ### Parameters
1507
+
1508
+ | Name | Type | Description | Notes |
1509
+ | ---- | ---- | ----------- | ----- |
1510
+ | **workspace_id** | **String** | The workspace: &#39;personal&#39; for your own workspace, or the UUID of an organization. A call made for one of your managed users (&#x60;X-Managed-User-Id&#x60;) always uses &#39;personal&#39;: a managed user has no other workspace, and a call that names an organization is refused with 403. | |
1511
+ | **workflow_id** | **String** | The workflow&#39;s id | |
1512
+ | **x_managed_user_id** | **String** | The id Widgetic gave the managed user (&#x60;POST /managed-users&#x60;). Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1513
+ | **x_managed_user_external_id** | **String** | Your own id for the managed user (its &#x60;externalId&#x60;), when you do not keep Widgetic&#39;s. Makes this call for one of your managed users, so that a mistake in your own code cannot reach another customer&#39;s work. Send this header, or the other one, never both. Left out, the call works on your whole account, as it always has. With it, the call reaches only that user&#39;s compositions and workflows: a list shows only theirs, a composition or a workflow the call makes is filed under them, and one of another user, or one that does not exist, answers &#x60;404&#x60; (the same answer, so the call cannot be used to find out what another customer has). A managed user that is not yours answers &#x60;404&#x60; with &#x60;MANAGED_USER_NOT_FOUND&#x60;. An empty, repeated or malformed header is &#x60;400&#x60; with &#x60;MANAGED_USER_SCOPE_INVALID&#x60;; an empty header is never read as no header. A call that is about the whole account, such as the list of your managed users, is refused with &#x60;403&#x60; and &#x60;MANAGED_USER_SCOPE_ROUTE_NOT_AVAILABLE&#x60;: send it without the header. Only your API key can send it. The header is a limit the call asks for: whoever holds the key can leave it out, so for a credential that a customer&#39;s browser holds, use an editor session. An &#x60;Idempotency-Key&#x60; is kept apart for each managed user. | [optional] |
1514
+
1515
+ ### Return type
1516
+
1517
+ [**WorkflowResponse**](WorkflowResponse.md)
1518
+
1519
+ ### Authorization
1520
+
1521
+ [apiKeyAuth](../README.md#apiKeyAuth)
1522
+
1523
+ ### HTTP request headers
1524
+
1525
+ - **Content-Type**: Not defined
1526
+ - **Accept**: application/json
1527
+