@supernova-studio/supernova-sdk-beta 2.0.32 → 2.0.38
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/build/sdk-typescript/src/core/SDKSupernova.d.ts +9 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaAI.d.ts +34 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaAssets.d.ts +7 -4
- package/build/sdk-typescript/src/core/areas/SDKAreaAutomation.d.ts +26 -7
- package/build/sdk-typescript/src/core/areas/SDKAreaDesignSystems.d.ts +19 -1
- package/build/sdk-typescript/src/core/areas/SDKAreaDocumentation.d.ts +5 -3
- package/build/sdk-typescript/src/core/areas/SDKAreaImport.d.ts +6 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaRawData.d.ts +84 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaResources.d.ts +6 -1
- package/build/sdk-typescript/src/core/data/SDKDataBridge.d.ts +4 -0
- package/build/sdk-typescript/src/core/data/SDKDataCore.d.ts +49 -12
- package/build/sdk-typescript/src/core/data/requests/SDKDataCoreAIRequests.d.ts +15 -0
- package/build/sdk-typescript/src/core/data/requests/SDKDataCoreReadRequests.d.ts +38 -6
- package/build/sdk-typescript/src/core/data/requests/SDKDataCoreWriteRequests.d.ts +461 -9
- package/build/sdk-typescript/src/core/resolvers/SDKDesignComponentGroupResolver.d.ts +5 -0
- package/build/sdk-typescript/src/core/resolvers/SDKDocsEntityItemResolver.d.ts +212 -0
- package/build/sdk-typescript/src/exports.d.ts +21 -2
- package/build/sdk-typescript/src/model/assets/SDKAsset.d.ts +24 -1
- package/build/sdk-typescript/src/model/base/SDKBrand.d.ts +1 -2
- package/build/sdk-typescript/src/model/base/SDKDesignSystemVersionStats.d.ts +11 -0
- package/build/sdk-typescript/src/model/components/SDKDesignComponent.d.ts +1 -0
- package/build/sdk-typescript/src/model/components/SDKDesignComponentPropertyDefinition.d.ts +1 -0
- package/build/sdk-typescript/src/model/components/SDKDesignComponentVariant.d.ts +1 -0
- package/build/sdk-typescript/src/model/docs/blocks/properties/SDKDocsBlockFigmaComponentProperty.d.ts +1 -0
- package/build/sdk-typescript/src/model/docs/entities/SDKDocsEntity.d.ts +6 -5
- package/build/sdk-typescript/src/model/docs/entities/SDKDocsEntityApprovalState.d.ts +2 -2
- package/build/sdk-typescript/src/model/docs/entities/SDKDocsEntityConfiguration.d.ts +1 -0
- package/build/sdk-typescript/src/model/docs/entities/SDKDocsEntityGroup.d.ts +8 -16
- package/build/sdk-typescript/src/model/docs/entities/SDKDocsEntityPage.d.ts +10 -9
- package/build/sdk-typescript/src/model/elements/SDKElementProperty.d.ts +4 -0
- package/build/sdk-typescript/src/model/elements/SDKElementPropertyOption.d.ts +1 -1
- package/build/sdk-typescript/src/model/exporters/SDKExporter.d.ts +15 -0
- package/build/sdk-typescript/src/model/exporters/SDKExporterJobDestination.d.ts +36 -0
- package/build/sdk-typescript/src/model/exporters/SDKPipeline.d.ts +27 -54
- package/build/sdk-typescript/src/model/exporters/custom_properties/SDKExporterPropertyBase.d.ts +11 -0
- package/build/sdk-typescript/src/model/exporters/custom_properties/SDKExporterPropertyBoolean.d.ts +7 -0
- package/build/sdk-typescript/src/model/exporters/custom_properties/SDKExporterPropertyDefinition.d.ts +6 -0
- package/build/sdk-typescript/src/model/exporters/custom_properties/SDKExporterPropertyEnum.d.ts +14 -0
- package/build/sdk-typescript/src/model/exporters/custom_properties/SDKExporterPropertyNumber.d.ts +7 -0
- package/build/sdk-typescript/src/model/exporters/custom_properties/SDKExporterPropertyObject.d.ts +12 -0
- package/build/sdk-typescript/src/model/exporters/custom_properties/SDKExporterPropertyString.d.ts +7 -0
- package/build/sdk-typescript/src/model/exporters/exporter_builds/SDKExportBuildResults.d.ts +2 -2
- package/build/sdk-typescript/src/model/groups/SDKAssetGroup.d.ts +4 -0
- package/build/sdk-typescript/src/model/groups/SDKDesignComponentGroup.d.ts +7 -0
- package/build/sdk-typescript/src/model/support/SDKDesignComponentOrigin.d.ts +15 -1
- package/build/sdk-typescript/src/model/support/SDKFigmaFrame.d.ts +2 -7
- package/build/sdk-typescript/src/model/support/SDKFigmaStructure.d.ts +11 -11
- package/build/sdk-typescript/src/model/support/SDKFigmaStructureDetail.d.ts +6 -29
- package/build/sdk-typescript/src/model/tokens/remote/SDKRemoteTokenModel.d.ts +1 -0
- package/build/sdk-typescript/src/model/users/SDKUser.d.ts +5 -1
- package/build/sdk-typescript/src/model/users/SDKUserProfile.d.ts +17 -0
- package/build/sdk-typescript/src/pulsar-interfaces.d.ts +1 -0
- package/build/sdk-typescript/src/tests/helpers.d.ts +2 -5
- package/build/sdk-typescript/src/tests/validators.d.ts +24 -23
- package/build/sdk-typescript/src/tools/token-preview/TokenUtilPreviewSegmentGenerator.d.ts +26 -1
- package/build/sdk-typescript/src/tools/token-preview/TokenUtilPreviewTypes.d.ts +2 -0
- package/build/sdk-typescript/src/tools/token-transform/SDKToolsTokenTransform.d.ts +2 -0
- package/build/sdk-typescript/src/utils/TokenUtils.d.ts +5 -0
- package/build/sdk-typescript/vitest.config-ci.d.ts +2 -0
- package/build/sdk-typescript/vitest.config-token-studio.d.ts +2 -0
- package/build/sdk-typescript/vitest.config.d.ts +2 -0
- package/build/supernova-sdk-typescript.js +1 -1
- package/build/supernova-sdk-typescript.js.map +1 -1
- package/package.json +12 -13
- package/build/sdk-typescript/src/core/resolvers/SDKDocsEntityMultiplayerItemResolver.d.ts +0 -7
- package/build/sdk-typescript/src/tests/Tooling/ToolDocSearch.spec.d.ts +0 -1
- package/build/sdk-typescript/src/tests/Tooling/ToolMarkdownTransform.spec.d.ts +0 -1
- /package/build/sdk-typescript/src/tests/Areas/{AreaAssets.spec.d.ts → AreaImport.spec.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/Tooling/{PluginFigmaTokens.spec.d.ts → PluginFigmaTokens.spec.token-studio.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/Tooling/{ReadTokens.spec.d.ts → ReadTokens.spec.token-studio.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/Tooling/{TokensModel.spec.d.ts → TokensModel.spec.token-studio.d.ts} +0 -0
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { AreaAI } from "./areas/SDKAreaAI";
|
|
1
2
|
import { AreaAssets } from "./areas/SDKAreaAssets";
|
|
2
3
|
import { AreaAutomation } from "./areas/SDKAreaAutomation";
|
|
3
4
|
import { AreaBrands } from "./areas/SDKAreaBrands";
|
|
@@ -10,6 +11,7 @@ import { AreaIntegrations } from "./areas/SDKAreaIntegrations";
|
|
|
10
11
|
import { AreaMe } from "./areas/SDKAreaMe";
|
|
11
12
|
import { AreaMultiplayer } from "./areas/SDKAreaMultiplayer";
|
|
12
13
|
import { AreaNetwork } from "./areas/SDKAreaNetwork";
|
|
14
|
+
import { AreaRawData } from "./areas/SDKAreaRawData";
|
|
13
15
|
import { AreaResources } from "./areas/SDKAreaResources";
|
|
14
16
|
import { AreaStorage } from "./areas/SDKAreaStorage";
|
|
15
17
|
import { AreaTokens } from "./areas/SDKAreaTokens";
|
|
@@ -63,6 +65,10 @@ export declare class Supernova {
|
|
|
63
65
|
network: AreaNetwork;
|
|
64
66
|
/** Get access to multiplayer capabilities */
|
|
65
67
|
multiplayer: AreaMultiplayer;
|
|
68
|
+
/** Get access to AI capabilities */
|
|
69
|
+
ai: AreaAI;
|
|
70
|
+
/** Get access to raw data for local-only restoration of data */
|
|
71
|
+
raw: AreaRawData;
|
|
66
72
|
/**
|
|
67
73
|
* Create new Supernova.io SDK object.
|
|
68
74
|
* @param apiKey API key to use for authentication
|
|
@@ -76,5 +82,8 @@ export declare class Supernova {
|
|
|
76
82
|
requestHook?: DataBridgeRequestHook;
|
|
77
83
|
bypassEnvFetch?: boolean;
|
|
78
84
|
proxyUrl?: string;
|
|
85
|
+
isPreview?: boolean;
|
|
86
|
+
jobId?: string;
|
|
79
87
|
});
|
|
88
|
+
get apiKeySet(): boolean;
|
|
80
89
|
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { DataCore } from "../data/SDKDataCore";
|
|
2
|
+
import { RemoteVersionIdentifier, RemoteWorkspaceVersionIdentifier } from "./SDKRemoteIdentifiers";
|
|
3
|
+
export declare class AreaAI {
|
|
4
|
+
/** Internal: Engine */
|
|
5
|
+
private dataCore;
|
|
6
|
+
constructor(dataCore: DataCore);
|
|
7
|
+
/** Generates code for the associated design system components for provided user prompt
|
|
8
|
+
* @param from - Design system to use
|
|
9
|
+
* @param prompt - Prompt to generate code for
|
|
10
|
+
* @param components - Components to generate code for
|
|
11
|
+
* @returns Forged component code
|
|
12
|
+
*/
|
|
13
|
+
forgeCode(from: RemoteVersionIdentifier, prompt: string, components: Array<any>): Promise<string>;
|
|
14
|
+
/** Reforges code for the associated design system components for provided user prompt, taking into account existing code
|
|
15
|
+
* @param from - Design system to use
|
|
16
|
+
* @param prompt - Prompt to generate code for
|
|
17
|
+
* @param components - Components to generate code for
|
|
18
|
+
* @param existingCode - Existing code to reforge
|
|
19
|
+
* @returns Reforged component code
|
|
20
|
+
*/
|
|
21
|
+
reforgeCode(from: RemoteVersionIdentifier, prompt: string, components: Array<any>, existingCode: string): Promise<string>;
|
|
22
|
+
/** Reforges code for the associated design system components for provided user prompt, taking into account existing code
|
|
23
|
+
* @param from - Design system to use
|
|
24
|
+
* @param prompt - Prompt to generate code for
|
|
25
|
+
* @param components - Components to generate code for
|
|
26
|
+
* @param existingCode - Existing code to reforge
|
|
27
|
+
* @returns Reforged component code
|
|
28
|
+
*/
|
|
29
|
+
proposeTitle(from: RemoteVersionIdentifier, firstForgeQuery: string): Promise<string>;
|
|
30
|
+
/** Answers question based on the data of design system in natural language */
|
|
31
|
+
answerQuestion(from: RemoteWorkspaceVersionIdentifier, persona: "designer" | "developer" | "code", askQuery: string): Promise<string>;
|
|
32
|
+
/** Indexes a design system so it can be asked in natural language */
|
|
33
|
+
indexDS(from: RemoteWorkspaceVersionIdentifier): Promise<string>;
|
|
34
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DTOFigmaNode, DTOFigmaNodeRenderInput } from "@supernova-studio/client";
|
|
1
|
+
import { DTOFigmaNode, DTOFigmaNodeRenderIdInput, DTOFigmaNodeRenderInput, DTOFigmaNodeV2 } from "@supernova-studio/client";
|
|
2
2
|
import { Asset } from "../../model/assets/SDKAsset";
|
|
3
3
|
import { RenderedAsset } from "../../model/assets/SDKRenderedAsset";
|
|
4
4
|
import { AssetFormat } from "../../model/enums/SDKAssetFormat";
|
|
@@ -37,7 +37,10 @@ export declare class AreaAssets {
|
|
|
37
37
|
*
|
|
38
38
|
* @returns Rendered Figma frames
|
|
39
39
|
*/
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
|
|
40
|
+
getRenderedFigmaFramesAsync(from: RemoteVersionIdentifier, nodesToRender: Array<DTOFigmaNodeRenderInput>): Promise<Array<DTOFigmaNodeV2>>;
|
|
41
|
+
/** Renders figma frames based on the source and node id. The result is a URL to the hosted image of the Figma frame that is stable across updates.
|
|
42
|
+
*
|
|
43
|
+
* @returns Rendered Figma frames
|
|
44
|
+
*/
|
|
45
|
+
getRenderedFigmaFrames(from: RemoteVersionIdentifier, framesToRender: Array<DTOFigmaNodeRenderIdInput>): Promise<Array<DTOFigmaNode>>;
|
|
43
46
|
}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
import { DTOExporterPropertyValueMap, DTOPipelineCreateBody, DTOPipelineUpdateBody } from "@supernova-studio/client";
|
|
1
2
|
import { Exporter, NewExporterPayload } from "../../model/exporters/SDKExporter";
|
|
2
|
-
import {
|
|
3
|
+
import { ExporterJobDestination } from "../../model/exporters/SDKExporterJobDestination";
|
|
4
|
+
import { Pipeline } from "../../model/exporters/SDKPipeline";
|
|
3
5
|
import { ExporterCustomBlockVariant } from "../../model/exporters/custom_blocks/SDKExporterCustomBlockVariant";
|
|
4
6
|
import { ExporterConfigurationProperty } from "../../model/exporters/custom_properties/SDKExporterConfigurationProperty";
|
|
5
7
|
import { ExportBuild } from "../../model/exporters/exporter_builds/SDKExportBuild";
|
|
@@ -18,6 +20,11 @@ export declare class AreaAutomation {
|
|
|
18
20
|
* @param versionId - Identifier of the version where the pipeline is installed
|
|
19
21
|
*/
|
|
20
22
|
getExportBuilds(workspaceId: string, versionId: string): Promise<Array<ExportBuild>>;
|
|
23
|
+
/** Fetches a single export build.
|
|
24
|
+
* @param workspaceId - Identifier of the workspace associated with the build.
|
|
25
|
+
* @param buildId - Identifier of the build.
|
|
26
|
+
*/
|
|
27
|
+
getExportBuild(workspaceId: string, buildId: string): Promise<ExportBuild>;
|
|
21
28
|
/** Fetches build logs of a specific build
|
|
22
29
|
* @param workspaceId - Identifier of the workspace where the pipeline is installed
|
|
23
30
|
* @param buildId - Identifier of the build to fetch logs for
|
|
@@ -77,28 +84,40 @@ export declare class AreaAutomation {
|
|
|
77
84
|
scheduleImportJobForFigmaSources(from: RemoteVersionIdentifier, sourceIds: Array<string>, dryRun?: boolean): Promise<ImportJob>;
|
|
78
85
|
/** Create pipeline
|
|
79
86
|
* @param workspaceId string
|
|
80
|
-
* @param
|
|
87
|
+
* @param payload
|
|
81
88
|
* @returns Pipeline
|
|
82
89
|
*/
|
|
83
|
-
createPipeline(workspaceId: string,
|
|
90
|
+
createPipeline(workspaceId: string, payload: DTOPipelineCreateBody): Promise<Pipeline>;
|
|
84
91
|
/** Update pipeline
|
|
85
|
-
* @param workspaceId string
|
|
86
|
-
* @param pipeline Pipeline
|
|
87
92
|
* @returns Pipeline
|
|
93
|
+
* @param designSystemId
|
|
94
|
+
* @param pipelineId
|
|
95
|
+
* @param payload
|
|
88
96
|
*/
|
|
89
|
-
updatePipeline(
|
|
97
|
+
updatePipeline(designSystemId: string, pipelineId: string, payload: DTOPipelineUpdateBody): Promise<Pipeline>;
|
|
90
98
|
/**
|
|
91
99
|
* Run pipeline
|
|
92
100
|
* @param workspaceId string
|
|
93
101
|
* @param designSystemVersionId string
|
|
94
102
|
* @param pipelineId string
|
|
95
103
|
*/
|
|
96
|
-
runPipeline(workspaceId: string, designSystemVersionId: string, pipelineId: string): Promise<
|
|
104
|
+
runPipeline(workspaceId: string, designSystemVersionId: string, pipelineId: string): Promise<ExportBuild>;
|
|
97
105
|
/** Create exporter
|
|
98
106
|
* @param workspaceId string
|
|
99
107
|
* @param payload NewExporterPayload
|
|
100
108
|
* @returns Exporter
|
|
101
109
|
*/
|
|
102
110
|
createExporter(workspaceId: string, payload: NewExporterPayload): Promise<Exporter>;
|
|
111
|
+
/** Create exporter build
|
|
112
|
+
* @param workspaceId string
|
|
113
|
+
* @param designSystemId string
|
|
114
|
+
* @param versionId string
|
|
115
|
+
* @param exporterId string
|
|
116
|
+
* @param destinations
|
|
117
|
+
* @param brandId
|
|
118
|
+
* @param themePersistentIds
|
|
119
|
+
* @param exporterConfigurationProperties
|
|
120
|
+
*/
|
|
121
|
+
createExporterBuild(workspaceId: string, designSystemId: string, versionId: string, exporterId: string, destinations: ExporterJobDestination, brandId: string | undefined, themePersistentIds: Array<string> | undefined, exporterConfigurationProperties: DTOExporterPropertyValueMap | undefined): Promise<ExportBuild>;
|
|
103
122
|
deletePipeline(workspaceId: string, pipelineId: string): Promise<void>;
|
|
104
123
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DTODocumentationLinkPreviewRequest, DTODocumentationPageApprovalStateChangeInput } from "@supernova-studio/client";
|
|
1
|
+
import { DTODocumentationLinkPreviewRequest, DTODocumentationPageApprovalStateChangeInput, DTOPageRedirectCreateBody, DTOPageRedirectUpdateBody } from "@supernova-studio/client";
|
|
2
2
|
import { DesignSystemInvite, DesignSystemInviteUpdate, DesignSystemMemberUpdate, DesignSystemPendingMemberInvite, DesignSystemUserInvitation } from "@supernova-studio/model";
|
|
3
3
|
import { DesignSystem, DesignSystemAccessMode, DesignSystemSwitcher } from "../../model/base/SDKDesignSystem";
|
|
4
4
|
import { DesignSystemContactList } from "../../model/base/SDKDesignSystemContactList";
|
|
@@ -24,6 +24,13 @@ export declare class AreaDesignSystems {
|
|
|
24
24
|
* @returns custom domain information
|
|
25
25
|
*/
|
|
26
26
|
designSystemCustomDomain(designSystemId: string): Promise<CustomDomain>;
|
|
27
|
+
/** Fetches design system stats
|
|
28
|
+
* @param dsId - Design system ID
|
|
29
|
+
* @param versionId - Version ID
|
|
30
|
+
* @param brandId - Brand ID to filter by
|
|
31
|
+
* @returns Design system stats
|
|
32
|
+
*/
|
|
33
|
+
designSystemStats(dsId: string, versionId: string, brandId?: string): Promise<import("../../model/base/SDKDesignSystemVersionStats").DesignSystemVersionStats>;
|
|
27
34
|
/** Fetches specific design system's memberships
|
|
28
35
|
* @param designSystemId - Design system's identifier
|
|
29
36
|
* @returns Design system's memberships
|
|
@@ -151,4 +158,15 @@ export declare class AreaDesignSystems {
|
|
|
151
158
|
* @returns nothing
|
|
152
159
|
*/
|
|
153
160
|
startSslGenerationForCustomDomain(designSystemId: string): Promise<void>;
|
|
161
|
+
getPageRedirects(designSystemId: string): Promise<{
|
|
162
|
+
path: string;
|
|
163
|
+
id: string;
|
|
164
|
+
createdAt: Date;
|
|
165
|
+
updatedAt: Date;
|
|
166
|
+
designSystemId: string;
|
|
167
|
+
pagePersistentId: string;
|
|
168
|
+
}[]>;
|
|
169
|
+
createPageRedirect(designSystemId: string, body: DTOPageRedirectCreateBody): Promise<void>;
|
|
170
|
+
updatePageRedirect(designSystemId: string, redirectId: string, body: DTOPageRedirectUpdateBody): Promise<void>;
|
|
171
|
+
deletePageRedirect(designSystemId: string, redirectId: string): Promise<void>;
|
|
154
172
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DTOCreateDocumentationGroupInput, DTOCreateDocumentationPageInputV2, DTOUpdateDocumentationGroupInput, DTOUpdateDocumentationPageInputV2, DTODuplicateDocumentationGroupInput, DTODuplicateDocumentationPageInputV2, DTODeleteDocumentationGroupInput, DTOMoveDocumentationPageInputV2, DTOMoveDocumentationGroupInput, DTOCreateDocumentationTabInput, DTODocumentationPageAnchor, DTODesignElementsDataDiffResponse, DTOPublishDocumentationRequest } from "@supernova-studio/client";
|
|
1
|
+
import { DTOCreateDocumentationGroupInput, DTOCreateDocumentationPageInputV2, DTOUpdateDocumentationGroupInput, DTOUpdateDocumentationPageInputV2, DTODuplicateDocumentationGroupInput, DTODuplicateDocumentationPageInputV2, DTODeleteDocumentationGroupInput, DTOMoveDocumentationPageInputV2, DTOMoveDocumentationGroupInput, DTOCreateDocumentationTabInput, DTODocumentationPageAnchor, DTODesignElementsDataDiffResponse, DTOPublishDocumentationRequest, DTOElementActionInput, DTOElementActionOutput } from "@supernova-studio/client";
|
|
2
2
|
import { DocumentationLegacy, DocumentationLegacyModel } from "../../model/base/SDKDocumentationLegacy";
|
|
3
3
|
import { DocsBlockDefinition } from "../../model/docs/blocks/definition/SDKDocsBlockDefinition";
|
|
4
4
|
import { DocsBlock } from "../../model/docs/blocks/usage/SDKDocsBlock";
|
|
@@ -67,6 +67,8 @@ export declare class AreaDocumentation {
|
|
|
67
67
|
* @returns Newly created documentation page
|
|
68
68
|
*/
|
|
69
69
|
createDocumentationPage(from: RemoteWorkspaceVersionIdentifier, payload: Omit<DTOCreateDocumentationPageInputV2, "persistentId">): Promise<string>;
|
|
70
|
+
/** General element action */
|
|
71
|
+
elementAction(from: RemoteWorkspaceVersionIdentifier, payload: DTOElementActionInput): Promise<DTOElementActionOutput>;
|
|
70
72
|
/** Creates a documentation group within documentation group
|
|
71
73
|
* @param from - Remote version to fetch from
|
|
72
74
|
* @param parentItemPersistentId - Peristent ID of the parent group
|
|
@@ -155,9 +157,9 @@ export declare class AreaDocumentation {
|
|
|
155
157
|
* @param from - Remote version to fetch from
|
|
156
158
|
* @param idInVersion - id of page or tab to be duplicated
|
|
157
159
|
* @param newPersistentId - suggested persistent id of a new group or tabbed page
|
|
158
|
-
* @returns
|
|
160
|
+
* @returns duplicated group persistent id
|
|
159
161
|
*/
|
|
160
|
-
duplicateDocumentationGroupOrTabbedPage(from: RemoteWorkspaceVersionIdentifier, payload: Omit<DTODuplicateDocumentationGroupInput, "persistentId">): Promise<
|
|
162
|
+
duplicateDocumentationGroupOrTabbedPage(from: RemoteWorkspaceVersionIdentifier, payload: Omit<DTODuplicateDocumentationGroupInput, "persistentId">): Promise<string>;
|
|
161
163
|
/** Ungroups a documentation group
|
|
162
164
|
* @param from - Remote version to fetch from
|
|
163
165
|
* @param idInVersion - id of a group
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { DTODesignSystem } from "@supernova-studio/client";
|
|
2
|
+
import { Asset } from "../../model/assets/SDKAsset";
|
|
3
|
+
import { Brand, BrandRemoteModel } from "../../model/base/SDKBrand";
|
|
4
|
+
import { DesignSystem } from "../../model/base/SDKDesignSystem";
|
|
5
|
+
import { DesignSystemVersion, DesignSystemVersionRemoteModel } from "../../model/base/SDKDesignSystemVersion";
|
|
6
|
+
import { Component, ComponentRemoteModel } from "../../model/components/SDKComponent";
|
|
7
|
+
import { DesignComponentRemoteModel } from "../../model/components/SDKDesignComponent";
|
|
8
|
+
import { ElementDataView, ElementDataViewRemoteModel } from "../../model/elements/SDKElementDataView";
|
|
9
|
+
import { ElementProperty, ElementPropertyRemoteModel } from "../../model/elements/SDKElementProperty";
|
|
10
|
+
import { ElementPropertyValue, ElementPropertyValueRemoteModel } from "../../model/elements/values/SDKElementPropertyValue";
|
|
11
|
+
import { AssetGroup } from "../../model/groups/SDKAssetGroup";
|
|
12
|
+
import { ComponentGroup, ComponentGroupRemoteModel } from "../../model/groups/SDKComponentGroup";
|
|
13
|
+
import { DesignComponentGroupRemoteModel } from "../../model/groups/SDKDesignComponentGroup";
|
|
14
|
+
import { TokenGroup, TokenGroupRemoteModel } from "../../model/groups/SDKTokenGroup";
|
|
15
|
+
import { Membership, MembershipRemoteModel } from "../../model/membership/SDKMembership";
|
|
16
|
+
import { Source, SourceRemoteModel } from "../../model/support/SDKSource";
|
|
17
|
+
import { Token } from "../../model/tokens/SDKToken";
|
|
18
|
+
import { TokenRemoteModel } from "../../model/tokens/remote/SDKRemoteTokenModel";
|
|
19
|
+
import { DataCore } from "../data/SDKDataCore";
|
|
20
|
+
export declare class AreaRawData {
|
|
21
|
+
/** Internal: Engine */
|
|
22
|
+
private dataCore;
|
|
23
|
+
constructor(dataCore: DataCore);
|
|
24
|
+
/** Fetches raw data necessary for construction of components */
|
|
25
|
+
getRawComponentModelData(designSystemId: string, versionId: string): Promise<Array<ComponentRemoteModel>>;
|
|
26
|
+
/** Fetches raw data necessary for component groups */
|
|
27
|
+
getRawComponentGroupModelData(designSystemId: string, versionId: string): Promise<Array<ComponentGroupRemoteModel>>;
|
|
28
|
+
/** Fetches raw data necessary for assets */
|
|
29
|
+
getRawAssetModelData(designSystemId: string, versionId: string): Promise<Array<DesignComponentRemoteModel>>;
|
|
30
|
+
/** Fetches raw data necessary for asset groups */
|
|
31
|
+
getRawAssetGroupModelData(designSystemId: string, versionId: string): Promise<Array<DesignComponentGroupRemoteModel>>;
|
|
32
|
+
/** Fetches raw data necessary for tokens */
|
|
33
|
+
getRawTokenModelData(designSystemId: string, versionId: string): Promise<Array<TokenRemoteModel>>;
|
|
34
|
+
/** Fetches raw data necessary for token groups */
|
|
35
|
+
getRawTokenGroupModelData(designSystemId: string, versionId: string): Promise<Array<TokenGroupRemoteModel>>;
|
|
36
|
+
/** Fetches raw data necessary for elements */
|
|
37
|
+
getRawElementModelData(designSystemId: string, versionId: string): Promise<{
|
|
38
|
+
propertyValues: Array<ElementPropertyValueRemoteModel>;
|
|
39
|
+
propertyViews: Array<ElementDataViewRemoteModel>;
|
|
40
|
+
propertyDefinitions: Array<ElementPropertyRemoteModel>;
|
|
41
|
+
}>;
|
|
42
|
+
/** Fetches raw source data */
|
|
43
|
+
getRawSourceModelData(designSystemId: string): Promise<Array<SourceRemoteModel>>;
|
|
44
|
+
/** Fetches raw membership */
|
|
45
|
+
getRawMembershipModelData(userId: string): Promise<Array<MembershipRemoteModel>>;
|
|
46
|
+
/** Fetches raw design systems */
|
|
47
|
+
getRawDesignSystemModelData(workspaceId: string): Promise<Array<DTODesignSystem>>;
|
|
48
|
+
/** Fetches raw versions */
|
|
49
|
+
getRawVersionModelData(designSystemId: string): Promise<Array<DesignSystemVersionRemoteModel>>;
|
|
50
|
+
/** Fetches raw brands */
|
|
51
|
+
getRawBrandModelData(designSystemId: string, versionId: string): Promise<Array<BrandRemoteModel>>;
|
|
52
|
+
/** Builds components from raw data */
|
|
53
|
+
buildComponentsFromRaw(rawData: Array<ComponentRemoteModel>, properties: Array<ElementProperty>, propertyValues: Array<ElementPropertyValue>): Array<Component>;
|
|
54
|
+
/** Build component groups */
|
|
55
|
+
buildComponentGroupsFromRaw(rawData: Array<ComponentGroupRemoteModel>, components: Array<Component>): Array<ComponentGroup>;
|
|
56
|
+
/** Builds assets from raw data */
|
|
57
|
+
buildAssetsFromRaw(rawData: Array<DesignComponentRemoteModel>, sources: Array<Source>): Array<Asset>;
|
|
58
|
+
/** Build asset groups */
|
|
59
|
+
buildAssetGroupsFromRaw(rawData: Array<DesignComponentGroupRemoteModel>, assets: Array<Asset>): Array<AssetGroup>;
|
|
60
|
+
/** Builds tokens from raw data */
|
|
61
|
+
buildTokensFromRaw(rawData: Array<TokenRemoteModel>, properties: Array<ElementProperty>, propertyValues: Array<ElementPropertyValue>, propertyViews: Array<ElementDataView>, tokenGroups: Array<TokenGroup>, sources: Array<Source>, designSystemId: string, versionId: string): Array<Token>;
|
|
62
|
+
/** Build token groups */
|
|
63
|
+
buildTokenGroupsFromRaw(rawData: Array<TokenGroupRemoteModel>): Array<TokenGroup>;
|
|
64
|
+
/** Builds elements from raw data */
|
|
65
|
+
buildElementsFromRaw(rawData: {
|
|
66
|
+
propertyValues: Array<ElementPropertyValueRemoteModel>;
|
|
67
|
+
propertyViews: Array<ElementDataViewRemoteModel>;
|
|
68
|
+
propertyDefinitions: Array<ElementPropertyRemoteModel>;
|
|
69
|
+
}): {
|
|
70
|
+
propertyValues: Array<ElementPropertyValue>;
|
|
71
|
+
propertyViews: Array<ElementDataView>;
|
|
72
|
+
propertyDefinitions: Array<ElementProperty>;
|
|
73
|
+
};
|
|
74
|
+
/** Build sources */
|
|
75
|
+
buildSourcesFromRaw(rawData: Array<SourceRemoteModel>): Array<Source>;
|
|
76
|
+
/** Builds memberships */
|
|
77
|
+
buildMembershipsFromRaw(rawData: Array<MembershipRemoteModel>): Array<Membership>;
|
|
78
|
+
/** Builds design systems */
|
|
79
|
+
buildDesignSystemsFromRaw(rawData: Array<DTODesignSystem>): Array<DesignSystem>;
|
|
80
|
+
/** Builds versions */
|
|
81
|
+
buildVersionsFromRaw(rawData: Array<DesignSystemVersionRemoteModel>): Array<DesignSystemVersion>;
|
|
82
|
+
/** Builds brands */
|
|
83
|
+
buildBrandsFromRaw(rawData: Array<BrandRemoteModel>): Array<Brand>;
|
|
84
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DTOFigmaNode } from "@supernova-studio/client";
|
|
1
|
+
import { DTOFigmaNode, DTOFigmaNodeV2 } from "@supernova-studio/client";
|
|
2
2
|
import { DocsImageRef, ResourceAsset, ResourceFont } from "../../exports";
|
|
3
3
|
import { DataCore } from "../data/SDKDataCore";
|
|
4
4
|
import { RemoteVersionIdentifier } from "./SDKRemoteIdentifiers";
|
|
@@ -21,6 +21,11 @@ export declare class AreaResources {
|
|
|
21
21
|
* @returns All font resources in the specified version
|
|
22
22
|
*/
|
|
23
23
|
getFigmaFrames(from: RemoteVersionIdentifier): Promise<Array<DTOFigmaNode>>;
|
|
24
|
+
/** Fetches all Figma frames that were rendered font resources in the version (V2 of the API)
|
|
25
|
+
* @param from - Remote version to fetch from
|
|
26
|
+
* @returns All font resources in the specified version
|
|
27
|
+
*/
|
|
28
|
+
getFigmaFramesV2(from: RemoteVersionIdentifier): Promise<Array<DTOFigmaNodeV2>>;
|
|
24
29
|
/**
|
|
25
30
|
* @param from - Remote version to fetch from
|
|
26
31
|
* @param frameReferenceId - Unique stable identifier of the Figma frame (Supernova id, not Figma id)
|
|
@@ -23,6 +23,8 @@ export type DataBridgeConfiguration = {
|
|
|
23
23
|
debugRequestObserver?: DebugRequestObserver | null;
|
|
24
24
|
debugResponseObserver?: DebugResponseObserver | null;
|
|
25
25
|
proxyUrl?: string | null;
|
|
26
|
+
jobId?: string | null;
|
|
27
|
+
isPreview?: boolean;
|
|
26
28
|
};
|
|
27
29
|
export declare class DataBridge {
|
|
28
30
|
authToken: string;
|
|
@@ -30,6 +32,8 @@ export declare class DataBridge {
|
|
|
30
32
|
apiVersion: string;
|
|
31
33
|
target: string | null;
|
|
32
34
|
bypassEnvFetch: boolean;
|
|
35
|
+
isPreview: boolean;
|
|
36
|
+
jobId: string | null;
|
|
33
37
|
proxyUrl: string | undefined;
|
|
34
38
|
requestHook: DataBridgeRequestHook | null;
|
|
35
39
|
debugRequestObserver: DebugRequestObserver | null;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { DTOCreateDocumentationGroupInput, DTOCreateDocumentationPageInputV2, DTOCreateDocumentationTabInput, DTODeleteDocumentationGroupInput, DTODeleteDocumentationPageInputV2, DTODeleteDocumentationTabGroupInput, DTODesignElementsDataDiffResponse, DTODocumentationLinkPreviewRequest, DTODocumentationPageAnchor, DTODocumentationPageApprovalStateChangeInput, DTODuplicateDocumentationGroupInput, DTODuplicateDocumentationPageInputV2, DTOFigmaNode, DTOFigmaNodeRenderInput, DTOMoveDocumentationGroupInput, DTOMoveDocumentationPageInputV2, DTOPublishDocumentationRequest, DTORestoreDocumentationGroupInput, DTORestoreDocumentationPageInput, DTOUpdateDocumentationGroupInput, DTOUpdateDocumentationPageInputV2 } from "@supernova-studio/client";
|
|
1
|
+
import { DTOCreateDocumentationGroupInput, DTOCreateDocumentationPageInputV2, DTOCreateDocumentationTabInput, DTODeleteDocumentationGroupInput, DTODeleteDocumentationPageInputV2, DTODeleteDocumentationTabGroupInput, DTODesignElementsDataDiffResponse, DTODocumentationLinkPreviewRequest, DTODocumentationPageAnchor, DTODocumentationPageApprovalStateChangeInput, DTODuplicateDocumentationGroupInput, DTODuplicateDocumentationPageInputV2, DTOElementActionInput, DTOExporterPropertyValueMap, DTOFigmaNode, DTOFigmaNodeRenderIdInput, DTOFigmaNodeRenderInput, DTOFigmaNodeV2, DTOMoveDocumentationGroupInput, DTOMoveDocumentationPageInputV2, DTOPageRedirectCreateBody, DTOPageRedirectUpdateBody, DTOPipelineCreateBody, DTOPipelineUpdateBody, DTOPublishDocumentationRequest, DTORestoreDocumentationGroupInput, DTORestoreDocumentationPageInput, DTOUpdateDocumentationGroupInput, DTOUpdateDocumentationPageInputV2 } from "@supernova-studio/client";
|
|
2
2
|
import { DesignSystemInvite, DesignSystemInviteUpdate, DesignSystemMemberUpdate, DesignSystemPendingMemberInvite, DesignSystemUserInvitation } from "@supernova-studio/model";
|
|
3
|
-
import { DesignSystemAccessMode, DocsBlockDefinition, ExportBuildStatus, ResourceFont, TokenThemeOverrideTranserObject, UserRole } from "../../exports";
|
|
3
|
+
import { DesignSystemAccessMode, DocsBlockDefinition, ExportBuildStatus, ExporterJobDestination, ResourceFont, TokenThemeOverrideTranserObject, UserRole } from "../../exports";
|
|
4
4
|
import { Acl } from "../../model/acl/SDKAcl";
|
|
5
5
|
import { Asset } from "../../model/assets/SDKAsset";
|
|
6
6
|
import { RenderedAsset } from "../../model/assets/SDKRenderedAsset";
|
|
@@ -11,6 +11,7 @@ import { DesignSystemCollection } from "../../model/base/SDKDesignSystemCollecti
|
|
|
11
11
|
import { DesignSystemContactList } from "../../model/base/SDKDesignSystemContactList";
|
|
12
12
|
import { DesignSystemMemberList } from "../../model/base/SDKDesignSystemMemberList";
|
|
13
13
|
import { DesignSystemVersion, DesignSystemVersionCreate, DesignSystemVersionCreationJob, DesignSystemVersionUpdateModel } from "../../model/base/SDKDesignSystemVersion";
|
|
14
|
+
import { DesignSystemVersionStats } from "../../model/base/SDKDesignSystemVersionStats";
|
|
14
15
|
import { DocumentationLegacy, DocumentationLegacyModel } from "../../model/base/SDKDocumentationLegacy";
|
|
15
16
|
import { Component } from "../../model/components/SDKComponent";
|
|
16
17
|
import { DesignComponent } from "../../model/components/SDKDesignComponent";
|
|
@@ -25,7 +26,7 @@ import { DocumentationEnvironment } from "../../model/enums/SDKDocumentationEnvi
|
|
|
25
26
|
import { TokenType } from "../../model/enums/SDKTokenType";
|
|
26
27
|
import { AzurePersonalAccessTokenConnectionPayload, PersonalAccessTokenConnectionPayload } from "../../model/exporters/SDKConnections";
|
|
27
28
|
import { Exporter, ExporterProvider, NewExporterPayload } from "../../model/exporters/SDKExporter";
|
|
28
|
-
import {
|
|
29
|
+
import { Pipeline } from "../../model/exporters/SDKPipeline";
|
|
29
30
|
import { ExporterCustomBlock } from "../../model/exporters/custom_blocks/SDKExporterCustomBlock";
|
|
30
31
|
import { ExporterCustomBlockVariant } from "../../model/exporters/custom_blocks/SDKExporterCustomBlockVariant";
|
|
31
32
|
import { ExporterConfigurationProperty } from "../../model/exporters/custom_properties/SDKExporterConfigurationProperty";
|
|
@@ -70,28 +71,40 @@ import { GitProvidersOrganizations } from "../../model/workspaces/integrations/G
|
|
|
70
71
|
import { GitProvidersProjects } from "../../model/workspaces/integrations/GitProvidersProjects";
|
|
71
72
|
import { GitProvidersRepositories } from "../../model/workspaces/integrations/GitProvidersRepositories";
|
|
72
73
|
import { ComponentUpdateTransactionData, TokenUpdateTransactionData } from "../areas/SDKAreaBulkOperations";
|
|
74
|
+
import { DataCoreReadRequests } from "./requests/SDKDataCoreReadRequests";
|
|
73
75
|
import { RenderedAssetRequestSettings } from "./requests/SDKDataCoreRenderRequests";
|
|
74
76
|
import { DataBridge } from "./SDKDataBridge";
|
|
75
77
|
import { RequestInfo, RequestInit, Response } from "node-fetch";
|
|
76
78
|
export declare class DataCore {
|
|
77
79
|
/** Read part of the network calls */
|
|
78
|
-
|
|
80
|
+
read: DataCoreReadRequests;
|
|
79
81
|
/** Write part of the network calls */
|
|
80
82
|
private write;
|
|
81
83
|
/** Asset generation part of the network calls */
|
|
82
84
|
private render;
|
|
85
|
+
/** AI */
|
|
86
|
+
private ai;
|
|
83
87
|
/** Bridge */
|
|
84
88
|
private bridge;
|
|
85
89
|
constructor(bridge: DataBridge);
|
|
86
90
|
/** Only for internal functionality */
|
|
87
91
|
getBridgeInternal(): DataBridge;
|
|
88
92
|
fetch(url: RequestInfo, init?: RequestInit): Promise<Response>;
|
|
89
|
-
dataThroughCorsProxy(urlToRalay: string): Promise<ArrayBuffer | undefined>;
|
|
90
93
|
bootstrapData(preferredWorkspaceId?: string, preferredDesignSystemId?: string, preferredVersionId?: string, preferredBrandId?: string): Promise<BootstrapData>;
|
|
91
94
|
/** Remote: Get single-use multiplayer token */
|
|
92
95
|
multiplayerToken(room: string | undefined): Promise<{
|
|
93
96
|
token: string;
|
|
94
97
|
}>;
|
|
98
|
+
/** Remote: Forges code based on user prompt */
|
|
99
|
+
forgeCode(designSystemId: string, versionId: string, prompt: string, components: Array<any>): Promise<string>;
|
|
100
|
+
/** Remote: Reforges code based on user prompt */
|
|
101
|
+
reforgeCode(designSystemId: string, versionId: string, prompt: string, components: Array<any>, existingCode: string): Promise<string>;
|
|
102
|
+
/** Remote: Proposes title for generated code */
|
|
103
|
+
proposeTitle(designSystemId: string, versionId: string, firstForgeQuery: string): Promise<string>;
|
|
104
|
+
/** Remote: Answers question based on the data of design system in natural language */
|
|
105
|
+
answerQuestion(workspaceId: string, designSystemId: string, versionId: string, persona: "designer" | "developer" | "code", askQuery: string): Promise<string>;
|
|
106
|
+
/** Remote: Index a design system so it can be asked in natural language */
|
|
107
|
+
indexDS(workspaceId: string, designSystemId: string, versionId: string): Promise<string>;
|
|
95
108
|
/** Remote: Get information about currently logged in user */
|
|
96
109
|
currentUser(): Promise<User>;
|
|
97
110
|
/** Remote: Get information about a specific user */
|
|
@@ -188,6 +201,8 @@ export declare class DataCore {
|
|
|
188
201
|
}>;
|
|
189
202
|
/** Create a page within documentation */
|
|
190
203
|
createDocumentationPage(designSystemId: string, versionId: string, payload: Omit<DTOCreateDocumentationPageInputV2, "persistentId">): Promise<string>;
|
|
204
|
+
/** General element action */
|
|
205
|
+
elementAction(designSystemId: string, versionId: string, data: DTOElementActionInput): Promise<any>;
|
|
191
206
|
/** Update page approval state */
|
|
192
207
|
updateApprovalState(designSystemId: string, versionId: string, payload: DTODocumentationPageApprovalStateChangeInput): Promise<string>;
|
|
193
208
|
/** Update design system's access mode and, if switching to invite-only, also the member list */
|
|
@@ -292,12 +307,19 @@ export declare class DataCore {
|
|
|
292
307
|
/** Render assets as PNG, SVG, PDF, or combinations of it */
|
|
293
308
|
renderedAssets(designSystemId: string, versionId: string, assets: Array<Asset>, groups: Array<AssetGroup>, settings: RenderedAssetRequestSettings): Promise<Array<RenderedAsset>>;
|
|
294
309
|
/** Render Figma frames */
|
|
295
|
-
renderedFigmaFrames(designSystemId: string, versionId: string, payload: Array<
|
|
310
|
+
renderedFigmaFrames(designSystemId: string, versionId: string, payload: Array<DTOFigmaNodeRenderIdInput>): Promise<Array<DTOFigmaNode>>;
|
|
311
|
+
/** Render Figma frames async */
|
|
312
|
+
renderedFigmaFramesAsync(designSystemId: string, versionId: string, payload: Array<DTOFigmaNodeRenderInput>): Promise<Array<DTOFigmaNodeV2>>;
|
|
296
313
|
/** Fetches all Figma frames that were rendered under specific version
|
|
297
314
|
* @param from - Remote version to fetch from
|
|
298
315
|
* @returns All Figma frames in the specified version (only rendered, for documentation etc.)
|
|
299
316
|
*/
|
|
300
317
|
figmaFrames(designSystemId: string, versionId: string): Promise<Array<DTOFigmaNode>>;
|
|
318
|
+
/** Fetches all Figma frames that were rendered under specific version (V2 of the API)
|
|
319
|
+
* @param from - Remote version to fetch from
|
|
320
|
+
* @returns All Figma frames in the specified version (only rendered, for documentation etc.)
|
|
321
|
+
*/
|
|
322
|
+
figmaFramesV2(designSystemId: string, versionId: string): Promise<Array<DTOFigmaNodeV2>>;
|
|
301
323
|
/** Retrieve the main documentation object through which all docs data can be accessed */
|
|
302
324
|
documentation(workspaceId: string, designSystemId: string, versionId: string): Promise<DocumentationLegacy>;
|
|
303
325
|
getDocumentationStructure(designSystemId: string, versionId: string): Promise<(DocsEntityPageModel | DocsEntityGroupModel)[]>;
|
|
@@ -331,9 +353,9 @@ export declare class DataCore {
|
|
|
331
353
|
/** Delete any multiple resources */
|
|
332
354
|
deleteResources(designSystemId: string, versionId: string, resourceIds: string[]): Promise<void>;
|
|
333
355
|
pipelines(workspaceId: string, designSystemId?: string): Promise<Array<Pipeline>>;
|
|
334
|
-
createPipeline(workspaceId: string,
|
|
335
|
-
updatePipeline(
|
|
336
|
-
runPipeline(workspaceId: string, designSystemVersionId: string, pipelineId: string): Promise<
|
|
356
|
+
createPipeline(workspaceId: string, payload: DTOPipelineCreateBody): Promise<Pipeline>;
|
|
357
|
+
updatePipeline(designSystemId: string, pipelineId: string, payload: DTOPipelineUpdateBody): Promise<Pipeline>;
|
|
358
|
+
runPipeline(workspaceId: string, designSystemVersionId: string, pipelineId: string): Promise<ExportBuild>;
|
|
337
359
|
deletePipeline(workspaceId: string, pipelineId: string): Promise<void>;
|
|
338
360
|
/** Download information about current exporter custom blocks and retrieve them resolved */
|
|
339
361
|
documentationExporterCustomBlocks(designSystemId: string, versionId: string): Promise<Array<ExporterCustomBlock>>;
|
|
@@ -365,10 +387,12 @@ export declare class DataCore {
|
|
|
365
387
|
/** Pull updates for exporter */
|
|
366
388
|
pullLatestExporter(workspaceId: string, exporterId: string): Promise<Exporter>;
|
|
367
389
|
exportBuilds(workspaceId: string, versionId: string): Promise<Array<ExportBuild>>;
|
|
368
|
-
|
|
390
|
+
exportBuild(workspaceId: string, buildId: string): Promise<ExportBuild>;
|
|
369
391
|
/** Download information about documentation builds and retrieve it resolved */
|
|
370
392
|
documentationBuilds(workspaceId: string, versionId: string, environment: DocumentationEnvironment, status?: ExportBuildStatus, createdByUserId?: string, limit?: number): Promise<Array<ExportBuild>>;
|
|
371
393
|
buildLogs(workspaceId: string, buildId: string): Promise<Array<ExportBuildResultLog>>;
|
|
394
|
+
/** Create a new exporter build */
|
|
395
|
+
createExporterBuild(workspaceId: string, designSystemId: string, versionId: string, exporterId: string, destinations: ExporterJobDestination, brandId: string | undefined, themePersistentIds: Array<string> | undefined, exporterConfigurationProperties: DTOExporterPropertyValueMap | undefined): Promise<ExportBuild>;
|
|
372
396
|
workspaceProductFeatures(workspaceId: string): Promise<SubscriptionProductFeatures>;
|
|
373
397
|
/** Download information about a single workspace and retrieve it resolved */
|
|
374
398
|
workspace(workspaceId: string): Promise<Workspace>;
|
|
@@ -503,6 +527,8 @@ export declare class DataCore {
|
|
|
503
527
|
deleteDesignSystem(designSystemId: string): Promise<void>;
|
|
504
528
|
/** Download information about a custom domain */
|
|
505
529
|
designSystemCustomDomain(designSystemId: string): Promise<CustomDomain>;
|
|
530
|
+
/** Get design system stats */
|
|
531
|
+
designSystemStats(dsId: string, versionId: string, brandId?: string): Promise<DesignSystemVersionStats>;
|
|
506
532
|
/** Download information about a desing system source within a design system design and retrieve it resolved */
|
|
507
533
|
designSystemSource(designSystemId: string, sourceId: string): Promise<Source>;
|
|
508
534
|
/** Download information about all design system sources within a design system design and retrieve it resolved */
|
|
@@ -511,8 +537,8 @@ export declare class DataCore {
|
|
|
511
537
|
designSystemMemberList(designSystemId: string): Promise<DesignSystemMemberList>;
|
|
512
538
|
/** Download information about design system's contacts */
|
|
513
539
|
designSystemContacts(designSystemId: string): Promise<DesignSystemContactList>;
|
|
514
|
-
getFigmaNodeStructures(designSystemId: string
|
|
515
|
-
getFigmaNodeStructureDetail(designSystemId: string,
|
|
540
|
+
getFigmaNodeStructures(designSystemId: string): Promise<Array<FigmaStructure>>;
|
|
541
|
+
getFigmaNodeStructureDetail(designSystemId: string, figmaStructureId: string): Promise<FigmaStructureDetail>;
|
|
516
542
|
deleteFigmaSource(designSystemId: string, sourceId: string): Promise<void>;
|
|
517
543
|
linkFigmaSource(designSystemId: string, brandId: string, url: string, options: {
|
|
518
544
|
scopes: {
|
|
@@ -558,4 +584,15 @@ export declare class DataCore {
|
|
|
558
584
|
readKeyValueStorageData(designSystemId: string, key: string): Promise<string | object | undefined>;
|
|
559
585
|
setKeyValueStorageData(designSystemId: string, key: string, value: string | object): Promise<void>;
|
|
560
586
|
unsetKeyValueStorageData(designSystemId: string, key: string): Promise<void>;
|
|
587
|
+
getPageRedirects(designSystemId: string): Promise<{
|
|
588
|
+
path: string;
|
|
589
|
+
id: string;
|
|
590
|
+
createdAt: Date;
|
|
591
|
+
updatedAt: Date;
|
|
592
|
+
designSystemId: string;
|
|
593
|
+
pagePersistentId: string;
|
|
594
|
+
}[]>;
|
|
595
|
+
createPageRedirect(designSystemId: string, body: DTOPageRedirectCreateBody): Promise<void>;
|
|
596
|
+
updatePageRedirect(designSystemId: string, redirectId: string, body: DTOPageRedirectUpdateBody): Promise<void>;
|
|
597
|
+
deletePageRedirect(designSystemId: string, redirectId: string): Promise<void>;
|
|
561
598
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { DataBridge } from "../SDKDataBridge";
|
|
2
|
+
export declare class DataCoreAIRequests {
|
|
3
|
+
private bridge;
|
|
4
|
+
constructor(bridge: DataBridge);
|
|
5
|
+
/** Remote: Forges code based on user prompt */
|
|
6
|
+
forgeCode(designSystemId: string, versionId: string, prompt: string, components: Array<any>): Promise<string>;
|
|
7
|
+
/** Remote: Reforges code based on user prompt */
|
|
8
|
+
reforgeCode(designSystemId: string, versionId: string, prompt: string, components: Array<any>, existingCode: string): Promise<string>;
|
|
9
|
+
/** Remote: Proposes title for the forged code */
|
|
10
|
+
proposeTitle(designSystemId: string, versionId: string, firstForgeQuery: string): Promise<string>;
|
|
11
|
+
/** Remote: Answers question based on the data of design system in natural language */
|
|
12
|
+
answerQuestion(workspaceId: string, designSystemId: string, versionId: string, persona: "designer" | "developer" | "code", askQuery: string): Promise<string>;
|
|
13
|
+
/** Remote: Index a design system so it can be asked in natural language */
|
|
14
|
+
indexDS(workspaceId: string, designSystemId: string, versionId: string): Promise<string>;
|
|
15
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DTODesignElementsDataDiffResponse, DTODesignSystem, DTODesignSystemContactsResponse, DTODesignSystemMemberListResponse, DTODocumentationLinkPreviewRequest, DTOFigmaNode, DTOGetDocumentationPageAnchorsResponse, DTOPipeline, DTOTokenCollection } from "@supernova-studio/client";
|
|
1
|
+
import { DTODesignElementsDataDiffResponse, DTODesignSystem, DTODesignSystemContactsResponse, DTODesignSystemMemberListResponse, DTODesignSystemVersionStats, DTODocumentationLinkPreviewRequest, DTOFigmaNode, DTOFigmaNodeV2, DTOGetDocumentationPageAnchorsResponse, DTOPipeline, DTOTokenCollection } from "@supernova-studio/client";
|
|
2
2
|
import { AclRemoteModel } from "../../../model/acl/SDKAcl";
|
|
3
3
|
import { BootstrapDataRemoteModel } from "../../../model/base/SDKBootstrapData";
|
|
4
4
|
import { BrandRemoteModel } from "../../../model/base/SDKBrand";
|
|
@@ -28,8 +28,6 @@ import { MembershipRemoteModel } from "../../../model/membership/SDKMembership";
|
|
|
28
28
|
import { ResourceAssetModel } from "../../../model/resources/SDKResourceAsset";
|
|
29
29
|
import { ResourceFontModel } from "../../../model/resources/SDKResourceFont";
|
|
30
30
|
import { CustomDomainRemoteModel } from "../../../model/support/SDKCustomDomain";
|
|
31
|
-
import { FigmaStructureModel } from "../../../model/support/SDKFigmaStructure";
|
|
32
|
-
import { FigmaStructureDetailModel } from "../../../model/support/SDKFigmaStructureDetail";
|
|
33
31
|
import { SourceRemoteModel } from "../../../model/support/SDKSource";
|
|
34
32
|
import { TokenThemeRemoteModel } from "../../../model/themes/SDKTokenTheme";
|
|
35
33
|
import { TokenRemoteModel } from "../../../model/tokens/remote/SDKRemoteTokenModel";
|
|
@@ -54,7 +52,6 @@ import { DataBridge } from "../SDKDataBridge";
|
|
|
54
52
|
export declare class DataCoreReadRequests {
|
|
55
53
|
private bridge;
|
|
56
54
|
constructor(bridge: DataBridge);
|
|
57
|
-
getDataThroughCorsProxy(url: string): Promise<ArrayBuffer | undefined>;
|
|
58
55
|
getRemoteBootstrapData(preferredWorkspaceId?: string, preferredDesignSystemId?: string, preferredVersionId?: string, preferredBrandId?: string): Promise<BootstrapDataRemoteModel>;
|
|
59
56
|
/** Remote: Get information about currently logged in user */
|
|
60
57
|
getRemoteMultiplayerToken(room: string | undefined): Promise<{
|
|
@@ -108,14 +105,40 @@ export declare class DataCoreReadRequests {
|
|
|
108
105
|
getRemoteDesignSystems(workspaceId: string): Promise<Array<DTODesignSystem>>;
|
|
109
106
|
/** Remote: Get custom domain */
|
|
110
107
|
getRemoteCustomDomain(designSystemId: string): Promise<CustomDomainRemoteModel>;
|
|
108
|
+
/** Remote: Get design system stats */
|
|
109
|
+
getRemoteDesignSystemStats(dsId: string, versionId: string, brandId?: string): Promise<DTODesignSystemVersionStats>;
|
|
111
110
|
/** Remote: Get a single design source */
|
|
112
111
|
getRemoteSource(designSystemId: string, sourceId: string): Promise<SourceRemoteModel>;
|
|
113
112
|
/** Remote: Get all design sources of a single design system */
|
|
114
113
|
getRemoteSources(designSystemId: string): Promise<Array<SourceRemoteModel>>;
|
|
115
114
|
/** Remote: Get all figma node structures */
|
|
116
|
-
getFigmaNodeStructures(designSystemId: string
|
|
115
|
+
getFigmaNodeStructures(designSystemId: string): Promise<{
|
|
116
|
+
id: string;
|
|
117
|
+
createdAt: Date;
|
|
118
|
+
updatedAt: Date;
|
|
119
|
+
sourceId: string;
|
|
120
|
+
importState: "Success" | "InProgress" | "Failed";
|
|
121
|
+
}[]>;
|
|
117
122
|
/** Remote: Get figma node detail */
|
|
118
|
-
getFigmaNodeStructureDetail(designSystemId: string,
|
|
123
|
+
getFigmaNodeStructureDetail(designSystemId: string, figmaStructureId: string): Promise<{
|
|
124
|
+
id: string;
|
|
125
|
+
createdAt: Date;
|
|
126
|
+
updatedAt: Date;
|
|
127
|
+
sourceId: string;
|
|
128
|
+
importState: "Success" | "InProgress" | "Failed";
|
|
129
|
+
rootNode: {
|
|
130
|
+
type: "DOCUMENT" | "CANVAS" | "COMPONENT_SET" | "COMPONENT" | "FRAME";
|
|
131
|
+
id: string;
|
|
132
|
+
name: string;
|
|
133
|
+
size?: {
|
|
134
|
+
width: number;
|
|
135
|
+
height: number;
|
|
136
|
+
} | undefined;
|
|
137
|
+
parentComponentSetId?: string | undefined;
|
|
138
|
+
} & {
|
|
139
|
+
children: import("@supernova-studio/model").FigmaFileStructureNode[];
|
|
140
|
+
};
|
|
141
|
+
}>;
|
|
119
142
|
/** Remote: Get information about design system's members */
|
|
120
143
|
getRemoteDesignSystemMemberList(designSystemId: string): Promise<DTODesignSystemMemberListResponse>;
|
|
121
144
|
getRemoteContacts(designSystemId: string): Promise<DTODesignSystemContactsResponse>;
|
|
@@ -213,6 +236,7 @@ export declare class DataCoreReadRequests {
|
|
|
213
236
|
/** Remote: Get all property values that were set by the user for each elemen */
|
|
214
237
|
getRemoteElementPropertyValues(designSystemId: string, versionId: string): Promise<ElementPropertyValueRemoteModel[]>;
|
|
215
238
|
getRemoteFigmaFrames(designSystemId: string, versionId: string): Promise<Array<DTOFigmaNode>>;
|
|
239
|
+
getRemoteFigmaFramesV2(designSystemId: string, versionId: string): Promise<Array<DTOFigmaNodeV2>>;
|
|
216
240
|
getRemoteTokenCollections(designSystemId: string, versionId: string): Promise<Array<DTOTokenCollection>>;
|
|
217
241
|
getRemotePipelines(workspaceId: string, designSystemId?: string): Promise<DTOPipeline[]>;
|
|
218
242
|
getRemoteBuild(workspaceId: string, buildId: string): Promise<ExportBuildModel>;
|
|
@@ -230,4 +254,12 @@ export declare class DataCoreReadRequests {
|
|
|
230
254
|
getImportJob(designSystemId: string, versionId: string, jobId: string): Promise<ImportJobRemoteModel>;
|
|
231
255
|
getKeyValueStorageData(designSystemId: string, keys: Array<string>): Promise<Record<string, string>>;
|
|
232
256
|
getTokenStudioData(designSystemId: string, versionId: string): Promise<object>;
|
|
257
|
+
getPageRedirects(designSystemId: string): Promise<{
|
|
258
|
+
path: string;
|
|
259
|
+
id: string;
|
|
260
|
+
createdAt: Date;
|
|
261
|
+
updatedAt: Date;
|
|
262
|
+
designSystemId: string;
|
|
263
|
+
pagePersistentId: string;
|
|
264
|
+
}[]>;
|
|
233
265
|
}
|