api-sdk-rb 1.11.66 → 1.11.111
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +192 -9
- data/docs/AdapterConnection.md +7 -1
- data/docs/BrandColor.md +22 -0
- data/docs/BrandFont.md +24 -0
- data/docs/BrandKitApi.md +593 -0
- data/docs/BrandKitAssetView.md +42 -0
- data/docs/BrandKitFigmaSource.md +26 -0
- data/docs/BrandKitTokens.md +24 -0
- data/docs/BrandKitTokensFonts.md +24 -0
- data/docs/BrandKitView.md +36 -0
- data/docs/BrandKitViewOwner.md +20 -0
- data/docs/BrandKitViewResponse.md +22 -0
- data/docs/BrandSpacing.md +32 -0
- data/docs/Composition.md +5 -1
- data/docs/CompositionLastEditedBy.md +20 -0
- data/docs/CompositionsApi.md +217 -135
- data/docs/ConfirmAdapterConnectionRequest.md +18 -0
- data/docs/CreateWidget201ResponseData.md +2 -4
- data/docs/CreateWorkspaceWorkflowFromPreset201Response.md +22 -0
- data/docs/CreateWorkspaceWorkflowFromPresetRequest.md +20 -0
- data/docs/CreateWorkspaceWorkflowRequest.md +22 -0
- data/docs/DeleteWorkspaceWorkflow200Response.md +22 -0
- data/docs/GetPublicCompositionEmbed200Response.md +7 -1
- data/docs/GetPublicCompositionEmbed200ResponseAdapters.md +20 -0
- data/docs/GetPublicCompositionEmbed200ResponseAdaptersCaptcha.md +18 -0
- data/docs/GetPublicCompositionEmbed200ResponseEntries.md +20 -0
- data/docs/GetPublicCompositionEmbed200ResponseMedia.md +18 -0
- data/docs/GetPublicWorkflow200Response.md +22 -0
- data/docs/GetWorkspaceWorkflowStats200Response.md +22 -0
- data/docs/GetWorkspaceWorkflowVersion200Response.md +22 -0
- data/docs/ListPartnerWorkflowPresets200Response.md +22 -0
- data/docs/ListWorkspaceWorkflowCompositionOptions200Response.md +22 -0
- data/docs/ListWorkspaceWorkflowPresets200Response.md +22 -0
- data/docs/ListWorkspaceWorkflowVersions200Response.md +22 -0
- data/docs/ListWorkspaceWorkflows200Response.md +22 -0
- data/docs/ManagedUsersApi.md +1 -1
- data/docs/NewComposition.md +1 -1
- data/docs/NewEditorSession.md +1 -1
- data/docs/OfferWorkflowPresetRequest.md +24 -0
- data/docs/OfferedWorkflowPreset.md +40 -0
- data/docs/OfferedWorkflowPresetList.md +18 -0
- data/docs/OfferedWorkflowPresetWidget.md +22 -0
- data/docs/PartnerApi.md +3360 -538
- data/docs/PartnerCustomization.md +2 -2
- data/docs/PartnerNotification.md +1 -1
- data/docs/PartnersApi.md +294 -2
- data/docs/PatchBrandKitAssetRequest.md +24 -0
- data/docs/PatchBrandKitRequest.md +28 -0
- data/docs/PatchBrandKitRequestFonts.md +24 -0
- data/docs/PatchBrandKitRequestSpacing.md +32 -0
- data/docs/PostBrandKitIconRequest.md +20 -0
- data/docs/PublicEmbedApi.md +270 -4
- data/docs/PublicWorkflow.md +36 -0
- data/docs/PublicWorkflowEventsAccepted.md +22 -0
- data/docs/PublicWorkflowEventsRequest.md +24 -0
- data/docs/PublicWorkflowEventsRequestEventsInner.md +22 -0
- data/docs/PublicWorkflowEventsRequestHeightsInner.md +20 -0
- data/docs/PublicWorkflowTranslation.md +20 -0
- data/docs/PublishWorkspaceWorkflow200Response.md +22 -0
- data/docs/PublishWorkspaceWorkflowRequest.md +18 -0
- data/docs/PutBrandKitRequest.md +22 -0
- data/docs/RemovePartnerWorkflowPreset200Response.md +22 -0
- data/docs/ReportPublicWorkflowEvents200Response.md +22 -0
- data/docs/SaveWorkspaceWorkflow200Response.md +22 -0
- data/docs/SaveWorkspaceWorkflowRequest.md +24 -0
- data/docs/SetAdapterConnectionRequest.md +1 -1
- data/docs/SetPartnerWorkflowPreset200Response.md +22 -0
- data/docs/UpdateComposition.md +1 -1
- data/docs/UsersApi.md +77 -1
- data/docs/Widget.md +2 -4
- data/docs/Workflow.md +50 -0
- data/docs/WorkflowCompositionAction.md +24 -0
- data/docs/WorkflowCompositionField.md +24 -0
- data/docs/WorkflowCompositionOption.md +30 -0
- data/docs/WorkflowCompositionOptionActions.md +22 -0
- data/docs/WorkflowCompositionOptionInputs.md +24 -0
- data/docs/WorkflowCompositionOptions.md +24 -0
- data/docs/WorkflowConditionCase.md +24 -0
- data/docs/WorkflowConditionTest.md +22 -0
- data/docs/WorkflowCounter.md +20 -0
- data/docs/WorkflowDetail.md +60 -0
- data/docs/WorkflowDetailAllOfLastEditedBy.md +20 -0
- data/docs/WorkflowEdge.md +24 -0
- data/docs/WorkflowFieldReference.md +22 -0
- data/docs/WorkflowGraph.md +22 -0
- data/docs/WorkflowIssue.md +28 -0
- data/docs/WorkflowList.md +24 -0
- data/docs/WorkflowNode.md +30 -0
- data/docs/WorkflowNodePosition.md +20 -0
- data/docs/WorkflowPresetChoice.md +26 -0
- data/docs/WorkflowPresetChoices.md +18 -0
- data/docs/WorkflowPresetRemoval.md +18 -0
- data/docs/WorkflowPresetWidget.md +20 -0
- data/docs/WorkflowPublishResult.md +22 -0
- data/docs/WorkflowRemoved.md +18 -0
- data/docs/WorkflowSchedule.md +24 -0
- data/docs/WorkflowStats.md +32 -0
- data/docs/WorkflowStatus.md +15 -0
- data/docs/WorkflowTrigger.md +28 -0
- data/docs/WorkflowTriggerValuesInner.md +20 -0
- data/docs/WorkflowVersion.md +28 -0
- data/docs/WorkflowVersionDetail.md +32 -0
- data/docs/WorkflowVersionList.md +18 -0
- data/docs/WorkflowVersionPublishedBy.md +20 -0
- data/docs/WorkflowsApi.md +1743 -0
- data/docs/WorkspacesApi.md +1527 -0
- data/lib/api-sdk-rb/api/brand_kit_api.rb +581 -0
- data/lib/api-sdk-rb/api/compositions_api.rb +237 -138
- data/lib/api-sdk-rb/api/managed_users_api.rb +2 -2
- data/lib/api-sdk-rb/api/partner_api.rb +3907 -809
- data/lib/api-sdk-rb/api/partners_api.rb +320 -4
- data/lib/api-sdk-rb/api/public_embed_api.rb +283 -6
- data/lib/api-sdk-rb/api/users_api.rb +96 -2
- data/lib/api-sdk-rb/api/workflows_api.rb +1997 -0
- data/lib/api-sdk-rb/api/workspaces_api.rb +1775 -0
- data/lib/api-sdk-rb/configuration.rb +50 -2
- data/lib/api-sdk-rb/models/adapter_connection.rb +48 -5
- data/lib/api-sdk-rb/models/brand_color.rb +329 -0
- data/lib/api-sdk-rb/models/brand_font.rb +357 -0
- data/lib/api-sdk-rb/models/brand_kit_asset_view.rb +409 -0
- data/lib/api-sdk-rb/models/brand_kit_figma_source.rb +277 -0
- data/lib/api-sdk-rb/models/brand_kit_tokens.rb +304 -0
- data/lib/api-sdk-rb/models/brand_kit_tokens_fonts.rb +241 -0
- data/lib/api-sdk-rb/models/brand_kit_view.rb +344 -0
- data/lib/api-sdk-rb/models/brand_kit_view_owner.rb +267 -0
- data/lib/api-sdk-rb/models/brand_kit_view_response.rb +247 -0
- data/lib/api-sdk-rb/models/brand_spacing.rb +557 -0
- data/lib/api-sdk-rb/models/composition.rb +26 -5
- data/lib/api-sdk-rb/models/composition_last_edited_by.rb +242 -0
- data/lib/api-sdk-rb/models/confirm_adapter_connection_request.rb +241 -0
- data/lib/api-sdk-rb/models/create_widget201_response_data.rb +9 -20
- data/lib/api-sdk-rb/models/create_workspace_workflow_from_preset201_response.rb +246 -0
- data/lib/api-sdk-rb/models/create_workspace_workflow_from_preset_request.rb +278 -0
- data/lib/api-sdk-rb/models/create_workspace_workflow_request.rb +271 -0
- data/lib/api-sdk-rb/models/delete_workspace_workflow200_response.rb +246 -0
- data/lib/api-sdk-rb/models/get_public_composition_embed200_response.rb +29 -2
- data/lib/api-sdk-rb/models/get_public_composition_embed200_response_adapters.rb +225 -0
- data/lib/api-sdk-rb/models/get_public_composition_embed200_response_adapters_captcha.rb +216 -0
- data/lib/api-sdk-rb/models/get_public_composition_embed200_response_entries.rb +224 -0
- data/lib/api-sdk-rb/models/get_public_composition_embed200_response_media.rb +216 -0
- data/lib/api-sdk-rb/models/get_public_workflow200_response.rb +246 -0
- data/lib/api-sdk-rb/models/get_workspace_workflow_stats200_response.rb +246 -0
- data/lib/api-sdk-rb/models/get_workspace_workflow_version200_response.rb +246 -0
- data/lib/api-sdk-rb/models/list_partner_workflow_presets200_response.rb +246 -0
- data/lib/api-sdk-rb/models/list_workspace_workflow_composition_options200_response.rb +246 -0
- data/lib/api-sdk-rb/models/list_workspace_workflow_presets200_response.rb +246 -0
- data/lib/api-sdk-rb/models/list_workspace_workflow_versions200_response.rb +246 -0
- data/lib/api-sdk-rb/models/list_workspace_workflows200_response.rb +246 -0
- data/lib/api-sdk-rb/models/new_composition.rb +1 -1
- data/lib/api-sdk-rb/models/new_editor_session.rb +1 -1
- data/lib/api-sdk-rb/models/offer_workflow_preset_request.rb +322 -0
- data/lib/api-sdk-rb/models/offered_workflow_preset.rb +423 -0
- data/lib/api-sdk-rb/models/offered_workflow_preset_list.rb +223 -0
- data/lib/api-sdk-rb/models/offered_workflow_preset_widget.rb +251 -0
- data/lib/api-sdk-rb/models/partner_notification.rb +1 -1
- data/lib/api-sdk-rb/models/partner_notification_event_type.rb +5 -1
- data/lib/api-sdk-rb/models/patch_brand_kit_asset_request.rb +289 -0
- data/lib/api-sdk-rb/models/patch_brand_kit_request.rb +332 -0
- data/lib/api-sdk-rb/models/patch_brand_kit_request_fonts.rb +242 -0
- data/lib/api-sdk-rb/models/patch_brand_kit_request_spacing.rb +502 -0
- data/lib/api-sdk-rb/models/post_brand_kit_icon_request.rb +237 -0
- data/lib/api-sdk-rb/models/public_workflow.rb +351 -0
- data/lib/api-sdk-rb/models/public_workflow_events_accepted.rb +242 -0
- data/lib/api-sdk-rb/models/public_workflow_events_request.rb +301 -0
- data/lib/api-sdk-rb/models/public_workflow_events_request_events_inner.rb +332 -0
- data/lib/api-sdk-rb/models/public_workflow_events_request_heights_inner.rb +267 -0
- data/lib/api-sdk-rb/models/public_workflow_translation.rb +242 -0
- data/lib/api-sdk-rb/models/publish_workspace_workflow200_response.rb +246 -0
- data/lib/api-sdk-rb/models/publish_workspace_workflow_request.rb +240 -0
- data/lib/api-sdk-rb/models/put_brand_kit_request.rb +239 -0
- data/lib/api-sdk-rb/models/remove_partner_workflow_preset200_response.rb +246 -0
- data/lib/api-sdk-rb/models/report_public_workflow_events200_response.rb +246 -0
- data/lib/api-sdk-rb/models/save_workspace_workflow200_response.rb +246 -0
- data/lib/api-sdk-rb/models/save_workspace_workflow_request.rb +296 -0
- data/lib/api-sdk-rb/models/set_adapter_connection_request.rb +1 -1
- data/lib/api-sdk-rb/models/set_partner_workflow_preset200_response.rb +246 -0
- data/lib/api-sdk-rb/models/update_composition.rb +1 -1
- data/lib/api-sdk-rb/models/widget.rb +9 -20
- data/lib/api-sdk-rb/models/workflow.rb +509 -0
- data/lib/api-sdk-rb/models/workflow_composition_action.rb +266 -0
- data/lib/api-sdk-rb/models/workflow_composition_field.rb +303 -0
- data/lib/api-sdk-rb/models/workflow_composition_option.rb +316 -0
- data/lib/api-sdk-rb/models/workflow_composition_option_actions.rb +284 -0
- data/lib/api-sdk-rb/models/workflow_composition_option_inputs.rb +304 -0
- data/lib/api-sdk-rb/models/workflow_composition_options.rb +271 -0
- data/lib/api-sdk-rb/models/workflow_condition_case.rb +322 -0
- data/lib/api-sdk-rb/models/workflow_condition_test.rb +284 -0
- data/lib/api-sdk-rb/models/workflow_counter.rb +238 -0
- data/lib/api-sdk-rb/models/workflow_detail.rb +580 -0
- data/lib/api-sdk-rb/models/workflow_detail_all_of_last_edited_by.rb +242 -0
- data/lib/api-sdk-rb/models/workflow_edge.rb +292 -0
- data/lib/api-sdk-rb/models/workflow_field_reference.rb +300 -0
- data/lib/api-sdk-rb/models/workflow_graph.rb +330 -0
- data/lib/api-sdk-rb/models/workflow_issue.rb +309 -0
- data/lib/api-sdk-rb/models/workflow_list.rb +271 -0
- data/lib/api-sdk-rb/models/workflow_node.rb +343 -0
- data/lib/api-sdk-rb/models/workflow_node_position.rb +238 -0
- data/lib/api-sdk-rb/models/workflow_preset_choice.rb +288 -0
- data/lib/api-sdk-rb/models/workflow_preset_choices.rb +224 -0
- data/lib/api-sdk-rb/models/workflow_preset_removal.rb +222 -0
- data/lib/api-sdk-rb/models/workflow_preset_widget.rb +234 -0
- data/lib/api-sdk-rb/models/workflow_publish_result.rb +256 -0
- data/lib/api-sdk-rb/models/workflow_removed.rb +221 -0
- data/lib/api-sdk-rb/models/workflow_schedule.rb +298 -0
- data/lib/api-sdk-rb/models/workflow_stats.rb +335 -0
- data/lib/api-sdk-rb/models/workflow_status.rb +42 -0
- data/lib/api-sdk-rb/models/workflow_trigger.rb +303 -0
- data/lib/api-sdk-rb/models/workflow_trigger_values_inner.rb +271 -0
- data/lib/api-sdk-rb/models/workflow_version.rb +316 -0
- data/lib/api-sdk-rb/models/workflow_version_detail.rb +354 -0
- data/lib/api-sdk-rb/models/workflow_version_list.rb +224 -0
- data/lib/api-sdk-rb/models/workflow_version_published_by.rb +225 -0
- data/lib/api-sdk-rb/version.rb +1 -1
- data/lib/api-sdk-rb.rb +88 -0
- data/spec/api/brand_kit_api_spec.rb +136 -0
- data/spec/api/compositions_api_spec.rb +86 -69
- data/spec/api/managed_users_api_spec.rb +1 -1
- data/spec/api/partner_api_spec.rb +624 -82
- data/spec/api/partners_api_spec.rb +56 -2
- data/spec/api/public_embed_api_spec.rb +54 -3
- data/spec/api/users_api_spec.rb +16 -1
- data/spec/api/workflows_api_spec.rb +378 -0
- data/spec/api/workspaces_api_spec.rb +339 -0
- data/spec/models/adapter_connection_spec.rb +18 -0
- data/spec/models/brand_color_spec.rb +52 -0
- data/spec/models/brand_font_spec.rb +62 -0
- data/spec/models/brand_kit_asset_view_spec.rb +120 -0
- data/spec/models/brand_kit_figma_source_spec.rb +60 -0
- data/spec/models/brand_kit_tokens_fonts_spec.rb +54 -0
- data/spec/models/brand_kit_tokens_spec.rb +54 -0
- data/spec/models/brand_kit_view_owner_spec.rb +46 -0
- data/spec/models/brand_kit_view_response_spec.rb +48 -0
- data/spec/models/brand_kit_view_spec.rb +90 -0
- data/spec/models/brand_spacing_spec.rb +78 -0
- data/spec/models/composition_last_edited_by_spec.rb +42 -0
- data/spec/models/composition_spec.rb +12 -0
- data/spec/models/confirm_adapter_connection_request_spec.rb +36 -0
- data/spec/models/create_widget201_response_data_spec.rb +1 -7
- data/spec/models/create_workspace_workflow_from_preset201_response_spec.rb +48 -0
- data/spec/models/create_workspace_workflow_from_preset_request_spec.rb +42 -0
- data/spec/models/create_workspace_workflow_request_spec.rb +48 -0
- data/spec/models/delete_workspace_workflow200_response_spec.rb +48 -0
- data/spec/models/editor_session_spec.rb +1 -1
- data/spec/models/get_public_composition_embed200_response_adapters_captcha_spec.rb +36 -0
- data/spec/models/get_public_composition_embed200_response_adapters_spec.rb +42 -0
- data/spec/models/get_public_composition_embed200_response_entries_spec.rb +42 -0
- data/spec/models/get_public_composition_embed200_response_media_spec.rb +36 -0
- data/spec/models/get_public_composition_embed200_response_spec.rb +18 -0
- data/spec/models/get_public_workflow200_response_spec.rb +48 -0
- data/spec/models/get_workspace_workflow_stats200_response_spec.rb +48 -0
- data/spec/models/get_workspace_workflow_version200_response_spec.rb +48 -0
- data/spec/models/list_partner_workflow_presets200_response_spec.rb +48 -0
- data/spec/models/list_workspace_workflow_composition_options200_response_spec.rb +48 -0
- data/spec/models/list_workspace_workflow_presets200_response_spec.rb +48 -0
- data/spec/models/list_workspace_workflow_versions200_response_spec.rb +48 -0
- data/spec/models/list_workspace_workflows200_response_spec.rb +48 -0
- data/spec/models/new_editor_session_spec.rb +1 -1
- data/spec/models/offer_workflow_preset_request_spec.rb +54 -0
- data/spec/models/offered_workflow_preset_list_spec.rb +36 -0
- data/spec/models/offered_workflow_preset_spec.rb +106 -0
- data/spec/models/offered_workflow_preset_widget_spec.rb +48 -0
- data/spec/models/patch_brand_kit_asset_request_spec.rb +62 -0
- data/spec/models/patch_brand_kit_request_fonts_spec.rb +54 -0
- data/spec/models/patch_brand_kit_request_spacing_spec.rb +78 -0
- data/spec/models/patch_brand_kit_request_spec.rb +66 -0
- data/spec/models/post_brand_kit_icon_request_spec.rb +42 -0
- data/spec/models/public_workflow_events_accepted_spec.rb +48 -0
- data/spec/models/public_workflow_events_request_events_inner_spec.rb +52 -0
- data/spec/models/public_workflow_events_request_heights_inner_spec.rb +42 -0
- data/spec/models/public_workflow_events_request_spec.rb +54 -0
- data/spec/models/public_workflow_spec.rb +94 -0
- data/spec/models/public_workflow_translation_spec.rb +42 -0
- data/spec/models/publish_workspace_workflow200_response_spec.rb +48 -0
- data/spec/models/publish_workspace_workflow_request_spec.rb +36 -0
- data/spec/models/put_brand_kit_request_spec.rb +48 -0
- data/spec/models/remove_partner_workflow_preset200_response_spec.rb +48 -0
- data/spec/models/report_public_workflow_events200_response_spec.rb +48 -0
- data/spec/models/save_workspace_workflow200_response_spec.rb +48 -0
- data/spec/models/save_workspace_workflow_request_spec.rb +54 -0
- data/spec/models/set_partner_workflow_preset200_response_spec.rb +48 -0
- data/spec/models/widget_spec.rb +1 -7
- data/spec/models/workflow_composition_action_spec.rb +54 -0
- data/spec/models/workflow_composition_field_spec.rb +58 -0
- data/spec/models/workflow_composition_option_actions_spec.rb +52 -0
- data/spec/models/workflow_composition_option_inputs_spec.rb +58 -0
- data/spec/models/workflow_composition_option_spec.rb +72 -0
- data/spec/models/workflow_composition_options_spec.rb +54 -0
- data/spec/models/workflow_condition_case_spec.rb +58 -0
- data/spec/models/workflow_condition_test_spec.rb +52 -0
- data/spec/models/workflow_counter_spec.rb +42 -0
- data/spec/models/workflow_detail_all_of_last_edited_by_spec.rb +42 -0
- data/spec/models/workflow_detail_spec.rb +162 -0
- data/spec/models/workflow_edge_spec.rb +54 -0
- data/spec/models/workflow_field_reference_spec.rb +56 -0
- data/spec/models/workflow_graph_spec.rb +52 -0
- data/spec/models/workflow_issue_spec.rb +70 -0
- data/spec/models/workflow_list_spec.rb +54 -0
- data/spec/models/workflow_node_position_spec.rb +42 -0
- data/spec/models/workflow_node_spec.rb +76 -0
- data/spec/models/workflow_preset_choice_spec.rb +60 -0
- data/spec/models/workflow_preset_choices_spec.rb +36 -0
- data/spec/models/workflow_preset_removal_spec.rb +36 -0
- data/spec/models/workflow_preset_widget_spec.rb +42 -0
- data/spec/models/workflow_publish_result_spec.rb +48 -0
- data/spec/models/workflow_removed_spec.rb +36 -0
- data/spec/models/workflow_schedule_spec.rb +62 -0
- data/spec/models/workflow_spec.rb +132 -0
- data/spec/models/workflow_stats_spec.rb +78 -0
- data/spec/models/workflow_status_spec.rb +30 -0
- data/spec/models/workflow_trigger_spec.rb +70 -0
- data/spec/models/workflow_trigger_values_inner_spec.rb +46 -0
- data/spec/models/workflow_version_detail_spec.rb +78 -0
- data/spec/models/workflow_version_list_spec.rb +36 -0
- data/spec/models/workflow_version_published_by_spec.rb +42 -0
- data/spec/models/workflow_version_spec.rb +66 -0
- metadata +364 -12
|
@@ -309,7 +309,7 @@ module ApiSdkRb
|
|
|
309
309
|
end
|
|
310
310
|
|
|
311
311
|
# Create an editor session for a managed user
|
|
312
|
-
# Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor pieces, such as the File Browser and the composition editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the `token` in the answer to that page. The token is shown once. It starts with `wgt_ses_` and the browser sends it as `Authorization: Bearer <token>`. It can do only what the `surfaces` you name allow, and only for this managed user: - `files`: upload a file (`uploadsPost`) and list the files uploaded for this user (`uploadsGet`). Every file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (`setPartnerStorageDestination`); until then it is refused with 409 and `PARTNER_STORAGE_REQUIRED`, and when the destination cannot be used with 503 and `STORAGE_DESTINATION_UNAVAILABLE`. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave `files` out of the session and hand the editors your own media library instead (`mediaLibrary`). - `editor`: edit one of this user's compositions: read it (`getCompositionById`, its content, design, embed settings and schemas), check a content change (`validateCompositionContent`), and change its name, content, design and embed settings (`updateComposition`, `setDynamicContent`). It can reach only compositions you created for this managed user (tag them with `managedUserId` when you create them); any other composition, including another of your users', answers 404. - `creator`: use Widgetic's widget creator for this user, including its AI. Draw on canvases and save them (`getAllCanvases`, `getCanvas`, `createCanvas`, `updateCanvas`, `previewDeleteCanvas`, `deleteCanvas`); make, change, copy and delete the widgets on them (`createWidget`, `getWidgets`, `getWidgetsBatch`, `updateWidget`, `uploadWidgetThumbnail`, `duplicateWidget`, `deleteWidget`); list and make the compositions of a widget it built (`getAllCompositions`, `createComposition`), which is how it shows the widget with sample values; keep the conversation of each widget (`getConversationsByWidgetId`, `createConversationForWidget`, `updateConversation`, `getMessages`, `createMessage`, `updateMessage`, `restoreCheckpoint`); and read a widget's schemas and give it its repository (`getWidgetContentSchema`, `getWidgetDesignSchema`, `updateWidgetRepository`). The AI that builds a widget is part of it: list the models (`agentModelsGet`), open the widget's repository (`agentRepositoriesPost`, `agentRepositoriesRepoIdGet`), start a generation and follow or cancel it (`agentCodeGeneratePost`, `operationsStreamGet`, `operationsIdGet`, `operationsIdCancelPost`), build and preview the result (`agentWidgetBuilderRepoHeadWidgetIdGet`, `buildWidgetFromRepo`, `previewWidgetVersion`), publish a version of the widget and move between its versions (`agentWidgetBuilderPublishWidgetIdPost`, `getWidgetPublishHistory`, `setWidgetPublishHistoryLive`, `renameWidgetPublishHistoryTitle`), and turn a stroke or a sentence into a decision (`agentShapeRecognizePost`, `agentDesignResolvePost`). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (`listMyPresets`, `copyMyPreset`; you choose the presets with `setPartnerPreset`). What the session makes is filed for this managed user, and the lists it reads hold only this user's canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with `managedUserId`); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users', answers 404. The creator also saves the composition it is editing (`updateComposition`, from the `editor` surface) and attaches pictures to its chat (`uploadsPost`, from the `files` surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for `creator`, `editor` and `files` together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`. Everything else is refused with 403 and `EDITOR_SESSION_ROUTE_NOT_ALLOWED`: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the `creator` surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at `expiresAt` (at most four hours), when you end it (`revokeManagedUserEditorSession`), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (`429 EDITOR_SESSION_LIMIT_REACHED`). A session that is bound to a web page (`allowedOrigin`) is refused from any other origin. The AI the session runs is paid for with your credits. Set `maxCredits` to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and `EDITOR_SESSION_CREDIT_LIMIT_REACHED`, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and `maxCredits: null` asks for none), and otherwise the credits of your account are the only ceiling. What each of your users' sessions has spent is in `getManagedUserUsage`. Each call makes a new session. It does not take an `Idempotency-Key`: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with `Cache-Control: no-store`.
|
|
312
|
+
# Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor pieces, such as the File Browser and the composition editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the `token` in the answer to that page. The token is shown once. It starts with `wgt_ses_` and the browser sends it as `Authorization: Bearer <token>`. It can do only what the `surfaces` you name allow, and only for this managed user: - `files`: upload a file (`uploadsPost`) and list the files uploaded for this user (`uploadsGet`). Every file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (`setPartnerStorageDestination`); until then it is refused with 409 and `PARTNER_STORAGE_REQUIRED`, and when the destination cannot be used with 503 and `STORAGE_DESTINATION_UNAVAILABLE`. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave `files` out of the session and hand the editors your own media library instead (`mediaLibrary`). - `editor`: edit one of this user's compositions: read it (`getCompositionById`, its content, design, embed settings and schemas), check a content change (`validateCompositionContent`), and change its name, content, design and embed settings (`updateComposition`, `setDynamicContent`). For a widget that answers visitors' questions from documents (the `ai-answers` adapter), it also lists those documents, adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one (`getAiAnswersKnowledge`, `addAiAnswersKnowledgeDocument`, `addAiAnswersKnowledgeFile`, `removeAiAnswersKnowledgeDocument`); adding costs no credits, and is limited for each of your users separately. It can reach only compositions you created for this managed user (tag them with `managedUserId` when you create them); any other composition, including another of your users', answers 404. - `creator`: use Widgetic's widget creator for this user, including its AI. Draw on canvases and save them (`getAllCanvases`, `getCanvas`, `createCanvas`, `updateCanvas`, `previewDeleteCanvas`, `deleteCanvas`); make, change, copy and delete the widgets on them (`createWidget`, `getWidgets`, `getWidgetsBatch`, `updateWidget`, `uploadWidgetThumbnail`, `duplicateWidget`, `deleteWidget`); list and make the compositions of a widget it built (`getAllCompositions`, `createComposition`), which is how it shows the widget with sample values; keep the conversation of each widget (`getConversationsByWidgetId`, `createConversationForWidget`, `updateConversation`, `getMessages`, `createMessage`, `updateMessage`, `restoreCheckpoint`); and read a widget's schemas and give it its repository (`getWidgetContentSchema`, `getWidgetDesignSchema`, `updateWidgetRepository`). The AI that builds a widget is part of it: list the models (`agentModelsGet`), open the widget's repository (`agentRepositoriesPost`, `agentRepositoriesRepoIdGet`), start a generation and follow or cancel it (`agentCodeGeneratePost`, `operationsStreamGet`, `operationsIdGet`, `operationsIdCancelPost`), build and preview the result (`agentWidgetBuilderRepoHeadWidgetIdGet`, `buildWidgetFromRepo`, `previewWidgetVersion`), publish a version of the widget and move between its versions (`agentWidgetBuilderPublishWidgetIdPost`, `getWidgetPublishHistory`, `setWidgetPublishHistoryLive`, `renameWidgetPublishHistoryTitle`), and turn a stroke or a sentence into a decision (`agentShapeRecognizePost`, `agentDesignResolvePost`). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (`listMyPresets`, `copyMyPreset`; you choose the presets with `setPartnerPreset`). What the session makes is filed for this managed user, and the lists it reads hold only this user's canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with `managedUserId`); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users', answers 404. The creator also saves the composition it is editing (`updateComposition`, from the `editor` surface) and attaches pictures to its chat (`uploadsPost`, from the `files` surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for `creator`, `editor` and `files` together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`. - `workflows`: use Widgetic's Workflows editor for this user. List their workflows and the compositions a workflow of theirs can chain (`listWorkspaceWorkflows`, `listWorkspaceWorkflowCompositionOptions`); list the starting points you offer them and make a workflow from one, which gives the user their own copy of every widget it chains, a composition of their own on each copy, and a draft (`listWorkspaceWorkflowPresets`, `createWorkspaceWorkflowFromPreset`; you offer them with `setPartnerWorkflowPreset`); make, open, change and delete one (`createWorkspaceWorkflow`, `getWorkspaceWorkflow`, `saveWorkspaceWorkflow`, `deleteWorkspaceWorkflow`) and copy it (`duplicateWorkspaceWorkflow`); publish it or discard the changes of its draft (`publishWorkspaceWorkflow`, `discardWorkspaceWorkflowChanges`); read and restore its versions (`listWorkspaceWorkflowVersions`, `getWorkspaceWorkflowVersion`, `restoreWorkspaceWorkflowVersion`); pause, resume, archive and unarchive it (`pauseWorkspaceWorkflow`, `resumeWorkspaceWorkflow`, `archiveWorkspaceWorkflow`, `unarchiveWorkspaceWorkflow`); and read its counts (`getWorkspaceWorkflowStats`). The workspace in each path is `personal`: a session has no other, and a path that names an organization is refused. What the session makes is filed for this managed user (`managedUserId`), the lists hold only this user's workflows, and it can reach only workflows made for this managed user; any other workflow, including one of yours or of another of your users, answers 404. A workflow can chain only the compositions you made for this managed user (tag them with `managedUserId`): one that belongs to anybody else is not available, and publishing a workflow that uses it is refused. A customer can have at most 50 workflows, and what a customer's session reads never says who published a version. A session cannot set who a workflow belongs to or which workspace it is in: a body with another field is refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`. Everything else is refused with 403 and `EDITOR_SESSION_ROUTE_NOT_ALLOWED`: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the `creator` surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at `expiresAt` (at most four hours), when you end it (`revokeManagedUserEditorSession`), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (`429 EDITOR_SESSION_LIMIT_REACHED`). A session that is bound to a web page (`allowedOrigin`) is refused from any other origin. The AI the session runs is paid for with your credits. Set `maxCredits` to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and `EDITOR_SESSION_CREDIT_LIMIT_REACHED`, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and `maxCredits: null` asks for none), and otherwise the credits of your account are the only ceiling. What each of your users' sessions has spent is in `getManagedUserUsage`. Each call makes a new session. It does not take an `Idempotency-Key`: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with `Cache-Control: no-store`.
|
|
313
313
|
# @param id [String] The managed user the session is for (Widgetic's id for the user)
|
|
314
314
|
# @param new_editor_session [NewEditorSession]
|
|
315
315
|
# @param [Hash] opts the optional parameters
|
|
@@ -320,7 +320,7 @@ module ApiSdkRb
|
|
|
320
320
|
end
|
|
321
321
|
|
|
322
322
|
# Create an editor session for a managed user
|
|
323
|
-
# Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor pieces, such as the File Browser and the composition editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the `token` in the answer to that page. The token is shown once. It starts with `wgt_ses_` and the browser sends it as `Authorization: Bearer <token>`. It can do only what the `surfaces` you name allow, and only for this managed user: - `files`: upload a file (`uploadsPost`) and list the files uploaded for this user (`uploadsGet`). Every file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (`setPartnerStorageDestination`); until then it is refused with 409 and `PARTNER_STORAGE_REQUIRED`, and when the destination cannot be used with 503 and `STORAGE_DESTINATION_UNAVAILABLE`. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave `files` out of the session and hand the editors your own media library instead (`mediaLibrary`). - `editor`: edit one of this user's compositions: read it (`getCompositionById`, its content, design, embed settings and schemas), check a content change (`validateCompositionContent`), and change its name, content, design and embed settings (`updateComposition`, `setDynamicContent`). It can reach only compositions you created for this managed user (tag them with `managedUserId` when you create them); any other composition, including another of your users', answers 404. - `creator`: use Widgetic's widget creator for this user, including its AI. Draw on canvases and save them (`getAllCanvases`, `getCanvas`, `createCanvas`, `updateCanvas`, `previewDeleteCanvas`, `deleteCanvas`); make, change, copy and delete the widgets on them (`createWidget`, `getWidgets`, `getWidgetsBatch`, `updateWidget`, `uploadWidgetThumbnail`, `duplicateWidget`, `deleteWidget`); list and make the compositions of a widget it built (`getAllCompositions`, `createComposition`), which is how it shows the widget with sample values; keep the conversation of each widget (`getConversationsByWidgetId`, `createConversationForWidget`, `updateConversation`, `getMessages`, `createMessage`, `updateMessage`, `restoreCheckpoint`); and read a widget's schemas and give it its repository (`getWidgetContentSchema`, `getWidgetDesignSchema`, `updateWidgetRepository`). The AI that builds a widget is part of it: list the models (`agentModelsGet`), open the widget's repository (`agentRepositoriesPost`, `agentRepositoriesRepoIdGet`), start a generation and follow or cancel it (`agentCodeGeneratePost`, `operationsStreamGet`, `operationsIdGet`, `operationsIdCancelPost`), build and preview the result (`agentWidgetBuilderRepoHeadWidgetIdGet`, `buildWidgetFromRepo`, `previewWidgetVersion`), publish a version of the widget and move between its versions (`agentWidgetBuilderPublishWidgetIdPost`, `getWidgetPublishHistory`, `setWidgetPublishHistoryLive`, `renameWidgetPublishHistoryTitle`), and turn a stroke or a sentence into a decision (`agentShapeRecognizePost`, `agentDesignResolvePost`). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (`listMyPresets`, `copyMyPreset`; you choose the presets with `setPartnerPreset`). What the session makes is filed for this managed user, and the lists it reads hold only this user's canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with `managedUserId`); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users', answers 404. The creator also saves the composition it is editing (`updateComposition`, from the `editor` surface) and attaches pictures to its chat (`uploadsPost`, from the `files` surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for `creator`, `editor` and `files` together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`. Everything else is refused with 403 and `EDITOR_SESSION_ROUTE_NOT_ALLOWED`: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the `creator` surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at `expiresAt` (at most four hours), when you end it (`revokeManagedUserEditorSession`), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (`429 EDITOR_SESSION_LIMIT_REACHED`). A session that is bound to a web page (`allowedOrigin`) is refused from any other origin. The AI the session runs is paid for with your credits. Set `maxCredits` to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and `EDITOR_SESSION_CREDIT_LIMIT_REACHED`, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and `maxCredits: null` asks for none), and otherwise the credits of your account are the only ceiling. What each of your users' sessions has spent is in `getManagedUserUsage`. Each call makes a new session. It does not take an `Idempotency-Key`: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with `Cache-Control: no-store`.
|
|
323
|
+
# Makes a short-lived credential that lets the browser of ONE of your managed users use Widgetic's editor pieces, such as the File Browser and the composition editor, without your API key ever reaching that browser. Call this from your server when the page that hosts the editor opens, and hand the `token` in the answer to that page. The token is shown once. It starts with `wgt_ses_` and the browser sends it as `Authorization: Bearer <token>`. It can do only what the `surfaces` you name allow, and only for this managed user: - `files`: upload a file (`uploadsPost`) and list the files uploaded for this user (`uploadsGet`). Every file is filed for this user and stored in your own storage destination, never in Widgetic's: a file a customer uploads is yours to keep, and takes none of your storage allowance. Partner storage is not optional, so no session, whatever its surfaces, can be made until you have set a destination (`setPartnerStorageDestination`); until then it is refused with 409 and `PARTNER_STORAGE_REQUIRED`, and when the destination cannot be used with 503 and `STORAGE_DESTINATION_UNAVAILABLE`. A destination you remove after the session was made stops its uploads too (the same 409; the browser is only told that the feature is not available right now). To keep a customer from uploading, leave `files` out of the session and hand the editors your own media library instead (`mediaLibrary`). - `editor`: edit one of this user's compositions: read it (`getCompositionById`, its content, design, embed settings and schemas), check a content change (`validateCompositionContent`), and change its name, content, design and embed settings (`updateComposition`, `setDynamicContent`). For a widget that answers visitors' questions from documents (the `ai-answers` adapter), it also lists those documents, adds one as text or as a file (a text file or a picture; a PDF once PDFs are read), and removes one (`getAiAnswersKnowledge`, `addAiAnswersKnowledgeDocument`, `addAiAnswersKnowledgeFile`, `removeAiAnswersKnowledgeDocument`); adding costs no credits, and is limited for each of your users separately. It can reach only compositions you created for this managed user (tag them with `managedUserId` when you create them); any other composition, including another of your users', answers 404. - `creator`: use Widgetic's widget creator for this user, including its AI. Draw on canvases and save them (`getAllCanvases`, `getCanvas`, `createCanvas`, `updateCanvas`, `previewDeleteCanvas`, `deleteCanvas`); make, change, copy and delete the widgets on them (`createWidget`, `getWidgets`, `getWidgetsBatch`, `updateWidget`, `uploadWidgetThumbnail`, `duplicateWidget`, `deleteWidget`); list and make the compositions of a widget it built (`getAllCompositions`, `createComposition`), which is how it shows the widget with sample values; keep the conversation of each widget (`getConversationsByWidgetId`, `createConversationForWidget`, `updateConversation`, `getMessages`, `createMessage`, `updateMessage`, `restoreCheckpoint`); and read a widget's schemas and give it its repository (`getWidgetContentSchema`, `getWidgetDesignSchema`, `updateWidgetRepository`). The AI that builds a widget is part of it: list the models (`agentModelsGet`), open the widget's repository (`agentRepositoriesPost`, `agentRepositoriesRepoIdGet`), start a generation and follow or cancel it (`agentCodeGeneratePost`, `operationsStreamGet`, `operationsIdGet`, `operationsIdCancelPost`), build and preview the result (`agentWidgetBuilderRepoHeadWidgetIdGet`, `buildWidgetFromRepo`, `previewWidgetVersion`), publish a version of the widget and move between its versions (`agentWidgetBuilderPublishWidgetIdPost`, `getWidgetPublishHistory`, `setWidgetPublishHistoryLive`, `renameWidgetPublishHistoryTitle`), and turn a stroke or a sentence into a decision (`agentShapeRecognizePost`, `agentDesignResolvePost`). It can also offer the customer your presets as starting points: read them and ask for a copy for this customer (`listMyPresets`, `copyMyPreset`; you choose the presets with `setPartnerPreset`). What the session makes is filed for this managed user, and the lists it reads hold only this user's canvases, widgets and compositions. It can reach only canvases, widgets, compositions, repositories, uploaded files and operations made for this managed user (tag the canvases and widgets you create with `managedUserId`); any other canvas, widget, composition, conversation, message, repository, file or operation, including another of your users', answers 404. The creator also saves the composition it is editing (`updateComposition`, from the `editor` surface) and attaches pictures to its chat (`uploadsPost`, from the `files` surface), and the surfaces do not imply one another: to open the whole creator for a user, ask for `creator`, `editor` and `files` together. A generation or a build one user starts can be followed and cancelled by that user and by you, never by another of your users. The AI is paid for by your account, as your own calls are: its credits and allowances are yours. A session cannot make a widget public (publishing a version does not), file one under a project or an organization, or set anything the creator does not set: a body with another field is refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`. - `workflows`: use Widgetic's Workflows editor for this user. List their workflows and the compositions a workflow of theirs can chain (`listWorkspaceWorkflows`, `listWorkspaceWorkflowCompositionOptions`); list the starting points you offer them and make a workflow from one, which gives the user their own copy of every widget it chains, a composition of their own on each copy, and a draft (`listWorkspaceWorkflowPresets`, `createWorkspaceWorkflowFromPreset`; you offer them with `setPartnerWorkflowPreset`); make, open, change and delete one (`createWorkspaceWorkflow`, `getWorkspaceWorkflow`, `saveWorkspaceWorkflow`, `deleteWorkspaceWorkflow`) and copy it (`duplicateWorkspaceWorkflow`); publish it or discard the changes of its draft (`publishWorkspaceWorkflow`, `discardWorkspaceWorkflowChanges`); read and restore its versions (`listWorkspaceWorkflowVersions`, `getWorkspaceWorkflowVersion`, `restoreWorkspaceWorkflowVersion`); pause, resume, archive and unarchive it (`pauseWorkspaceWorkflow`, `resumeWorkspaceWorkflow`, `archiveWorkspaceWorkflow`, `unarchiveWorkspaceWorkflow`); and read its counts (`getWorkspaceWorkflowStats`). The workspace in each path is `personal`: a session has no other, and a path that names an organization is refused. What the session makes is filed for this managed user (`managedUserId`), the lists hold only this user's workflows, and it can reach only workflows made for this managed user; any other workflow, including one of yours or of another of your users, answers 404. A workflow can chain only the compositions you made for this managed user (tag them with `managedUserId`): one that belongs to anybody else is not available, and publishing a workflow that uses it is refused. A customer can have at most 50 workflows, and what a customer's session reads never says who published a version. A session cannot set who a workflow belongs to or which workspace it is in: a body with another field is refused with 403 and `EDITOR_SESSION_FIELD_NOT_ALLOWED`. Everything else is refused with 403 and `EDITOR_SESSION_ROUTE_NOT_ALLOWED`: a session cannot read your account, make more sessions, change your presets or delete a composition, and a session without the `creator` surface cannot create or list compositions. Create the composition yourself with your API key, then open the editor on it. A session ends at `expiresAt` (at most four hours), when you end it (`revokeManagedUserEditorSession`), or when the managed user is switched off or deleted. A managed user can have at most 100 live sessions at once (`429 EDITOR_SESSION_LIMIT_REACHED`). A session that is bound to a web page (`allowedOrigin`) is refused from any other origin. The AI the session runs is paid for with your credits. Set `maxCredits` to hold the session to a number of them: once its generations have taken that many (a generation that fails is refunded and does not count), the next one is refused with 402 and `EDITOR_SESSION_CREDIT_LIMIT_REACHED`, and the browser is told only that the feature is not available right now. Without it, the limit Widgetic has set for your account applies when it has set one (the same limit for every session you make, and `maxCredits: null` asks for none), and otherwise the credits of your account are the only ceiling. What each of your users' sessions has spent is in `getManagedUserUsage`. Each call makes a new session. It does not take an `Idempotency-Key`: the answer holds the token, and the token is never stored where a retry could read it back. The answer is sent with `Cache-Control: no-store`.
|
|
324
324
|
# @param id [String] The managed user the session is for (Widgetic's id for the user)
|
|
325
325
|
# @param new_editor_session [NewEditorSession]
|
|
326
326
|
# @param [Hash] opts the optional parameters
|