@widgetic/api-sdk-ts 1.11.109 → 1.11.151
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.
- package/README.md +1 -1
- package/dist/apis/BrandKitApi.d.ts +130 -0
- package/dist/apis/BrandKitApi.js +381 -0
- package/dist/apis/CanvasesApi.d.ts +15 -15
- package/dist/apis/CompositionsApi.d.ts +257 -155
- package/dist/apis/CompositionsApi.js +338 -134
- package/dist/apis/CreditsApi.d.ts +11 -11
- package/dist/apis/CreditsApi.js +5 -5
- package/dist/apis/EntitlementsApi.d.ts +6 -6
- package/dist/apis/InvoicesApi.d.ts +6 -6
- package/dist/apis/InvoicesApi.js +2 -2
- package/dist/apis/ManagedUsersApi.d.ts +97 -63
- package/dist/apis/ManagedUsersApi.js +106 -39
- package/dist/apis/OperationsApi.d.ts +4 -4
- package/dist/apis/OperationsApi.js +5 -5
- package/dist/apis/OrganizationsApi.d.ts +74 -0
- package/dist/apis/OrganizationsApi.js +205 -0
- package/dist/apis/PartnersApi.d.ts +133 -133
- package/dist/apis/PartnersApi.js +19 -19
- package/dist/apis/PublicEmbedApi.d.ts +57 -42
- package/dist/apis/PublicEmbedApi.js +64 -29
- package/dist/apis/TokensApi.d.ts +2 -0
- package/dist/apis/TokensApi.js +2 -0
- package/dist/apis/UploadsApi.d.ts +40 -40
- package/dist/apis/UploadsApi.js +60 -60
- package/dist/apis/UsersApi.d.ts +30 -86
- package/dist/apis/UsersApi.js +6 -154
- package/dist/apis/WidgetsApi.d.ts +25 -25
- package/dist/apis/WidgetsApi.js +38 -38
- package/dist/apis/WorkflowsApi.d.ts +115 -157
- package/dist/apis/WorkflowsApi.js +111 -221
- package/dist/apis/index.d.ts +2 -2
- package/dist/apis/index.js +2 -2
- package/dist/esm/apis/BrandKitApi.js +344 -0
- package/dist/esm/apis/CompositionsApi.js +338 -134
- package/dist/esm/apis/CreditsApi.js +6 -6
- package/dist/esm/apis/InvoicesApi.js +1 -1
- package/dist/esm/apis/ManagedUsersApi.js +106 -39
- package/dist/esm/apis/OperationsApi.js +6 -6
- package/dist/esm/apis/OrganizationsApi.js +168 -0
- package/dist/esm/apis/PartnersApi.js +20 -20
- package/dist/esm/apis/PublicEmbedApi.js +65 -30
- package/dist/esm/apis/TokensApi.js +2 -0
- package/dist/esm/apis/UploadsApi.js +60 -60
- package/dist/esm/apis/UsersApi.js +7 -155
- package/dist/esm/apis/WidgetsApi.js +39 -39
- package/dist/esm/apis/WorkflowsApi.js +111 -221
- package/dist/esm/apis/index.js +2 -2
- package/dist/esm/models/{GetPartnerCreditTransactions200Response.js → AccountCreditTransactionListResponse.js} +8 -8
- package/dist/esm/models/{GetUserAdapterConnections200Response.js → AdapterConnectionListResponse.js} +8 -8
- package/dist/esm/models/{RemoveUserAdapterConnection200Response.js → AdapterConnectionRemovalResponse.js} +8 -8
- package/dist/esm/models/{SetUserAdapterConnection200Response.js → AdapterConnectionResponse.js} +8 -8
- package/dist/esm/models/AddOrganizationDomainResponse.js +51 -0
- package/dist/esm/models/AddOrganizationDomainResponseData.js +44 -0
- package/dist/esm/models/{AddAiAnswersKnowledgeDocument201Response.js → AiAnswersKnowledgeDocumentResponse.js} +8 -8
- package/dist/esm/models/BrandColor.js +64 -0
- package/dist/esm/models/BrandFont.js +72 -0
- package/dist/esm/models/BrandKitAssetView.js +96 -0
- package/dist/esm/models/BrandKitFigmaSource.js +59 -0
- package/dist/esm/models/BrandKitTokens.js +59 -0
- package/dist/esm/models/BrandKitTokensFonts.js +48 -0
- package/dist/esm/models/BrandKitView.js +75 -0
- package/dist/esm/models/BrandKitViewOwner.js +54 -0
- package/dist/esm/models/BrandKitViewResponse.js +51 -0
- package/dist/esm/models/BrandSpacing.js +71 -0
- package/dist/esm/models/BrandTextStyle.js +65 -0
- package/dist/esm/models/Canvas.js +3 -0
- package/dist/esm/models/CanvasActiveOperation.js +66 -0
- package/dist/esm/models/{CreateCompositionDatabaseRecord201Response.js → CompositionDatabaseRecordResponse.js} +8 -8
- package/dist/esm/models/{CreateCompositionContentItem201Response.js → ContentItemWriteResultResponse.js} +8 -8
- package/dist/esm/models/CreateWidget201ResponseData.js +6 -0
- package/dist/esm/models/{CreateCompositionFromWidget201Response.js → DeleteOrganizationDomainResponse.js} +11 -11
- package/dist/esm/models/DeleteOrganizationDomainResponseData.js +41 -0
- package/dist/esm/models/{OperationsIdGetResponse.js → DeleteUpload200Response.js} +11 -11
- package/dist/esm/models/{UploadsIdDelete200ResponseData.js → DeleteUpload200ResponseData.js} +8 -8
- package/dist/esm/models/{GetPartnerDesignDefaults200Response.js → DesignDefaultsResponse.js} +8 -8
- package/dist/esm/models/EditorSession.js +4 -0
- package/dist/esm/models/GetOperationResponse.js +51 -0
- package/dist/esm/models/{OperationsIdGetResponseData.js → GetOperationResponseData.js} +12 -11
- package/dist/esm/models/GetOperationResponseDataMetadata.js +69 -0
- package/dist/esm/models/GetOrganizationDomains200Response.js +51 -0
- package/dist/esm/models/{UploadsGet200Response.js → ListUploads200Response.js} +8 -8
- package/dist/esm/models/{GetManagedUserLimits200Response.js → ManagedUserLimitsResponse.js} +8 -8
- package/dist/esm/models/{DeleteManagedUser200Response.js → ManagedUserRemovalResponse.js} +8 -8
- package/dist/esm/models/NewWidget.js +0 -1
- package/dist/esm/models/{PersonalWorkspaceDomain.js → OrganizationDomain.js} +12 -18
- package/dist/esm/models/PatchBrandKitAssetRequest.js +68 -0
- package/dist/esm/models/PatchBrandKitRequest.js +57 -0
- package/dist/esm/models/PatchBrandKitRequestFonts.js +48 -0
- package/dist/esm/models/PatchBrandKitRequestSpacing.js +55 -0
- package/dist/esm/models/PostBrandKitIconRequest.js +47 -0
- package/dist/esm/models/PublicWorkflowEventsRequestEventsInner.js +11 -0
- package/dist/esm/models/{GetPublicWorkflow200Response.js → PublicWorkflowResponse.js} +8 -8
- package/dist/esm/models/PutBrandKitRequest.js +49 -0
- package/dist/esm/models/UpdateOrganizationDomainResponse.js +51 -0
- package/dist/esm/models/Upload.js +2 -0
- package/dist/esm/models/UserApiKey.js +2 -0
- package/dist/esm/models/ValidateToken200ResponseData.js +3 -0
- package/dist/esm/models/ValidateToken200ResponseDataWorkspace.js +43 -0
- package/dist/esm/models/Widget.js +6 -0
- package/dist/esm/models/WidgetClarification.js +52 -0
- package/dist/esm/models/WidgetClarificationOption.js +51 -0
- package/dist/esm/models/WidgetClarificationQuestion.js +64 -0
- package/dist/esm/models/WidgetCodeChange.js +68 -0
- package/dist/esm/models/WidgetCodeChanges.js +48 -0
- package/dist/esm/models/WidgetNextStep.js +71 -0
- package/dist/esm/models/WidgetPlan.js +61 -0
- package/dist/esm/models/WidgetPlanDecisions.js +72 -0
- package/dist/esm/models/WidgetPlanDecisionsAdaptersInner.js +47 -0
- package/dist/esm/models/WidgetPlanDecisionsLibrariesInner.js +51 -0
- package/dist/esm/models/WidgetPlanDecisionsResponsive.js +51 -0
- package/dist/esm/models/WidgetPlanTask.js +80 -0
- package/dist/esm/models/{CreateWorkspaceWorkflowFromPreset201Response.js → WorkflowDetailResponse.js} +8 -8
- package/dist/esm/models/WorkflowFailureReason.js +49 -0
- package/dist/esm/models/WorkflowFailureReasonCounter.js +52 -0
- package/dist/esm/models/{SaveWorkspaceWorkflow200Response.js → WorkflowResponse.js} +8 -8
- package/dist/esm/models/WorkflowStats.js +3 -0
- package/dist/esm/models/index.js +59 -25
- package/dist/esm/runtime.js +1 -1
- package/dist/models/AccountCreditBalance.d.ts +2 -2
- package/dist/models/AccountCreditTransactionListResponse.d.ts +46 -0
- package/dist/models/{GetPartnerCreditTransactions200Response.js → AccountCreditTransactionListResponse.js} +13 -13
- package/dist/models/AdapterConnectionListResponse.d.ts +46 -0
- package/dist/models/{GetUserAdapterConnections200Response.js → AdapterConnectionListResponse.js} +13 -13
- package/dist/models/AdapterConnectionRemovalResponse.d.ts +46 -0
- package/dist/models/{RemoveUserAdapterConnection200Response.js → AdapterConnectionRemovalResponse.js} +13 -13
- package/dist/models/AdapterConnectionResponse.d.ts +46 -0
- package/dist/models/{SetUserAdapterConnection200Response.js → AdapterConnectionResponse.js} +13 -13
- package/dist/models/AddOrganizationDomainResponse.d.ts +46 -0
- package/dist/models/AddOrganizationDomainResponse.js +58 -0
- package/dist/models/AddOrganizationDomainResponseData.d.ts +39 -0
- package/dist/models/AddOrganizationDomainResponseData.js +51 -0
- package/dist/models/AiAnswersKnowledgeDocumentResponse.d.ts +46 -0
- package/dist/models/{AddAiAnswersKnowledgeDocument201Response.js → AiAnswersKnowledgeDocumentResponse.js} +13 -13
- package/dist/models/BrandColor.d.ts +60 -0
- package/dist/models/BrandColor.js +72 -0
- package/dist/models/BrandFont.d.ts +73 -0
- package/dist/models/BrandFont.js +80 -0
- package/dist/models/BrandKitAssetView.d.ts +130 -0
- package/dist/models/BrandKitAssetView.js +104 -0
- package/dist/models/BrandKitFigmaSource.d.ts +56 -0
- package/dist/models/BrandKitFigmaSource.js +66 -0
- package/dist/models/BrandKitTokens.d.ts +60 -0
- package/dist/models/BrandKitTokens.js +66 -0
- package/dist/models/BrandKitTokensFonts.d.ts +51 -0
- package/dist/models/BrandKitTokensFonts.js +55 -0
- package/dist/models/BrandKitView.d.ts +90 -0
- package/dist/models/BrandKitView.js +82 -0
- package/dist/models/BrandKitViewOwner.d.ts +46 -0
- package/dist/models/BrandKitViewOwner.js +62 -0
- package/dist/models/BrandKitViewResponse.d.ts +46 -0
- package/dist/models/BrandKitViewResponse.js +58 -0
- package/dist/models/BrandSpacing.d.ts +74 -0
- package/dist/models/BrandSpacing.js +78 -0
- package/dist/models/BrandTextStyle.d.ts +59 -0
- package/dist/models/BrandTextStyle.js +73 -0
- package/dist/models/Canvas.d.ts +7 -0
- package/dist/models/Canvas.js +3 -0
- package/dist/models/CanvasActiveOperation.d.ts +65 -0
- package/dist/models/CanvasActiveOperation.js +74 -0
- package/dist/models/CompositionDatabaseRecordResponse.d.ts +48 -0
- package/dist/models/CompositionDatabaseRecordResponse.js +57 -0
- package/dist/models/ContentItemWriteResultResponse.d.ts +46 -0
- package/dist/models/{CreateCompositionContentItem201Response.js → ContentItemWriteResultResponse.js} +13 -13
- package/dist/models/CreateWidget201ResponseData.d.ts +18 -0
- package/dist/models/CreateWidget201ResponseData.js +6 -0
- package/dist/models/DeleteOrganizationDomainResponse.d.ts +46 -0
- package/dist/models/DeleteOrganizationDomainResponse.js +58 -0
- package/dist/models/DeleteOrganizationDomainResponseData.d.ts +32 -0
- package/dist/models/DeleteOrganizationDomainResponseData.js +48 -0
- package/dist/models/DeleteUpload200Response.d.ts +46 -0
- package/dist/models/{OperationsIdGetResponse.js → DeleteUpload200Response.js} +16 -16
- package/dist/models/DeleteUpload200ResponseData.d.ts +32 -0
- package/dist/models/DeleteUpload200ResponseData.js +48 -0
- package/dist/models/DesignDefaultsResponse.d.ts +46 -0
- package/dist/models/{GetPartnerDesignDefaults200Response.js → DesignDefaultsResponse.js} +13 -13
- package/dist/models/EditorSession.d.ts +7 -0
- package/dist/models/EditorSession.js +4 -0
- package/dist/models/GetOperationResponse.d.ts +46 -0
- package/dist/models/GetOperationResponse.js +58 -0
- package/dist/models/GetOperationResponseData.d.ts +86 -0
- package/dist/models/{OperationsIdGetResponseData.js → GetOperationResponseData.js} +18 -17
- package/dist/models/GetOperationResponseDataMetadata.d.ts +87 -0
- package/dist/models/GetOperationResponseDataMetadata.js +77 -0
- package/dist/models/GetOrganizationDomains200Response.d.ts +46 -0
- package/dist/models/GetOrganizationDomains200Response.js +58 -0
- package/dist/models/ListUploads200Response.d.ts +46 -0
- package/dist/models/{UploadsGet200Response.js → ListUploads200Response.js} +13 -13
- package/dist/models/ManagedUserLimitsResponse.d.ts +46 -0
- package/dist/models/{GetManagedUserLimits200Response.js → ManagedUserLimitsResponse.js} +13 -13
- package/dist/models/ManagedUserRemovalResponse.d.ts +46 -0
- package/dist/models/{DeleteManagedUser200Response.js → ManagedUserRemovalResponse.js} +13 -13
- package/dist/models/NewEditorSession.d.ts +1 -1
- package/dist/models/NewWidget.d.ts +2 -3
- package/dist/models/NewWidget.js +0 -1
- package/dist/models/OrganizationDomain.d.ts +56 -0
- package/dist/models/OrganizationDomain.js +56 -0
- package/dist/models/PartnerBillingOverviewOperationalCredits.d.ts +1 -1
- package/dist/models/PatchBrandKitAssetRequest.d.ts +73 -0
- package/dist/models/PatchBrandKitAssetRequest.js +76 -0
- package/dist/models/PatchBrandKitRequest.d.ts +72 -0
- package/dist/models/PatchBrandKitRequest.js +64 -0
- package/dist/models/PatchBrandKitRequestFonts.d.ts +51 -0
- package/dist/models/PatchBrandKitRequestFonts.js +55 -0
- package/dist/models/PatchBrandKitRequestSpacing.d.ts +74 -0
- package/dist/models/PatchBrandKitRequestSpacing.js +62 -0
- package/dist/models/PostBrandKitIconRequest.d.ts +38 -0
- package/dist/models/PostBrandKitIconRequest.js +54 -0
- package/dist/models/PublicWorkflowEventsRequestEventsInner.d.ts +21 -0
- package/dist/models/PublicWorkflowEventsRequestEventsInner.js +12 -1
- package/dist/models/PublicWorkflowResponse.d.ts +46 -0
- package/dist/models/{GetPublicWorkflow200Response.js → PublicWorkflowResponse.js} +13 -13
- package/dist/models/PutBrandKitRequest.d.ts +46 -0
- package/dist/models/PutBrandKitRequest.js +56 -0
- package/dist/models/UpdateOrganizationDomainResponse.d.ts +46 -0
- package/dist/models/UpdateOrganizationDomainResponse.js +58 -0
- package/dist/models/Upload.d.ts +7 -1
- package/dist/models/Upload.js +2 -0
- package/dist/models/UploadLimits.d.ts +3 -3
- package/dist/models/UserApiKey.d.ts +6 -0
- package/dist/models/UserApiKey.js +2 -0
- package/dist/models/ValidateToken200ResponseData.d.ts +7 -0
- package/dist/models/ValidateToken200ResponseData.js +3 -0
- package/dist/models/ValidateToken200ResponseDataWorkspace.d.ts +38 -0
- package/dist/models/ValidateToken200ResponseDataWorkspace.js +50 -0
- package/dist/models/Widget.d.ts +18 -0
- package/dist/models/Widget.js +6 -0
- package/dist/models/WidgetClarification.d.ts +45 -0
- package/dist/models/WidgetClarification.js +59 -0
- package/dist/models/WidgetClarificationOption.d.ts +44 -0
- package/dist/models/WidgetClarificationOption.js +58 -0
- package/dist/models/WidgetClarificationQuestion.d.ts +63 -0
- package/dist/models/WidgetClarificationQuestion.js +71 -0
- package/dist/models/WidgetCodeChange.d.ts +70 -0
- package/dist/models/WidgetCodeChange.js +76 -0
- package/dist/models/WidgetCodeChanges.d.ts +39 -0
- package/dist/models/WidgetCodeChanges.js +55 -0
- package/dist/models/WidgetNextStep.d.ts +69 -0
- package/dist/models/WidgetNextStep.js +79 -0
- package/dist/models/WidgetPlan.d.ts +58 -0
- package/dist/models/WidgetPlan.js +68 -0
- package/dist/models/WidgetPlanDecisions.d.ts +77 -0
- package/dist/models/WidgetPlanDecisions.js +79 -0
- package/dist/models/WidgetPlanDecisionsAdaptersInner.d.ts +38 -0
- package/dist/models/WidgetPlanDecisionsAdaptersInner.js +54 -0
- package/dist/models/WidgetPlanDecisionsLibrariesInner.d.ts +44 -0
- package/dist/models/WidgetPlanDecisionsLibrariesInner.js +58 -0
- package/dist/models/WidgetPlanDecisionsResponsive.d.ts +44 -0
- package/dist/models/WidgetPlanDecisionsResponsive.js +58 -0
- package/dist/models/WidgetPlanTask.d.ts +77 -0
- package/dist/models/WidgetPlanTask.js +88 -0
- package/dist/models/WorkflowDetailAllOfLastEditedBy.d.ts +2 -2
- package/dist/models/WorkflowDetailResponse.d.ts +46 -0
- package/dist/models/WorkflowDetailResponse.js +58 -0
- package/dist/models/WorkflowFailureReason.d.ts +31 -0
- package/dist/models/WorkflowFailureReason.js +57 -0
- package/dist/models/WorkflowFailureReasonCounter.d.ts +45 -0
- package/dist/models/WorkflowFailureReasonCounter.js +59 -0
- package/dist/models/WorkflowResponse.d.ts +46 -0
- package/dist/models/{SaveWorkspaceWorkflow200Response.js → WorkflowResponse.js} +13 -13
- package/dist/models/WorkflowStats.d.ts +16 -1
- package/dist/models/WorkflowStats.js +3 -0
- package/dist/models/index.d.ts +59 -25
- package/dist/models/index.js +59 -25
- package/dist/runtime.d.ts +2 -2
- package/dist/runtime.js +1 -1
- package/package.json +1 -1
- package/dist/apis/PartnerApi.d.ts +0 -2595
- package/dist/apis/PartnerApi.js +0 -6749
- package/dist/apis/WorkspacesApi.d.ts +0 -352
- package/dist/apis/WorkspacesApi.js +0 -946
- package/dist/esm/apis/PartnerApi.js +0 -6712
- package/dist/esm/apis/WorkspacesApi.js +0 -909
- package/dist/esm/models/DeletePersonalWorkspaceDomainResponse.js +0 -51
- package/dist/esm/models/DeletePersonalWorkspaceDomainResponseData.js +0 -41
- package/dist/esm/models/GetPersonalWorkspaceDomains200Response.js +0 -51
- package/dist/esm/models/PersonalWorkspaceDomainResult.js +0 -48
- package/dist/esm/models/PersonalWorkspaceDomainResultResponse.js +0 -51
- package/dist/esm/models/UploadsIdDelete200Response.js +0 -51
- package/dist/models/AddAiAnswersKnowledgeDocument201Response.d.ts +0 -46
- package/dist/models/CreateCompositionContentItem201Response.d.ts +0 -46
- package/dist/models/CreateCompositionDatabaseRecord201Response.d.ts +0 -48
- package/dist/models/CreateCompositionDatabaseRecord201Response.js +0 -57
- package/dist/models/CreateCompositionFromWidget201Response.d.ts +0 -46
- package/dist/models/CreateCompositionFromWidget201Response.js +0 -58
- package/dist/models/CreateWorkspaceWorkflowFromPreset201Response.d.ts +0 -46
- package/dist/models/CreateWorkspaceWorkflowFromPreset201Response.js +0 -58
- package/dist/models/DeleteManagedUser200Response.d.ts +0 -46
- package/dist/models/DeletePersonalWorkspaceDomainResponse.d.ts +0 -46
- package/dist/models/DeletePersonalWorkspaceDomainResponse.js +0 -58
- package/dist/models/DeletePersonalWorkspaceDomainResponseData.d.ts +0 -32
- package/dist/models/DeletePersonalWorkspaceDomainResponseData.js +0 -48
- package/dist/models/GetManagedUserLimits200Response.d.ts +0 -46
- package/dist/models/GetPartnerCreditTransactions200Response.d.ts +0 -46
- package/dist/models/GetPartnerDesignDefaults200Response.d.ts +0 -46
- package/dist/models/GetPersonalWorkspaceDomains200Response.d.ts +0 -46
- package/dist/models/GetPersonalWorkspaceDomains200Response.js +0 -58
- package/dist/models/GetPublicWorkflow200Response.d.ts +0 -46
- package/dist/models/GetUserAdapterConnections200Response.d.ts +0 -46
- package/dist/models/OperationsIdGetResponse.d.ts +0 -46
- package/dist/models/OperationsIdGetResponseData.d.ts +0 -88
- package/dist/models/PersonalWorkspaceDomain.d.ts +0 -56
- package/dist/models/PersonalWorkspaceDomain.js +0 -62
- package/dist/models/PersonalWorkspaceDomainResult.d.ts +0 -39
- package/dist/models/PersonalWorkspaceDomainResult.js +0 -55
- package/dist/models/PersonalWorkspaceDomainResultResponse.d.ts +0 -46
- package/dist/models/PersonalWorkspaceDomainResultResponse.js +0 -58
- package/dist/models/RemoveUserAdapterConnection200Response.d.ts +0 -46
- package/dist/models/SaveWorkspaceWorkflow200Response.d.ts +0 -46
- package/dist/models/SetUserAdapterConnection200Response.d.ts +0 -46
- package/dist/models/UploadsGet200Response.d.ts +0 -46
- package/dist/models/UploadsIdDelete200Response.d.ts +0 -46
- package/dist/models/UploadsIdDelete200Response.js +0 -58
- package/dist/models/UploadsIdDelete200ResponseData.d.ts +0 -32
- package/dist/models/UploadsIdDelete200ResponseData.js +0 -48
|
@@ -90,6 +90,41 @@ class PublicEmbedApi extends runtime.BaseAPI {
|
|
|
90
90
|
const response = await this.callPublicCompositionAdapterRaw(requestParameters, initOverrides);
|
|
91
91
|
return await response.value();
|
|
92
92
|
}
|
|
93
|
+
/**
|
|
94
|
+
* Removes every row of one table. The caller must send the composition write token (`X-Widgetic-Write-Token`), the same token a widget receives as `entries.writeToken`. No owner session. A permitted Origin is required, the same rule as appending a row.
|
|
95
|
+
* Reset one table of a composition
|
|
96
|
+
*/
|
|
97
|
+
async clearPublicCompositionEntriesRaw(requestParameters, initOverrides) {
|
|
98
|
+
if (requestParameters['compositionId'] == null) {
|
|
99
|
+
throw new runtime.RequiredError('compositionId', 'Required parameter "compositionId" was null or undefined when calling clearPublicCompositionEntries().');
|
|
100
|
+
}
|
|
101
|
+
if (requestParameters['table'] == null) {
|
|
102
|
+
throw new runtime.RequiredError('table', 'Required parameter "table" was null or undefined when calling clearPublicCompositionEntries().');
|
|
103
|
+
}
|
|
104
|
+
if (requestParameters['xWidgeticWriteToken'] == null) {
|
|
105
|
+
throw new runtime.RequiredError('xWidgeticWriteToken', 'Required parameter "xWidgeticWriteToken" was null or undefined when calling clearPublicCompositionEntries().');
|
|
106
|
+
}
|
|
107
|
+
const queryParameters = {};
|
|
108
|
+
const headerParameters = {};
|
|
109
|
+
if (requestParameters['xWidgeticWriteToken'] != null) {
|
|
110
|
+
headerParameters['X-Widgetic-Write-Token'] = String(requestParameters['xWidgeticWriteToken']);
|
|
111
|
+
}
|
|
112
|
+
const response = await this.request({
|
|
113
|
+
path: `/embed/compositions/{compositionId}/entries/{table}`.replace(`{${"compositionId"}}`, encodeURIComponent(String(requestParameters['compositionId']))).replace(`{${"table"}}`, encodeURIComponent(String(requestParameters['table']))),
|
|
114
|
+
method: 'DELETE',
|
|
115
|
+
headers: headerParameters,
|
|
116
|
+
query: queryParameters,
|
|
117
|
+
}, initOverrides);
|
|
118
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.SuccessResponseFromJSON)(jsonValue));
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Removes every row of one table. The caller must send the composition write token (`X-Widgetic-Write-Token`), the same token a widget receives as `entries.writeToken`. No owner session. A permitted Origin is required, the same rule as appending a row.
|
|
122
|
+
* Reset one table of a composition
|
|
123
|
+
*/
|
|
124
|
+
async clearPublicCompositionEntries(requestParameters, initOverrides) {
|
|
125
|
+
const response = await this.clearPublicCompositionEntriesRaw(requestParameters, initOverrides);
|
|
126
|
+
return await response.value();
|
|
127
|
+
}
|
|
93
128
|
/**
|
|
94
129
|
* Public append-only write into a published composition database. No API key. The browser must send a permitted `Origin` header: the artifact iframe origin, or any website when the owner has not restricted the allowed websites (when the owner has, one of the websites the owner listed, Widgetic\'s own sites, the visitor\'s own machine or the owner\'s own platform). When the request comes from the shared artifact origin, it must also carry the per-composition write token (`X-Widgetic-Write-Token` header or `writeToken` body field, handed to the widget in `widgetic:host` as `entries.writeToken` and returned as `entryWriteToken` on `getPublicCompositionEmbed`). Host `context` is stored for partner attribution; it is not authenticated unless the partner signs it (see **Signed context**). Request bodies are limited to 16 KB before parsing. **Address.** `https://api.widgetic.com/embed/compositions/{compositionId}/entries/{table}`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag. **Signed context.** A partner that wants to trust `context` (to bill a customer by it, say) makes a signing secret (`rotatePartnerEntryContextSecret`), and its server signs the context it hands to the embed. The signature travels inside `context` as two reserved keys, `widgetic_exp` (UTC seconds, at most seven days ahead) and `widgetic_sig`. The gateway checks them after the `Origin` and before anything else is judged, stored or announced, and keeps and announces the context WITHOUT them. A context that is not signed as the partner requires is refused with 403 `CONTEXT_SIGNATURE_REQUIRED`, `CONTEXT_SIGNATURE_INVALID` or `CONTEXT_SIGNATURE_EXPIRED`; when the check cannot be made just now the answer is a retryable 503 `CONTEXT_SIGNATURE_UNAVAILABLE`, never an unchecked entry. Until a partner makes a secret nothing changes: the two keys are dropped and the rest is taken as it came. A signature is good until its `widgetic_exp` and may be used again until then, so a partner that must count each submission once keeps a unique value of its own (a `submissionId`, say) in the context. The recipe and a test vector are in the description of `rotatePartnerEntryContextSecret`.
|
|
95
130
|
* Append a visitor entry through the gateway
|
|
@@ -188,7 +223,33 @@ class PublicEmbedApi extends runtime.BaseAPI {
|
|
|
188
223
|
return await response.value();
|
|
189
224
|
}
|
|
190
225
|
/**
|
|
191
|
-
*
|
|
226
|
+
* Public read of a workflow for the embed that carries `workflow-id`. No API key. The answer is the live version (its graph, the composition a new visitor starts on, the time zone, the languages its compositions can be shown in, and the token that lets the browser report counts), or `status: paused` with nothing else, in which case the embed shows only its first composition. A workflow that is a draft, archived or unknown answers 404, and the embed then behaves as a plain embed of its `composition-id`. So does a workflow whose owner is not being served (a plan that lapsed, a partner whose agreement is not in force): the answer is the one the compositions of that owner give. **Address.** `https://api.widgetic.com/embed/workflows/{workflowId}`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag. The answer may be reused for a few seconds (`Cache-Control: public, max-age=15`), so a publish or a pause reaches visitors within moments. The graph is readable by anyone who has the workflow\'s id: its rules run in the visitor\'s browser, so a rule must never hold a secret.
|
|
227
|
+
* Read the published Workflow of an embed
|
|
228
|
+
*/
|
|
229
|
+
async getPublicWorkflowRaw(requestParameters, initOverrides) {
|
|
230
|
+
if (requestParameters['workflowId'] == null) {
|
|
231
|
+
throw new runtime.RequiredError('workflowId', 'Required parameter "workflowId" was null or undefined when calling getPublicWorkflow().');
|
|
232
|
+
}
|
|
233
|
+
const queryParameters = {};
|
|
234
|
+
const headerParameters = {};
|
|
235
|
+
const response = await this.request({
|
|
236
|
+
path: `/embed/workflows/{workflowId}`.replace(`{${"workflowId"}}`, encodeURIComponent(String(requestParameters['workflowId']))),
|
|
237
|
+
method: 'GET',
|
|
238
|
+
headers: headerParameters,
|
|
239
|
+
query: queryParameters,
|
|
240
|
+
}, initOverrides);
|
|
241
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.PublicWorkflowResponseFromJSON)(jsonValue));
|
|
242
|
+
}
|
|
243
|
+
/**
|
|
244
|
+
* Public read of a workflow for the embed that carries `workflow-id`. No API key. The answer is the live version (its graph, the composition a new visitor starts on, the time zone, the languages its compositions can be shown in, and the token that lets the browser report counts), or `status: paused` with nothing else, in which case the embed shows only its first composition. A workflow that is a draft, archived or unknown answers 404, and the embed then behaves as a plain embed of its `composition-id`. So does a workflow whose owner is not being served (a plan that lapsed, a partner whose agreement is not in force): the answer is the one the compositions of that owner give. **Address.** `https://api.widgetic.com/embed/workflows/{workflowId}`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag. The answer may be reused for a few seconds (`Cache-Control: public, max-age=15`), so a publish or a pause reaches visitors within moments. The graph is readable by anyone who has the workflow\'s id: its rules run in the visitor\'s browser, so a rule must never hold a secret.
|
|
245
|
+
* Read the published Workflow of an embed
|
|
246
|
+
*/
|
|
247
|
+
async getPublicWorkflow(requestParameters, initOverrides) {
|
|
248
|
+
const response = await this.getPublicWorkflowRaw(requestParameters, initOverrides);
|
|
249
|
+
return await response.value();
|
|
250
|
+
}
|
|
251
|
+
/**
|
|
252
|
+
* A page that runs a published workflow, for a place that can only be given an address or an iframe: a chat messenger, a link page, a site builder, a blog that follows oEmbed. No API key, no SDK to add. The page holds the Embed SDK and the same tag a website carries (`<widgetic workflow-id composition-id>`), so a visitor moves from one composition to the next in place, by the same rules, exactly as on a website. A paused workflow shows its first composition alone, as its embeds do. **What the frame can count.** Only what happens inside it: entries, a widget\'s goals and actions, and waits. The page events a website can send to a workflow (`widgetic:workflow-event`) are events of the page around the embed, and they do not cross an iframe, so a connection that waits for one never fires from a frame. A workflow that is a draft, is archived, or does not exist, and one whose owner is not being served, answers 404 with a short page that gives no reason. If the owner of the workflow\'s first composition listed the websites it may appear on, the page is sent with `Content-Security-Policy: frame-ancestors` naming those websites (and Widgetic\'s own, and the website where the partner the owner administers integrates Widgetic, with its subdomains), so a browser refuses to show it inside any other website. Opening the address directly still works. An owner who listed nothing is not restricted. The page links its oEmbed card, so a site that follows oEmbed turns the address of the frame into an embed. **Address.** `https://api.widgetic.com/embed/workflows/{workflowId}/frame`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag.
|
|
192
253
|
* Show a published Workflow in a page of its own
|
|
193
254
|
*/
|
|
194
255
|
async getPublicWorkflowFrameRaw(requestParameters, initOverrides) {
|
|
@@ -211,7 +272,7 @@ class PublicEmbedApi extends runtime.BaseAPI {
|
|
|
211
272
|
}
|
|
212
273
|
}
|
|
213
274
|
/**
|
|
214
|
-
* A page that runs a published workflow, for a place that can only be given an address or an iframe: a chat messenger, a link page, a site builder, a blog that follows oEmbed. No API key, no SDK to add. The page holds the Embed SDK and the same tag a website carries (`<widgetic workflow-id composition-id>`), so a visitor moves from one composition to the next in place, by the same rules, exactly as on a website. A paused workflow shows its first composition alone, as its embeds do. **What the frame can count.** Only what happens inside it: entries, a widget\'s goals and actions, and waits. The page events a website can send to a workflow (`widgetic:workflow-event`) are events of the page around the embed, and they do not cross an iframe, so a connection that waits for one never fires from a frame. A workflow that is a draft, is archived, or does not exist, and one whose owner is not being served, answers 404 with a short page that gives no reason. If the owner of the workflow\'s first composition listed the websites it may appear on, the page is sent with `Content-Security-Policy: frame-ancestors` naming those websites (and Widgetic\'s own), so a browser refuses to show it inside any other website. Opening the address directly still works. An owner who listed nothing is not restricted. The page links its oEmbed card, so a site that follows oEmbed turns the address of the frame into an embed. **Address.** `https://api.widgetic.com/embed/workflows/{workflowId}/frame`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag.
|
|
275
|
+
* A page that runs a published workflow, for a place that can only be given an address or an iframe: a chat messenger, a link page, a site builder, a blog that follows oEmbed. No API key, no SDK to add. The page holds the Embed SDK and the same tag a website carries (`<widgetic workflow-id composition-id>`), so a visitor moves from one composition to the next in place, by the same rules, exactly as on a website. A paused workflow shows its first composition alone, as its embeds do. **What the frame can count.** Only what happens inside it: entries, a widget\'s goals and actions, and waits. The page events a website can send to a workflow (`widgetic:workflow-event`) are events of the page around the embed, and they do not cross an iframe, so a connection that waits for one never fires from a frame. A workflow that is a draft, is archived, or does not exist, and one whose owner is not being served, answers 404 with a short page that gives no reason. If the owner of the workflow\'s first composition listed the websites it may appear on, the page is sent with `Content-Security-Policy: frame-ancestors` naming those websites (and Widgetic\'s own, and the website where the partner the owner administers integrates Widgetic, with its subdomains), so a browser refuses to show it inside any other website. Opening the address directly still works. An owner who listed nothing is not restricted. The page links its oEmbed card, so a site that follows oEmbed turns the address of the frame into an embed. **Address.** `https://api.widgetic.com/embed/workflows/{workflowId}/frame`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag.
|
|
215
276
|
* Show a published Workflow in a page of its own
|
|
216
277
|
*/
|
|
217
278
|
async getPublicWorkflowFrame(requestParameters, initOverrides) {
|
|
@@ -237,7 +298,7 @@ class PublicEmbedApi extends runtime.BaseAPI {
|
|
|
237
298
|
headers: headerParameters,
|
|
238
299
|
query: queryParameters,
|
|
239
300
|
}, initOverrides);
|
|
240
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.
|
|
301
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.PublicWorkflowResponseFromJSON)(jsonValue));
|
|
241
302
|
}
|
|
242
303
|
/**
|
|
243
304
|
* Public read of one version of a workflow, for a visitor who started on it before a newer one was published: they finish on the version they started on (for up to 30 days; after that they get the latest). The graph of a version never changes once published; the languages its compositions can be shown in (`translations`) are read each time, as for the live version. Like the read of the live version, it answers `status: paused` with nothing else while the workflow is paused, and 404 when the workflow is a draft or archived, or has no such version. **Address.** `https://api.widgetic.com/embed/workflows/{workflowId}/versions/{versionId}`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag.
|
|
@@ -247,32 +308,6 @@ class PublicEmbedApi extends runtime.BaseAPI {
|
|
|
247
308
|
const response = await this.getPublicWorkflowVersionRaw(requestParameters, initOverrides);
|
|
248
309
|
return await response.value();
|
|
249
310
|
}
|
|
250
|
-
/**
|
|
251
|
-
* Public read of a workflow for the embed that carries `workflow-id`. No API key. The answer is the live version (its graph, the composition a new visitor starts on, the time zone, the languages its compositions can be shown in, and the token that lets the browser report counts), or `status: paused` with nothing else, in which case the embed shows only its first composition. A workflow that is a draft, archived or unknown answers 404, and the embed then behaves as a plain embed of its `composition-id`. So does a workflow whose owner is not being served (a plan that lapsed, a partner whose agreement is not in force): the answer is the one the compositions of that owner give. **Address.** `https://api.widgetic.com/embed/workflows/{workflowId}`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag. The answer may be reused for a few seconds (`Cache-Control: public, max-age=15`), so a publish or a pause reaches visitors within moments. The graph is readable by anyone who has the workflow\'s id: its rules run in the visitor\'s browser, so a rule must never hold a secret.
|
|
252
|
-
* Read the published Workflow of an embed
|
|
253
|
-
*/
|
|
254
|
-
async getPublicWorkflowRaw(requestParameters, initOverrides) {
|
|
255
|
-
if (requestParameters['workflowId'] == null) {
|
|
256
|
-
throw new runtime.RequiredError('workflowId', 'Required parameter "workflowId" was null or undefined when calling getPublicWorkflow().');
|
|
257
|
-
}
|
|
258
|
-
const queryParameters = {};
|
|
259
|
-
const headerParameters = {};
|
|
260
|
-
const response = await this.request({
|
|
261
|
-
path: `/embed/workflows/{workflowId}`.replace(`{${"workflowId"}}`, encodeURIComponent(String(requestParameters['workflowId']))),
|
|
262
|
-
method: 'GET',
|
|
263
|
-
headers: headerParameters,
|
|
264
|
-
query: queryParameters,
|
|
265
|
-
}, initOverrides);
|
|
266
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.GetPublicWorkflow200ResponseFromJSON)(jsonValue));
|
|
267
|
-
}
|
|
268
|
-
/**
|
|
269
|
-
* Public read of a workflow for the embed that carries `workflow-id`. No API key. The answer is the live version (its graph, the composition a new visitor starts on, the time zone, the languages its compositions can be shown in, and the token that lets the browser report counts), or `status: paused` with nothing else, in which case the embed shows only its first composition. A workflow that is a draft, archived or unknown answers 404, and the embed then behaves as a plain embed of its `composition-id`. So does a workflow whose owner is not being served (a plan that lapsed, a partner whose agreement is not in force): the answer is the one the compositions of that owner give. **Address.** `https://api.widgetic.com/embed/workflows/{workflowId}`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag. The answer may be reused for a few seconds (`Cache-Control: public, max-age=15`), so a publish or a pause reaches visitors within moments. The graph is readable by anyone who has the workflow\'s id: its rules run in the visitor\'s browser, so a rule must never hold a secret.
|
|
270
|
-
* Read the published Workflow of an embed
|
|
271
|
-
*/
|
|
272
|
-
async getPublicWorkflow(requestParameters, initOverrides) {
|
|
273
|
-
const response = await this.getPublicWorkflowRaw(requestParameters, initOverrides);
|
|
274
|
-
return await response.value();
|
|
275
|
-
}
|
|
276
311
|
/**
|
|
277
312
|
* Public batch health check for embed-sdk.js. No API key. Uses the same serving gate and domain policy as `GET /embed/compositions/{compositionId}`: the caller\'s website is read from `Origin`, or the host of `Referer` when there is no `Origin`. A request that names neither (a server or tool) is not refused for domain reasons. **Address.** `https://api.widgetic.com/embed/compositions/status`: the root of the API host, NOT under `/v1`. A client generated from this description for `https://api.widgetic.com/v1` must be given the base address `https://api.widgetic.com` for the calls of the `Public Embed` tag. **Limit.** The route counts against the same limit as the lookup and the frame routes: 500 calls for each visitor address and browser in one counting window. A call is ONE hit whatever the number of `ids` it carries (up to 100), so a server that checks many compositions spends one call for each hundred of them. A visitor who is over the limit gets 429 `RATE_LIMITED` for the WHOLE call, with a `Retry-After` header and no state for any id: there is no per-composition rate-limit state in the answer.
|
|
278
313
|
* Batch-check whether compositions are currently served for embed
|
package/dist/apis/TokensApi.d.ts
CHANGED
|
@@ -16,10 +16,12 @@ import type { ValidateToken200Response } from '../models/index';
|
|
|
16
16
|
*/
|
|
17
17
|
export declare class TokensApi extends runtime.BaseAPI {
|
|
18
18
|
/**
|
|
19
|
+
* Describes the credential the request was made with: how it signs in (`tokenType`), what it may do (`scopes`), the account it belongs to (`userId`) and the workspace it works in (`workspace`). An API key works in the one workspace it was made for, whichever workspace its owner is looking at on widgetic.com; a signed-in session names none (`workspace` is null), and follows the workspace the person has chosen. A credential that belongs to the platform itself, and not to a customer\'s account, is held to no scope: it is answered with `tokenType` `service_key`, `scopes` `[\"*:*\"]`, no `userId` and no `workspace`.
|
|
19
20
|
* Validate current authentication token
|
|
20
21
|
*/
|
|
21
22
|
validateTokenRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ValidateToken200Response>>;
|
|
22
23
|
/**
|
|
24
|
+
* Describes the credential the request was made with: how it signs in (`tokenType`), what it may do (`scopes`), the account it belongs to (`userId`) and the workspace it works in (`workspace`). An API key works in the one workspace it was made for, whichever workspace its owner is looking at on widgetic.com; a signed-in session names none (`workspace` is null), and follows the workspace the person has chosen. A credential that belongs to the platform itself, and not to a customer\'s account, is held to no scope: it is answered with `tokenType` `service_key`, `scopes` `[\"*:*\"]`, no `userId` and no `workspace`.
|
|
23
25
|
* Validate current authentication token
|
|
24
26
|
*/
|
|
25
27
|
validateToken(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ValidateToken200Response>;
|
package/dist/apis/TokensApi.js
CHANGED
|
@@ -54,6 +54,7 @@ const index_1 = require("../models/index");
|
|
|
54
54
|
*/
|
|
55
55
|
class TokensApi extends runtime.BaseAPI {
|
|
56
56
|
/**
|
|
57
|
+
* Describes the credential the request was made with: how it signs in (`tokenType`), what it may do (`scopes`), the account it belongs to (`userId`) and the workspace it works in (`workspace`). An API key works in the one workspace it was made for, whichever workspace its owner is looking at on widgetic.com; a signed-in session names none (`workspace` is null), and follows the workspace the person has chosen. A credential that belongs to the platform itself, and not to a customer\'s account, is held to no scope: it is answered with `tokenType` `service_key`, `scopes` `[\"*:*\"]`, no `userId` and no `workspace`.
|
|
57
58
|
* Validate current authentication token
|
|
58
59
|
*/
|
|
59
60
|
async validateTokenRaw(initOverrides) {
|
|
@@ -78,6 +79,7 @@ class TokensApi extends runtime.BaseAPI {
|
|
|
78
79
|
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.ValidateToken200ResponseFromJSON)(jsonValue));
|
|
79
80
|
}
|
|
80
81
|
/**
|
|
82
|
+
* Describes the credential the request was made with: how it signs in (`tokenType`), what it may do (`scopes`), the account it belongs to (`userId`) and the workspace it works in (`workspace`). An API key works in the one workspace it was made for, whichever workspace its owner is looking at on widgetic.com; a signed-in session names none (`workspace` is null), and follows the workspace the person has chosen. A credential that belongs to the platform itself, and not to a customer\'s account, is held to no scope: it is answered with `tokenType` `service_key`, `scopes` `[\"*:*\"]`, no `userId` and no `workspace`.
|
|
81
83
|
* Validate current authentication token
|
|
82
84
|
*/
|
|
83
85
|
async validateToken(initOverrides) {
|
|
@@ -10,107 +10,107 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type {
|
|
14
|
-
export interface
|
|
15
|
-
limit?: number;
|
|
16
|
-
managedUserId?: string;
|
|
17
|
-
managedUserExternalId?: string;
|
|
18
|
-
}
|
|
19
|
-
export interface UploadsIdDelete0Request {
|
|
13
|
+
import type { DeleteUpload200Response, ListUploads200Response, UploadLimitsResponse, UploadResponse } from '../models/index';
|
|
14
|
+
export interface DeleteUploadRequest {
|
|
20
15
|
id: string;
|
|
21
16
|
}
|
|
22
|
-
export interface
|
|
17
|
+
export interface GetUploadRequest {
|
|
23
18
|
id: string;
|
|
24
19
|
}
|
|
25
|
-
export interface
|
|
20
|
+
export interface ListUploadsRequest {
|
|
21
|
+
limit?: number;
|
|
22
|
+
managedUserId?: string;
|
|
23
|
+
managedUserExternalId?: string;
|
|
24
|
+
}
|
|
25
|
+
export interface UploadFileRequest {
|
|
26
26
|
file: Blob;
|
|
27
|
-
contextType?:
|
|
28
|
-
source?:
|
|
27
|
+
contextType?: UploadFileContextTypeEnum;
|
|
28
|
+
source?: UploadFileSourceEnum;
|
|
29
29
|
managedUserId?: string;
|
|
30
30
|
managedUserExternalId?: string;
|
|
31
|
-
purpose?:
|
|
31
|
+
purpose?: UploadFilePurposeEnum;
|
|
32
32
|
}
|
|
33
33
|
/**
|
|
34
34
|
*
|
|
35
35
|
*/
|
|
36
36
|
export declare class UploadsApi extends runtime.BaseAPI {
|
|
37
37
|
/**
|
|
38
|
-
*
|
|
39
|
-
* List the account\'s uploads
|
|
40
|
-
*/
|
|
41
|
-
uploadsGetRaw(requestParameters: UploadsGet0Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<UploadsGet200Response>>;
|
|
42
|
-
/**
|
|
43
|
-
* The files the account has uploaded, newest first. Deleted files are not listed. Returns at most `limit` files and has no further pages: a client that needs more narrows the list instead, for example to one managed user\'s files with `managedUserId` or `managedUserExternalId`. The files that visitors sent through a widget\'s upload adapter (`source` is `widget-visitor-upload`) are not part of this list, so that a popular widget does not push the account\'s own files out of it; naming one widget with `widgetId` lists what visitors sent to that widget as well.
|
|
44
|
-
* List the account\'s uploads
|
|
45
|
-
*/
|
|
46
|
-
uploadsGet(requestParameters?: UploadsGet0Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<UploadsGet200Response>;
|
|
47
|
-
/**
|
|
48
|
-
* Removes the stored file and the upload row. A file in Widgetic\'s own storage gives back the space it took from your storage allowance; a file in your own bucket is removed from your bucket. Deleting an upload that is already gone succeeds the same way as the first delete. An upload that belongs to another account is not found. If the storage cannot be reached the call fails and nothing is marked deleted, so it can be repeated.
|
|
38
|
+
* Removes the stored file and the upload row. A file in Widgetic\'s own storage gives back the space it took from the storage allowance it was charged to (the team\'s shared space for a file uploaded in a team workspace); a file in your own bucket is removed from your bucket. Deleting an upload that is already gone succeeds the same way as the first delete. A file you uploaded can always be deleted by you. A file in a team\'s workspace can also be deleted by the owner and by every active member of that team, whoever uploaded it (the files of a workspace are the whole team\'s). An upload that belongs to another account, or to a team you are not a member of, is not found. If the storage cannot be reached the call fails and nothing is marked deleted, so it can be repeated.
|
|
49
39
|
* Delete an upload
|
|
50
40
|
*/
|
|
51
|
-
|
|
41
|
+
deleteUploadRaw(requestParameters: DeleteUploadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DeleteUpload200Response>>;
|
|
52
42
|
/**
|
|
53
|
-
* Removes the stored file and the upload row. A file in Widgetic\'s own storage gives back the space it took from
|
|
43
|
+
* Removes the stored file and the upload row. A file in Widgetic\'s own storage gives back the space it took from the storage allowance it was charged to (the team\'s shared space for a file uploaded in a team workspace); a file in your own bucket is removed from your bucket. Deleting an upload that is already gone succeeds the same way as the first delete. A file you uploaded can always be deleted by you. A file in a team\'s workspace can also be deleted by the owner and by every active member of that team, whoever uploaded it (the files of a workspace are the whole team\'s). An upload that belongs to another account, or to a team you are not a member of, is not found. If the storage cannot be reached the call fails and nothing is marked deleted, so it can be repeated.
|
|
54
44
|
* Delete an upload
|
|
55
45
|
*/
|
|
56
|
-
|
|
46
|
+
deleteUpload(requestParameters: DeleteUploadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DeleteUpload200Response>;
|
|
57
47
|
/**
|
|
58
48
|
* The details of one of the account\'s uploads. An upload that belongs to another account is not found.
|
|
59
49
|
* Get an upload by id
|
|
60
50
|
*/
|
|
61
|
-
|
|
51
|
+
getUploadRaw(requestParameters: GetUploadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<UploadResponse>>;
|
|
62
52
|
/**
|
|
63
53
|
* The details of one of the account\'s uploads. An upload that belongs to another account is not found.
|
|
64
54
|
* Get an upload by id
|
|
65
55
|
*/
|
|
66
|
-
|
|
56
|
+
getUpload(requestParameters: GetUploadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<UploadResponse>;
|
|
67
57
|
/**
|
|
68
58
|
* The size limit and the accepted file types of the upload endpoints. Read them from here rather than hard-coding thresholds: they are configuration and can change. The limits are the same for every account, whatever its plan: `multipart_max_bytes` for a file sent in one request (10 MB) and `tus_max_bytes` for a resumable upload (250 MB).
|
|
69
59
|
* Upload size limits and accepted file types
|
|
70
60
|
*/
|
|
71
|
-
|
|
61
|
+
getUploadLimitsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<UploadLimitsResponse>>;
|
|
72
62
|
/**
|
|
73
63
|
* The size limit and the accepted file types of the upload endpoints. Read them from here rather than hard-coding thresholds: they are configuration and can change. The limits are the same for every account, whatever its plan: `multipart_max_bytes` for a file sent in one request (10 MB) and `tus_max_bytes` for a resumable upload (250 MB).
|
|
74
64
|
* Upload size limits and accepted file types
|
|
75
65
|
*/
|
|
76
|
-
|
|
66
|
+
getUploadLimits(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<UploadLimitsResponse>;
|
|
67
|
+
/**
|
|
68
|
+
* The files of the workspace the caller works in, newest first: the workspace\'s shared files (every member\'s, and those of members who have since left). The workspace is the one a person signed in on widgetic.com switched to, or the one an API key or a connection belongs to; an editor session names none and lists the files of the account. Deleted files are not listed. Returns at most `limit` files and has no further pages: a client that needs more narrows the list instead, for example to one managed user\'s files with `managedUserId` or `managedUserExternalId`. The files that visitors sent through a widget\'s upload adapter (`source` is `widget-visitor-upload`) are not part of this list, so that a popular widget does not push the account\'s own files out of it; naming one widget with `widgetId` lists what visitors sent to that widget as well.
|
|
69
|
+
* List the account\'s uploads
|
|
70
|
+
*/
|
|
71
|
+
listUploadsRaw(requestParameters: ListUploadsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListUploads200Response>>;
|
|
72
|
+
/**
|
|
73
|
+
* The files of the workspace the caller works in, newest first: the workspace\'s shared files (every member\'s, and those of members who have since left). The workspace is the one a person signed in on widgetic.com switched to, or the one an API key or a connection belongs to; an editor session names none and lists the files of the account. Deleted files are not listed. Returns at most `limit` files and has no further pages: a client that needs more narrows the list instead, for example to one managed user\'s files with `managedUserId` or `managedUserExternalId`. The files that visitors sent through a widget\'s upload adapter (`source` is `widget-visitor-upload`) are not part of this list, so that a popular widget does not push the account\'s own files out of it; naming one widget with `widgetId` lists what visitors sent to that widget as well.
|
|
74
|
+
* List the account\'s uploads
|
|
75
|
+
*/
|
|
76
|
+
listUploads(requestParameters?: ListUploadsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListUploads200Response>;
|
|
77
77
|
/**
|
|
78
|
-
* Stores one file for the account and returns its public address. This is how a user\'s own images, video and PDFs reach a widget\'s content. Send a `multipart/form-data` request with the file in the field named `file`. The file counts against the storage of the workspace it is uploaded in, and a full workspace is refused with 413 and `QUOTA_STORAGE_EXCEEDED`. For a person signed in on widgetic.com that is the workspace they are currently working in: inside a team, the team\'s shared storage; inside their own workspace, their own allowance. An organization API key, and a Shopify store\'s session, always work in that team\'s shared storage. A personal API key or an SDK token always uses the account\'s own allowance. The two never add up and one never lends room to the other. A file over the size limit is refused with 413 and `UPLOAD_TOO_LARGE`, and a type that is not accepted with 415 and `UPLOAD_UNSUPPORTED_TYPE`; `
|
|
78
|
+
* Stores one file for the account and returns its public address. This is how a user\'s own images, video and PDFs reach a widget\'s content. Send a `multipart/form-data` request with the file in the field named `file`. The file counts against the storage of the workspace it is uploaded in, and a full workspace is refused with 413 and `QUOTA_STORAGE_EXCEEDED`. For a person signed in on widgetic.com that is the workspace they are currently working in: inside a team, the team\'s shared storage; inside their own workspace, their own allowance. An organization API key, and a Shopify store\'s session, always work in that team\'s shared storage. A personal API key or an SDK token always uses the account\'s own allowance. The two never add up and one never lends room to the other. A file over the size limit is refused with 413 and `UPLOAD_TOO_LARGE`, and a type that is not accepted with 415 and `UPLOAD_UNSUPPORTED_TYPE`; `getUploadLimits` lists the size limit and the accepted types. A file is judged by what is in it, not by the type it is sent as. A file that is not the type it claims (a web page sent as `image/png`) is refused with 415 and `UPLOAD_UNSUPPORTED_TYPE`, and a picture sent under the wrong picture type is stored under the type it really is, which `mime_type` in the answer says. An SVG is rewritten as it is stored: script, `foreignObject`, animation and references to other addresses are taken out, it must be UTF-8 and at most 2 MB, and the stored file can be larger or smaller than the one sent. Anything that is not an image, audio or video (a PDF, for example) is served as a download rather than shown in a page. When the full storage is a Shopify store\'s team\'s, extra storage cannot be added through Shopify yet, so the message ends by saying so and what to do instead: delete files, or contact support. On a Solo plan it names the Teams plan (which holds more) and `error.details.planPageUrl` is the address of the plan page on Shopify. `error.suggestedAction` says the same in a few words, instead of the usual \"upgrade your storage plan\". Any other team, and a person\'s own workspace, get the shorter message. To upload the file for one of your managed users, send `managedUserId` (Widgetic\'s id for the user) or `managedUserExternalId` (your own identifier for the user), not both. The file stays in your account and counts against its allowance; the tag lets you list one user\'s files with `listUploads`. The managed user must be yours and active: one that is not yours, or does not exist, is refused with 404 and `MANAGED_USER_NOT_FOUND`, and one that is switched off with 409 and `MANAGED_USER_INACTIVE`, before the file is stored. The tag is set here and does not change afterwards. Called with an editor session (`createManagedUserEditorSession`), the file is always filed for the session\'s own managed user and is always media for widget content: naming another managed user is refused with 403 and `MANAGED_USER_SESSION_MISMATCH`, and `contextType`, `source`, `widgetId` and `conversationId` are ignored. A full storage allowance is refused with the same 413 and `QUOTA_STORAGE_EXCEEDED`, but the message only says that it is not available right now (not how much is stored: that is the partner\'s business) and `error.details.limit` is `storage`. An account that administers a partner with a storage destination (`setPartnerStorageDestination`) has its files stored in the partner\'s own bucket instead. Such a file takes none of the allowance, its `url` is served from the partner\'s public address, and its `storage_key` is the key in the partner\'s bucket. The file is never stored with Widgetic instead: when the destination cannot be used the upload is refused with 503 and `STORAGE_DESTINATION_UNAVAILABLE`, and when the partner\'s storage rejects the file with 502 and `STORAGE_DESTINATION_WRITE_FAILED`. Partner storage is not optional, and it does not depend on how the file arrives. A partner\'s own uploads (with its API key, an SDK token, or from the Widgetic website, the resumable route and the media library alike) and the uploads of its customers\' editor sessions are kept in the partner\'s own storage or not at all, so a partner with no destination (or one that removed it after the session was made) has them refused with 409 and `PARTNER_STORAGE_REQUIRED`; they are never stored with Widgetic. An editor session\'s browser is only told that the feature is not available right now.
|
|
79
79
|
* Upload a file
|
|
80
80
|
*/
|
|
81
|
-
|
|
81
|
+
uploadFileRaw(requestParameters: UploadFileRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<UploadResponse>>;
|
|
82
82
|
/**
|
|
83
|
-
* Stores one file for the account and returns its public address. This is how a user\'s own images, video and PDFs reach a widget\'s content. Send a `multipart/form-data` request with the file in the field named `file`. The file counts against the storage of the workspace it is uploaded in, and a full workspace is refused with 413 and `QUOTA_STORAGE_EXCEEDED`. For a person signed in on widgetic.com that is the workspace they are currently working in: inside a team, the team\'s shared storage; inside their own workspace, their own allowance. An organization API key, and a Shopify store\'s session, always work in that team\'s shared storage. A personal API key or an SDK token always uses the account\'s own allowance. The two never add up and one never lends room to the other. A file over the size limit is refused with 413 and `UPLOAD_TOO_LARGE`, and a type that is not accepted with 415 and `UPLOAD_UNSUPPORTED_TYPE`; `
|
|
83
|
+
* Stores one file for the account and returns its public address. This is how a user\'s own images, video and PDFs reach a widget\'s content. Send a `multipart/form-data` request with the file in the field named `file`. The file counts against the storage of the workspace it is uploaded in, and a full workspace is refused with 413 and `QUOTA_STORAGE_EXCEEDED`. For a person signed in on widgetic.com that is the workspace they are currently working in: inside a team, the team\'s shared storage; inside their own workspace, their own allowance. An organization API key, and a Shopify store\'s session, always work in that team\'s shared storage. A personal API key or an SDK token always uses the account\'s own allowance. The two never add up and one never lends room to the other. A file over the size limit is refused with 413 and `UPLOAD_TOO_LARGE`, and a type that is not accepted with 415 and `UPLOAD_UNSUPPORTED_TYPE`; `getUploadLimits` lists the size limit and the accepted types. A file is judged by what is in it, not by the type it is sent as. A file that is not the type it claims (a web page sent as `image/png`) is refused with 415 and `UPLOAD_UNSUPPORTED_TYPE`, and a picture sent under the wrong picture type is stored under the type it really is, which `mime_type` in the answer says. An SVG is rewritten as it is stored: script, `foreignObject`, animation and references to other addresses are taken out, it must be UTF-8 and at most 2 MB, and the stored file can be larger or smaller than the one sent. Anything that is not an image, audio or video (a PDF, for example) is served as a download rather than shown in a page. When the full storage is a Shopify store\'s team\'s, extra storage cannot be added through Shopify yet, so the message ends by saying so and what to do instead: delete files, or contact support. On a Solo plan it names the Teams plan (which holds more) and `error.details.planPageUrl` is the address of the plan page on Shopify. `error.suggestedAction` says the same in a few words, instead of the usual \"upgrade your storage plan\". Any other team, and a person\'s own workspace, get the shorter message. To upload the file for one of your managed users, send `managedUserId` (Widgetic\'s id for the user) or `managedUserExternalId` (your own identifier for the user), not both. The file stays in your account and counts against its allowance; the tag lets you list one user\'s files with `listUploads`. The managed user must be yours and active: one that is not yours, or does not exist, is refused with 404 and `MANAGED_USER_NOT_FOUND`, and one that is switched off with 409 and `MANAGED_USER_INACTIVE`, before the file is stored. The tag is set here and does not change afterwards. Called with an editor session (`createManagedUserEditorSession`), the file is always filed for the session\'s own managed user and is always media for widget content: naming another managed user is refused with 403 and `MANAGED_USER_SESSION_MISMATCH`, and `contextType`, `source`, `widgetId` and `conversationId` are ignored. A full storage allowance is refused with the same 413 and `QUOTA_STORAGE_EXCEEDED`, but the message only says that it is not available right now (not how much is stored: that is the partner\'s business) and `error.details.limit` is `storage`. An account that administers a partner with a storage destination (`setPartnerStorageDestination`) has its files stored in the partner\'s own bucket instead. Such a file takes none of the allowance, its `url` is served from the partner\'s public address, and its `storage_key` is the key in the partner\'s bucket. The file is never stored with Widgetic instead: when the destination cannot be used the upload is refused with 503 and `STORAGE_DESTINATION_UNAVAILABLE`, and when the partner\'s storage rejects the file with 502 and `STORAGE_DESTINATION_WRITE_FAILED`. Partner storage is not optional, and it does not depend on how the file arrives. A partner\'s own uploads (with its API key, an SDK token, or from the Widgetic website, the resumable route and the media library alike) and the uploads of its customers\' editor sessions are kept in the partner\'s own storage or not at all, so a partner with no destination (or one that removed it after the session was made) has them refused with 409 and `PARTNER_STORAGE_REQUIRED`; they are never stored with Widgetic. An editor session\'s browser is only told that the feature is not available right now.
|
|
84
84
|
* Upload a file
|
|
85
85
|
*/
|
|
86
|
-
|
|
86
|
+
uploadFile(requestParameters: UploadFileRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<UploadResponse>;
|
|
87
87
|
}
|
|
88
88
|
/**
|
|
89
89
|
* @export
|
|
90
90
|
*/
|
|
91
|
-
export declare const
|
|
91
|
+
export declare const UploadFileContextTypeEnum: {
|
|
92
92
|
readonly WidgetCodegen: 'widget-codegen';
|
|
93
93
|
readonly BrowserIc: 'browser-ic';
|
|
94
94
|
readonly ContentProperty: 'content-property';
|
|
95
95
|
};
|
|
96
|
-
export type
|
|
96
|
+
export type UploadFileContextTypeEnum = typeof UploadFileContextTypeEnum[keyof typeof UploadFileContextTypeEnum];
|
|
97
97
|
/**
|
|
98
98
|
* @export
|
|
99
99
|
*/
|
|
100
|
-
export declare const
|
|
100
|
+
export declare const UploadFileSourceEnum: {
|
|
101
101
|
readonly ChatUpload: 'chat-upload';
|
|
102
102
|
readonly ChatScreenshot: 'chat-screenshot';
|
|
103
103
|
readonly BrowserIcScreenshot: 'browser-ic-screenshot';
|
|
104
104
|
readonly PreviewScreenshot: 'preview-screenshot';
|
|
105
105
|
readonly FileBrowserUpload: 'file-browser-upload';
|
|
106
106
|
};
|
|
107
|
-
export type
|
|
107
|
+
export type UploadFileSourceEnum = typeof UploadFileSourceEnum[keyof typeof UploadFileSourceEnum];
|
|
108
108
|
/**
|
|
109
109
|
* @export
|
|
110
110
|
*/
|
|
111
|
-
export declare const
|
|
111
|
+
export declare const UploadFilePurposeEnum: {
|
|
112
112
|
readonly Canvas: 'canvas';
|
|
113
113
|
readonly Chat: 'chat';
|
|
114
114
|
readonly Field: 'field';
|
|
115
115
|
};
|
|
116
|
-
export type
|
|
116
|
+
export type UploadFilePurposeEnum = typeof UploadFilePurposeEnum[keyof typeof UploadFilePurposeEnum];
|