@wix/ditto-codegen-public 1.0.78 → 1.0.80
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/dist/out.js +366 -370
- package/package.json +2 -2
package/dist/out.js
CHANGED
|
@@ -116553,321 +116553,6 @@ ${JSON.stringify(todoExample, null, 2)}
|
|
|
116553
116553
|
}
|
|
116554
116554
|
});
|
|
116555
116555
|
|
|
116556
|
-
// dist/system-prompts/planner/data.js
|
|
116557
|
-
var require_data = __commonJS({
|
|
116558
|
-
"dist/system-prompts/planner/data.js"(exports2) {
|
|
116559
|
-
"use strict";
|
|
116560
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
116561
|
-
exports2.cmsPlannerPrompt = void 0;
|
|
116562
|
-
var handlingFeesExample = {
|
|
116563
|
-
id: "handling-fees-rules",
|
|
116564
|
-
displayName: "Handling Fees Rules",
|
|
116565
|
-
displayField: "productId",
|
|
116566
|
-
fields: [
|
|
116567
|
-
{
|
|
116568
|
-
key: "productId",
|
|
116569
|
-
displayName: "Product",
|
|
116570
|
-
type: "REFERENCE",
|
|
116571
|
-
typeMetadata: {
|
|
116572
|
-
reference: {
|
|
116573
|
-
referencedCollectionId: "Stores/Products"
|
|
116574
|
-
}
|
|
116575
|
-
}
|
|
116576
|
-
},
|
|
116577
|
-
{ key: "oversizedFee", displayName: "Oversized Fee", type: "NUMBER" },
|
|
116578
|
-
{ key: "fragileFee", displayName: "Fragile Fee", type: "NUMBER" }
|
|
116579
|
-
],
|
|
116580
|
-
dataPermissions: {
|
|
116581
|
-
itemRead: "ADMIN",
|
|
116582
|
-
itemInsert: "ADMIN",
|
|
116583
|
-
itemUpdate: "ADMIN",
|
|
116584
|
-
itemRemove: "ADMIN"
|
|
116585
|
-
}
|
|
116586
|
-
};
|
|
116587
|
-
var cmsPlannerPrompt = () => `
|
|
116588
|
-
<CMS_PLANNER_SYSTEM_PROMPT>
|
|
116589
|
-
|
|
116590
|
-
<role>
|
|
116591
|
-
You are a Wix CMS planning expert. Given a blueprint describing an app (name, summary, and extensions), you must produce a concrete CMS plan consisting of one or more valid Wix Data collection objects.
|
|
116592
|
-
|
|
116593
|
-
Your output must be strictly JSON that conforms to the provided schema (no markdown). Use only supported field and role enums listed below.
|
|
116594
|
-
</role>
|
|
116595
|
-
|
|
116596
|
-
<constraints>
|
|
116597
|
-
- Field definitions must use supported FieldType enums exactly as strings: TEXT, NUMBER, DATE, DATETIME, IMAGE, BOOLEAN, DOCUMENT, URL, RICH_TEXT, VIDEO, ANY, ARRAY_STRING, ARRAY_DOCUMENT, AUDIO, TIME, LANGUAGE, RICH_CONTENT, MEDIA_GALLERY, ADDRESS, PAGE_LINK, REFERENCE, MULTI_REFERENCE, OBJECT, ARRAY.
|
|
116598
|
-
- ALWAYS use REFERENCE fields when creating relationships between different CMS collections. ALL related fields must use REFERENCE type.
|
|
116599
|
-
- ALWAYS use REFERENCE fields when the blueprint indicates relationships to Stores entities (products, categories, orders). Use TEXT fields for all other relationships.
|
|
116600
|
-
- MANDATORY REFERENCE scenarios (you MUST use REFERENCE type):
|
|
116601
|
-
- productId, product \u2192 REFERENCE to "Stores/Products"
|
|
116602
|
-
- categoryId, category \u2192 REFERENCE to "Stores/Collections"
|
|
116603
|
-
- orderId, order \u2192 REFERENCE to "Stores/Orders"
|
|
116604
|
-
- When using REFERENCE/MULTI_REFERENCE fields, they MUST include a "typeMetadata" object.
|
|
116605
|
-
- Permissions must use Role enums exactly as strings: ADMIN, SITE_MEMBER_AUTHOR, SITE_MEMBER, ANYONE. Prefer read: ANYONE, insert/update/remove: ADMIN unless the blueprint implies otherwise.
|
|
116606
|
-
- Permissions: For each collection, specify the permissions for each operation (insert, update, remove, read) using one of the following roles:
|
|
116607
|
-
- ADMIN: Only site admins.
|
|
116608
|
-
- SITE_MEMBER_AUTHOR: Each member manages their own items.
|
|
116609
|
-
- SITE_MEMBER: Any logged-in member.
|
|
116610
|
-
- ANYONE: All site visitors, including anonymous.
|
|
116611
|
-
- Choose minimal but meaningful fields that fit the blueprint's domain. Do not add system fields like _id, _createdDate, etc.; they are created automatically.
|
|
116612
|
-
- Ensure field keys are lowerCamelCase and ASCII. displayName values are human-readable.
|
|
116613
|
-
- Do NOT create fields that can be inferred or aggregated from other existing fields (e.g., don't create an "averageRating" field if you already have individual "rating" fields - calculate it dynamically).
|
|
116614
|
-
- Do NOT create audit, transaction, log, history, or analytics collections unless the blueprint explicitly requests them.
|
|
116615
|
-
- If the blueprint does not request persistent data, do not create any collections.
|
|
116616
|
-
- For static or hardcoded behaviors, at most create one minimal read-only configuration collection only when strictly necessary.
|
|
116617
|
-
- NEVER create CMS collections to store embedded script configuration parameters. Embedded script parameters (colors, messages, positions, display settings, etc.) are ALREADY persisted via the embeddedScripts API and are managed through embeddedScriptParameters. Creating duplicate CMS collections for this data is redundant and incorrect.
|
|
116618
|
-
</constraints>
|
|
116619
|
-
|
|
116620
|
-
<typing_rules>
|
|
116621
|
-
- TEXT -> string
|
|
116622
|
-
- NUMBER -> number
|
|
116623
|
-
- BOOLEAN -> boolean
|
|
116624
|
-
- DATE -> string in YYYY-MM-DD
|
|
116625
|
-
- DATETIME -> ISO 8601 string or omit when not needed
|
|
116626
|
-
- IMAGE/VIDEO/DOCUMENT/URL -> string URL
|
|
116627
|
-
- ARRAY_STRING -> string[]
|
|
116628
|
-
- ARRAY_DOCUMENT -> string[] (URLs)
|
|
116629
|
-
- OBJECT -> JSON object
|
|
116630
|
-
- ARRAY -> JSON array
|
|
116631
|
-
</typing_rules>
|
|
116632
|
-
|
|
116633
|
-
<example>
|
|
116634
|
-
Blueprint indicates a handling fees system for products.
|
|
116635
|
-
|
|
116636
|
-
For the collections field, return:
|
|
116637
|
-
\`\`\`
|
|
116638
|
-
${JSON.stringify(handlingFeesExample, null, 2)}
|
|
116639
|
-
\`\`\`
|
|
116640
|
-
</example>
|
|
116641
|
-
|
|
116642
|
-
<approach>
|
|
116643
|
-
1) Read the blueprint name and summary to infer the domain nouns and essential attributes.
|
|
116644
|
-
2) Propose collections only when the blueprint clearly requires persistent data. Define only the fields that are strictly required to fulfill the blueprint's functionality.
|
|
116645
|
-
3) For any field that references products, categories, or orders: ALWAYS use REFERENCE type with proper typeMetadata.
|
|
116646
|
-
4) Pick clear collection ids derived from the domain, lower-kebab or lower_underscore; avoid spaces.
|
|
116647
|
-
5) Avoid Duplicate Data Storage:
|
|
116648
|
-
- Embedded script parameters (defined in embeddedScriptParameters) are ALREADY saved and persisted via the embeddedScripts API
|
|
116649
|
-
- NEVER create CMS collections that duplicate these parameters (colors, messages, positions, display settings, etc.)
|
|
116650
|
-
- CMS collections should ONLY be created for additional business data that is NOT covered by embeddedScriptParameters
|
|
116651
|
-
- Only create CMS collections if there's genuinely new data needed beyond what's in embeddedScriptParameters (e.g., user-generated content, analytics, logs if explicitly requested)
|
|
116652
|
-
</approach>
|
|
116653
|
-
|
|
116654
|
-
</CMS_PLANNER_SYSTEM_PROMPT>
|
|
116655
|
-
`;
|
|
116656
|
-
exports2.cmsPlannerPrompt = cmsPlannerPrompt;
|
|
116657
|
-
}
|
|
116658
|
-
});
|
|
116659
|
-
|
|
116660
|
-
// dist/system-prompts/planner/dynamicParameters.js
|
|
116661
|
-
var require_dynamicParameters = __commonJS({
|
|
116662
|
-
"dist/system-prompts/planner/dynamicParameters.js"(exports2) {
|
|
116663
|
-
"use strict";
|
|
116664
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
116665
|
-
exports2.dynamicParametersPrompt = void 0;
|
|
116666
|
-
var dynamicParametersPrompt = () => `
|
|
116667
|
-
<DYNAMIC_PARAMETERS_PLANNER_SYSTEM_PROMPT>
|
|
116668
|
-
|
|
116669
|
-
<role>
|
|
116670
|
-
You are a Wix CLI planner expert specialized in determining dynamic parameters for embedded scripts. Given a blueprint with EMBEDDED_SCRIPT extensions, you must decide if the embedded script needs dynamic parameters that can be configured via the dashboard, and if so, define them.
|
|
116671
|
-
</role>
|
|
116672
|
-
|
|
116673
|
-
<description>
|
|
116674
|
-
Dynamic parameters allow embedded scripts to be configurable through a dashboard interface. They are template variables ({{variableName}}) that get replaced with actual values set by the site owner in the dashboard.
|
|
116675
|
-
|
|
116676
|
-
Common use cases:
|
|
116677
|
-
- Configuration values (API keys, script settings, display options)
|
|
116678
|
-
- Content that changes (headlines, messages, display text)
|
|
116679
|
-
- Visual customization (colors, sizes, images)
|
|
116680
|
-
- Timing and scheduling (dates, durations, intervals)
|
|
116681
|
-
- Feature toggles (enable/disable functionality)
|
|
116682
|
-
</description>
|
|
116683
|
-
|
|
116684
|
-
<when_to_use_dynamic_parameters>
|
|
116685
|
-
Use dynamic parameters when:
|
|
116686
|
-
- The embedded script needs configurable values that site owners should be able to change
|
|
116687
|
-
- The script's behavior or appearance should be customizable without code changes
|
|
116688
|
-
- Different instances or configurations are needed for different sites
|
|
116689
|
-
- Content, styling, or functionality needs to be adjusted through a UI
|
|
116690
|
-
|
|
116691
|
-
IMPORTANT: If an embedded script extension exists but doesn't need specific dynamic parameters, you should ALWAYS add at least one dynamic parameter: an enable/disable toggle. This allows site owners to control whether the embedded script is active without removing it entirely.
|
|
116692
|
-
|
|
116693
|
-
Example of minimum enable/disable parameter:
|
|
116694
|
-
{
|
|
116695
|
-
"key": "enabled",
|
|
116696
|
-
"displayName": "Enable",
|
|
116697
|
-
"type": "BOOLEAN",
|
|
116698
|
-
"description": "Enable or disable this feature",
|
|
116699
|
-
"required": true,
|
|
116700
|
-
"defaultValue": "true"
|
|
116701
|
-
}
|
|
116702
|
-
</when_to_use_dynamic_parameters>
|
|
116703
|
-
|
|
116704
|
-
<output_structure>
|
|
116705
|
-
|
|
116706
|
-
Each embedded script parameter object contains:
|
|
116707
|
-
- extensionId (string): The name of the embedded script extension these parameters belong to (use the extension.name field)
|
|
116708
|
-
- parameters (array): Array of dynamic parameter definitions
|
|
116709
|
-
|
|
116710
|
-
Each dynamic parameter must include:
|
|
116711
|
-
- key (string, lowerCamelCase): The template variable name used as {{key}} in the embedded script
|
|
116712
|
-
- displayName (string): Human-readable label for the dashboard UI
|
|
116713
|
-
- type (ParameterType): The data type of the parameter
|
|
116714
|
-
- description (string, optional): Help text explaining the parameter's purpose
|
|
116715
|
-
- required (boolean): Whether the parameter must have a value
|
|
116716
|
-
- defaultValue (string, optional): Default value if not set by the user
|
|
116717
|
-
- options (array of strings, optional): For SELECT type parameters, the available options
|
|
116718
|
-
|
|
116719
|
-
Example output structures:
|
|
116720
|
-
|
|
116721
|
-
|
|
116722
|
-
With embedded script extensions:
|
|
116723
|
-
[
|
|
116724
|
-
{
|
|
116725
|
-
"extensionId": "site-popup",
|
|
116726
|
-
"parameters": [
|
|
116727
|
-
{ "key": "headline", "displayName": "Headline", "type": "TEXT", "required": true },
|
|
116728
|
-
{ "key": "text", "displayName": "Text", "type": "TEXT", "required": true }
|
|
116729
|
-
]
|
|
116730
|
-
}
|
|
116731
|
-
]
|
|
116732
|
-
|
|
116733
|
-
Supported parameter types:
|
|
116734
|
-
- TEXT: text input
|
|
116735
|
-
- NUMBER: Numeric input
|
|
116736
|
-
- BOOLEAN: Checkbox or toggle
|
|
116737
|
-
- IMAGE: Image picker
|
|
116738
|
-
- DATE: Date picker
|
|
116739
|
-
- DATETIME: Date and time picker
|
|
116740
|
-
- URL: URL input with validation
|
|
116741
|
-
- SELECT: Dropdown with predefined options (must include options array)
|
|
116742
|
-
- COLOR: Color picker
|
|
116743
|
-
</output_structure>
|
|
116744
|
-
|
|
116745
|
-
<examples>
|
|
116746
|
-
|
|
116747
|
-
Example 1 - Site Popup (dynamic parameters needed):
|
|
116748
|
-
Blueprint: A popup that appears on the site with configurable message and timing
|
|
116749
|
-
Extension Name: "site-popup"
|
|
116750
|
-
Output:
|
|
116751
|
-
[
|
|
116752
|
-
{
|
|
116753
|
-
"extensionId": "site-popup",
|
|
116754
|
-
"parameters": [
|
|
116755
|
-
{
|
|
116756
|
-
"key": "headline",
|
|
116757
|
-
"displayName": "Headline",
|
|
116758
|
-
"type": "TEXT",
|
|
116759
|
-
"description": "The main headline shown in the popup",
|
|
116760
|
-
"required": true,
|
|
116761
|
-
"defaultValue": "Sale 20% Off"
|
|
116762
|
-
},
|
|
116763
|
-
{
|
|
116764
|
-
"key": "text",
|
|
116765
|
-
"displayName": "Text",
|
|
116766
|
-
"type": "TEXT",
|
|
116767
|
-
"description": "The message content of the popup",
|
|
116768
|
-
"required": true,
|
|
116769
|
-
"defaultValue": "Sign up and get 20% off on our Winter Sale"
|
|
116770
|
-
},
|
|
116771
|
-
{
|
|
116772
|
-
"key": "imageUrl",
|
|
116773
|
-
"displayName": "Image",
|
|
116774
|
-
"type": "IMAGE",
|
|
116775
|
-
"description": "The image displayed in the popup",
|
|
116776
|
-
"required": false
|
|
116777
|
-
},
|
|
116778
|
-
{
|
|
116779
|
-
"key": "imageTitle",
|
|
116780
|
-
"displayName": "Image Title",
|
|
116781
|
-
"type": "TEXT",
|
|
116782
|
-
"description": "Alt text for the popup image",
|
|
116783
|
-
"required": false
|
|
116784
|
-
},
|
|
116785
|
-
{
|
|
116786
|
-
"key": "activationMode",
|
|
116787
|
-
"displayName": "Activation Mode",
|
|
116788
|
-
"type": "SELECT",
|
|
116789
|
-
"description": "When the popup should be active",
|
|
116790
|
-
"required": true,
|
|
116791
|
-
"defaultValue": "active",
|
|
116792
|
-
"options": ["active", "timed", "disabled"]
|
|
116793
|
-
},
|
|
116794
|
-
{
|
|
116795
|
-
"key": "startDate",
|
|
116796
|
-
"displayName": "Start Date",
|
|
116797
|
-
"type": "DATE",
|
|
116798
|
-
"description": "Start date for timed activation",
|
|
116799
|
-
"required": false
|
|
116800
|
-
},
|
|
116801
|
-
{
|
|
116802
|
-
"key": "endDate",
|
|
116803
|
-
"displayName": "End Date",
|
|
116804
|
-
"type": "DATE",
|
|
116805
|
-
"description": "End date for timed activation",
|
|
116806
|
-
"required": false
|
|
116807
|
-
}
|
|
116808
|
-
]
|
|
116809
|
-
}
|
|
116810
|
-
]
|
|
116811
|
-
|
|
116812
|
-
Example 2 - Static Pixel (minimal dynamic parameters):
|
|
116813
|
-
Blueprint: Add a Facebook Pixel with a hardcoded pixel ID
|
|
116814
|
-
Extension Name: "facebook-pixel"
|
|
116815
|
-
Output:
|
|
116816
|
-
{
|
|
116817
|
-
"key": "enabled",
|
|
116818
|
-
"displayName": "Enable",
|
|
116819
|
-
"type": "BOOLEAN",
|
|
116820
|
-
"description": "Enable or disable this feature",
|
|
116821
|
-
"required": true,
|
|
116822
|
-
"defaultValue": "true"
|
|
116823
|
-
}
|
|
116824
|
-
|
|
116825
|
-
</examples>
|
|
116826
|
-
|
|
116827
|
-
<guidelines>
|
|
116828
|
-
- If there are EMBEDDED_SCRIPT extensions, you MUST always include at least one parameter per extension
|
|
116829
|
-
- At minimum, every embedded script should have an enable/disable parameter to allow site owners to control activation
|
|
116830
|
-
- The extensionId MUST match the exact name of the embedded script extension from the blueprint
|
|
116831
|
-
- Define additional parameters only if they truly need to be configurable by the site owner
|
|
116832
|
-
- Keep parameter keys descriptive and in lowerCamelCase
|
|
116833
|
-
- Provide clear displayName and description for each parameter
|
|
116834
|
-
- Set appropriate required flags based on functionality needs
|
|
116835
|
-
- Choose the most appropriate type for the data
|
|
116836
|
-
- For SELECT types, MUST include the options array with all possible values
|
|
116837
|
-
- Consider grouping related parameters (e.g., activation settings, appearance settings)
|
|
116838
|
-
- Default values should be sensible and demonstrate the expected format
|
|
116839
|
-
</guidelines>
|
|
116840
|
-
|
|
116841
|
-
</DYNAMIC_PARAMETERS_PLANNER_SYSTEM_PROMPT>
|
|
116842
|
-
`;
|
|
116843
|
-
exports2.dynamicParametersPrompt = dynamicParametersPrompt;
|
|
116844
|
-
}
|
|
116845
|
-
});
|
|
116846
|
-
|
|
116847
|
-
// dist/system-prompts/planner/planner.js
|
|
116848
|
-
var require_planner = __commonJS({
|
|
116849
|
-
"dist/system-prompts/planner/planner.js"(exports2) {
|
|
116850
|
-
"use strict";
|
|
116851
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
116852
|
-
exports2.plannerPrompt = void 0;
|
|
116853
|
-
var apiSpec_1 = require_apiSpec();
|
|
116854
|
-
var data_1 = require_data();
|
|
116855
|
-
var dynamicParameters_1 = require_dynamicParameters();
|
|
116856
|
-
var plannerPrompt = (hasEmbeddedScriptExtensions, hasBackendApiExtensions) => {
|
|
116857
|
-
return `
|
|
116858
|
-
<WIXCLI_PLANNER_SYSTEM_PROMPT>
|
|
116859
|
-
${(0, data_1.cmsPlannerPrompt)()}
|
|
116860
|
-
|
|
116861
|
-
${hasBackendApiExtensions ? (0, apiSpec_1.apiSpecPrompt)() : "No backend API extensions in the blueprint, don't return anything for apiSpec"}
|
|
116862
|
-
|
|
116863
|
-
${hasEmbeddedScriptExtensions ? (0, dynamicParameters_1.dynamicParametersPrompt)() : 'No embeddedScriptParameters needed, no embedded scripts in the blueprint, return an empty array: "embeddedScriptParameters": []'}
|
|
116864
|
-
</WIXCLI_PLANNER_SYSTEM_PROMPT>
|
|
116865
|
-
`;
|
|
116866
|
-
};
|
|
116867
|
-
exports2.plannerPrompt = plannerPrompt;
|
|
116868
|
-
}
|
|
116869
|
-
});
|
|
116870
|
-
|
|
116871
116556
|
// ../../node_modules/@wix/ambassador-data-v2-data-collection/build/cjs/types.impl.js
|
|
116872
116557
|
var require_types_impl2 = __commonJS({
|
|
116873
116558
|
"../../node_modules/@wix/ambassador-data-v2-data-collection/build/cjs/types.impl.js"(exports2) {
|
|
@@ -117069,62 +116754,371 @@ var require_types_impl2 = __commonJS({
|
|
|
117069
116754
|
}
|
|
117070
116755
|
});
|
|
117071
116756
|
|
|
117072
|
-
// dist/cms/CMSSchema.js
|
|
117073
|
-
var require_CMSSchema = __commonJS({
|
|
117074
|
-
"dist/cms/CMSSchema.js"(exports2) {
|
|
116757
|
+
// dist/cms/CMSSchema.js
|
|
116758
|
+
var require_CMSSchema = __commonJS({
|
|
116759
|
+
"dist/cms/CMSSchema.js"(exports2) {
|
|
116760
|
+
"use strict";
|
|
116761
|
+
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
116762
|
+
exports2.CmsCollectionSchema = void 0;
|
|
116763
|
+
var types_1 = require_types_impl2();
|
|
116764
|
+
var zod_1 = require_zod();
|
|
116765
|
+
var FieldTypeEnum = zod_1.z.enum(Object.values(types_1.FieldType));
|
|
116766
|
+
var AccessLevelEnum = zod_1.z.enum(Object.values(types_1.AccessLevel));
|
|
116767
|
+
var ReferenceSchema = zod_1.z.object({
|
|
116768
|
+
referencedCollectionId: zod_1.z.string().optional()
|
|
116769
|
+
});
|
|
116770
|
+
var MultiReferenceSchema = zod_1.z.object({
|
|
116771
|
+
referencedCollectionId: zod_1.z.string().optional(),
|
|
116772
|
+
referencingFieldKey: zod_1.z.string().optional()
|
|
116773
|
+
});
|
|
116774
|
+
var ObjectFieldSchema = zod_1.z.object({
|
|
116775
|
+
key: zod_1.z.string().optional()
|
|
116776
|
+
});
|
|
116777
|
+
var ObjectSchema = zod_1.z.object({
|
|
116778
|
+
fields: zod_1.z.array(ObjectFieldSchema).optional()
|
|
116779
|
+
});
|
|
116780
|
+
var ArraySchema = zod_1.z.object({
|
|
116781
|
+
elementType: FieldTypeEnum.optional(),
|
|
116782
|
+
typeMetadata: zod_1.z.any().optional()
|
|
116783
|
+
// Recursive, simplified for now
|
|
116784
|
+
});
|
|
116785
|
+
var TypeMetadataSchema = zod_1.z.object({
|
|
116786
|
+
reference: ReferenceSchema.optional(),
|
|
116787
|
+
multiReference: MultiReferenceSchema.optional(),
|
|
116788
|
+
object: ObjectSchema.optional(),
|
|
116789
|
+
array: ArraySchema.optional()
|
|
116790
|
+
}).optional();
|
|
116791
|
+
var FieldSchema = zod_1.z.object({
|
|
116792
|
+
key: zod_1.z.string().optional(),
|
|
116793
|
+
displayName: zod_1.z.string().nullable().optional(),
|
|
116794
|
+
type: FieldTypeEnum.optional(),
|
|
116795
|
+
typeMetadata: TypeMetadataSchema,
|
|
116796
|
+
encrypted: zod_1.z.boolean().optional(),
|
|
116797
|
+
description: zod_1.z.string().nullable().optional()
|
|
116798
|
+
});
|
|
116799
|
+
var DataPermissionsSchema = zod_1.z.object({
|
|
116800
|
+
itemRead: AccessLevelEnum.optional(),
|
|
116801
|
+
itemInsert: AccessLevelEnum.optional(),
|
|
116802
|
+
itemUpdate: AccessLevelEnum.optional(),
|
|
116803
|
+
itemRemove: AccessLevelEnum.optional()
|
|
116804
|
+
});
|
|
116805
|
+
exports2.CmsCollectionSchema = zod_1.z.object({
|
|
116806
|
+
id: zod_1.z.string().optional(),
|
|
116807
|
+
displayName: zod_1.z.string().nullable().optional(),
|
|
116808
|
+
displayField: zod_1.z.string().nullable().optional(),
|
|
116809
|
+
fields: zod_1.z.array(FieldSchema).optional(),
|
|
116810
|
+
dataPermissions: DataPermissionsSchema.optional(),
|
|
116811
|
+
initialData: zod_1.z.array(zod_1.z.record(zod_1.z.string(), zod_1.z.any())).optional()
|
|
116812
|
+
});
|
|
116813
|
+
}
|
|
116814
|
+
});
|
|
116815
|
+
|
|
116816
|
+
// dist/system-prompts/planner/data.js
|
|
116817
|
+
var require_data = __commonJS({
|
|
116818
|
+
"dist/system-prompts/planner/data.js"(exports2) {
|
|
116819
|
+
"use strict";
|
|
116820
|
+
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
116821
|
+
exports2.cmsPlannerPrompt = void 0;
|
|
116822
|
+
var zod_1 = require_zod();
|
|
116823
|
+
var CMSSchema_1 = require_CMSSchema();
|
|
116824
|
+
var types_impl_1 = require_types_impl2();
|
|
116825
|
+
var CollectionsArraySchema = zod_1.z.array(CMSSchema_1.CmsCollectionSchema);
|
|
116826
|
+
var handlingFeesExample = [
|
|
116827
|
+
{
|
|
116828
|
+
id: "handling-fees-rules",
|
|
116829
|
+
displayName: "Handling Fees Rules",
|
|
116830
|
+
displayField: "productId",
|
|
116831
|
+
fields: [
|
|
116832
|
+
{
|
|
116833
|
+
key: "productId",
|
|
116834
|
+
displayName: "Product",
|
|
116835
|
+
type: "REFERENCE",
|
|
116836
|
+
typeMetadata: {
|
|
116837
|
+
reference: {
|
|
116838
|
+
referencedCollectionId: "Stores/Products"
|
|
116839
|
+
}
|
|
116840
|
+
}
|
|
116841
|
+
},
|
|
116842
|
+
{ key: "oversizedFee", displayName: "Oversized Fee", type: "NUMBER" },
|
|
116843
|
+
{ key: "fragileFee", displayName: "Fragile Fee", type: "NUMBER" }
|
|
116844
|
+
],
|
|
116845
|
+
dataPermissions: {
|
|
116846
|
+
itemRead: types_impl_1.AccessLevel.ANYONE,
|
|
116847
|
+
itemInsert: types_impl_1.AccessLevel.PRIVILEGED,
|
|
116848
|
+
itemUpdate: types_impl_1.AccessLevel.PRIVILEGED,
|
|
116849
|
+
itemRemove: types_impl_1.AccessLevel.PRIVILEGED
|
|
116850
|
+
}
|
|
116851
|
+
}
|
|
116852
|
+
];
|
|
116853
|
+
var cmsPlannerPrompt = () => `
|
|
116854
|
+
<CMS_PLANNER_SYSTEM_PROMPT>
|
|
116855
|
+
|
|
116856
|
+
<role>
|
|
116857
|
+
You are a Wix CMS planning expert. Given a blueprint describing an app (name, summary, and extensions), you must produce a concrete CMS plan consisting of one or more valid Wix Data collection objects.
|
|
116858
|
+
|
|
116859
|
+
Your output must be strictly JSON that conforms to the provided schema (no markdown). Use only supported field and role enums listed below.
|
|
116860
|
+
</role>
|
|
116861
|
+
|
|
116862
|
+
<constraints>
|
|
116863
|
+
- Field definitions must use supported FieldType enums exactly as strings: TEXT, NUMBER, DATE, DATETIME, IMAGE, BOOLEAN, DOCUMENT, URL, RICH_TEXT, VIDEO, ANY, ARRAY_STRING, ARRAY_DOCUMENT, AUDIO, TIME, LANGUAGE, RICH_CONTENT, MEDIA_GALLERY, ADDRESS, PAGE_LINK, REFERENCE, MULTI_REFERENCE, OBJECT, ARRAY.
|
|
116864
|
+
- ALWAYS use REFERENCE fields when creating relationships between different CMS collections. ALL related fields must use REFERENCE type.
|
|
116865
|
+
- ALWAYS use REFERENCE fields when the blueprint indicates relationships to Stores entities (products, categories, orders). Use TEXT fields for all other relationships.
|
|
116866
|
+
- MANDATORY REFERENCE scenarios (you MUST use REFERENCE type):
|
|
116867
|
+
- productId, product \u2192 REFERENCE to "Stores/Products"
|
|
116868
|
+
- categoryId, category \u2192 REFERENCE to "Stores/Collections"
|
|
116869
|
+
- orderId, order \u2192 REFERENCE to "Stores/Orders"
|
|
116870
|
+
- When using REFERENCE/MULTI_REFERENCE fields, they MUST include a "typeMetadata" object.
|
|
116871
|
+
- Permissions must use AccessLevel enums exactly as strings: UNDEFINED, ANYONE, SITE_MEMBER, SITE_MEMBER_AUTHOR, CMS_EDITOR, PRIVILEGED. Prefer read: ANYONE, insert/update/remove: PRIVILEGED unless the blueprint implies otherwise.
|
|
116872
|
+
- Permissions: For each collection, specify the permissions for each operation (insert, update, remove, read) using one of the following access levels:
|
|
116873
|
+
- UNDEFINED: Not set.
|
|
116874
|
+
- ANYONE: Any subject, including visitors.
|
|
116875
|
+
- SITE_MEMBER: Any signed-in user (both site members and collaborators).
|
|
116876
|
+
- SITE_MEMBER_AUTHOR: Any signed-in user, but site members only have access to own items.
|
|
116877
|
+
- CMS_EDITOR: Site collaborator that has a role with CMS Access permission.
|
|
116878
|
+
- PRIVILEGED: CMS administrators and users or roles granted with special access.
|
|
116879
|
+
- Ensure field keys are lowerCamelCase and ASCII. displayName values are human-readable.
|
|
116880
|
+
- Do NOT create fields that can be inferred or aggregated from other existing fields (e.g., don't create an "averageRating" field if you already have individual "rating" fields - calculate it dynamically).
|
|
116881
|
+
- Do NOT create audit, transaction, log, history, or analytics collections unless the blueprint explicitly requests them.
|
|
116882
|
+
- If the blueprint does not request persistent data, do not create any collections.
|
|
116883
|
+
- For static or hardcoded behaviors, at most create one minimal read-only configuration collection only when strictly necessary.
|
|
116884
|
+
- NEVER create CMS collections to store embedded script configuration parameters. Embedded script parameters (colors, messages, positions, display settings, etc.) are ALREADY persisted via the embeddedScripts API and are managed through embeddedScriptParameters. Creating duplicate CMS collections for this data is redundant and incorrect.
|
|
116885
|
+
</constraints>
|
|
116886
|
+
|
|
116887
|
+
<example>
|
|
116888
|
+
Blueprint indicates a handling fees system for products.
|
|
116889
|
+
|
|
116890
|
+
For the collections field, return:
|
|
116891
|
+
\`\`\`
|
|
116892
|
+
${JSON.stringify(handlingFeesExample, null, 2)}
|
|
116893
|
+
\`\`\`
|
|
116894
|
+
</example>
|
|
116895
|
+
|
|
116896
|
+
<approach>
|
|
116897
|
+
1) Read the blueprint name and summary to infer the domain nouns and essential attributes.
|
|
116898
|
+
2) Propose collections only when the blueprint clearly requires persistent data. Define only the fields that are strictly required to fulfill the blueprint's functionality.
|
|
116899
|
+
3) For any field that references products, categories, or orders: ALWAYS use REFERENCE type with proper typeMetadata.
|
|
116900
|
+
4) Pick clear collection ids derived from the domain, lower-kebab or lower_underscore; avoid spaces.
|
|
116901
|
+
5) Avoid Duplicate Data Storage:
|
|
116902
|
+
- Embedded script parameters (defined in embeddedScriptParameters) are ALREADY saved and persisted via the embeddedScripts API
|
|
116903
|
+
- NEVER create CMS collections that duplicate these parameters (colors, messages, positions, display settings, etc.)
|
|
116904
|
+
- CMS collections should ONLY be created for additional business data that is NOT covered by embeddedScriptParameters
|
|
116905
|
+
- Only create CMS collections if there's genuinely new data needed beyond what's in embeddedScriptParameters (e.g., user-generated content, analytics, logs if explicitly requested)
|
|
116906
|
+
</approach>
|
|
116907
|
+
|
|
116908
|
+
</CMS_PLANNER_SYSTEM_PROMPT>
|
|
116909
|
+
`;
|
|
116910
|
+
exports2.cmsPlannerPrompt = cmsPlannerPrompt;
|
|
116911
|
+
}
|
|
116912
|
+
});
|
|
116913
|
+
|
|
116914
|
+
// dist/system-prompts/planner/dynamicParameters.js
|
|
116915
|
+
var require_dynamicParameters = __commonJS({
|
|
116916
|
+
"dist/system-prompts/planner/dynamicParameters.js"(exports2) {
|
|
116917
|
+
"use strict";
|
|
116918
|
+
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
116919
|
+
exports2.dynamicParametersPrompt = void 0;
|
|
116920
|
+
var dynamicParametersPrompt = () => `
|
|
116921
|
+
<DYNAMIC_PARAMETERS_PLANNER_SYSTEM_PROMPT>
|
|
116922
|
+
|
|
116923
|
+
<role>
|
|
116924
|
+
You are a Wix CLI planner expert specialized in determining dynamic parameters for embedded scripts. Given a blueprint with EMBEDDED_SCRIPT extensions, you must decide if the embedded script needs dynamic parameters that can be configured via the dashboard, and if so, define them.
|
|
116925
|
+
</role>
|
|
116926
|
+
|
|
116927
|
+
<description>
|
|
116928
|
+
Dynamic parameters allow embedded scripts to be configurable through a dashboard interface. They are template variables ({{variableName}}) that get replaced with actual values set by the site owner in the dashboard.
|
|
116929
|
+
|
|
116930
|
+
Common use cases:
|
|
116931
|
+
- Configuration values (API keys, script settings, display options)
|
|
116932
|
+
- Content that changes (headlines, messages, display text)
|
|
116933
|
+
- Visual customization (colors, sizes, images)
|
|
116934
|
+
- Timing and scheduling (dates, durations, intervals)
|
|
116935
|
+
- Feature toggles (enable/disable functionality)
|
|
116936
|
+
</description>
|
|
116937
|
+
|
|
116938
|
+
<when_to_use_dynamic_parameters>
|
|
116939
|
+
Use dynamic parameters when:
|
|
116940
|
+
- The embedded script needs configurable values that site owners should be able to change
|
|
116941
|
+
- The script's behavior or appearance should be customizable without code changes
|
|
116942
|
+
- Different instances or configurations are needed for different sites
|
|
116943
|
+
- Content, styling, or functionality needs to be adjusted through a UI
|
|
116944
|
+
|
|
116945
|
+
IMPORTANT: If an embedded script extension exists but doesn't need specific dynamic parameters, you should ALWAYS add at least one dynamic parameter: an enable/disable toggle. This allows site owners to control whether the embedded script is active without removing it entirely.
|
|
116946
|
+
|
|
116947
|
+
Example of minimum enable/disable parameter:
|
|
116948
|
+
{
|
|
116949
|
+
"key": "enabled",
|
|
116950
|
+
"displayName": "Enable",
|
|
116951
|
+
"type": "BOOLEAN",
|
|
116952
|
+
"description": "Enable or disable this feature",
|
|
116953
|
+
"required": true,
|
|
116954
|
+
"defaultValue": "true"
|
|
116955
|
+
}
|
|
116956
|
+
</when_to_use_dynamic_parameters>
|
|
116957
|
+
|
|
116958
|
+
<output_structure>
|
|
116959
|
+
|
|
116960
|
+
Each embedded script parameter object contains:
|
|
116961
|
+
- extensionId (string): The name of the embedded script extension these parameters belong to (use the extension.name field)
|
|
116962
|
+
- parameters (array): Array of dynamic parameter definitions
|
|
116963
|
+
|
|
116964
|
+
Each dynamic parameter must include:
|
|
116965
|
+
- key (string, lowerCamelCase): The template variable name used as {{key}} in the embedded script
|
|
116966
|
+
- displayName (string): Human-readable label for the dashboard UI
|
|
116967
|
+
- type (ParameterType): The data type of the parameter
|
|
116968
|
+
- description (string, optional): Help text explaining the parameter's purpose
|
|
116969
|
+
- required (boolean): Whether the parameter must have a value
|
|
116970
|
+
- defaultValue (string, optional): Default value if not set by the user
|
|
116971
|
+
- options (array of strings, optional): For SELECT type parameters, the available options
|
|
116972
|
+
|
|
116973
|
+
Example output structures:
|
|
116974
|
+
|
|
116975
|
+
|
|
116976
|
+
With embedded script extensions:
|
|
116977
|
+
[
|
|
116978
|
+
{
|
|
116979
|
+
"extensionId": "site-popup",
|
|
116980
|
+
"parameters": [
|
|
116981
|
+
{ "key": "headline", "displayName": "Headline", "type": "TEXT", "required": true },
|
|
116982
|
+
{ "key": "text", "displayName": "Text", "type": "TEXT", "required": true }
|
|
116983
|
+
]
|
|
116984
|
+
}
|
|
116985
|
+
]
|
|
116986
|
+
|
|
116987
|
+
Supported parameter types:
|
|
116988
|
+
- TEXT: text input
|
|
116989
|
+
- NUMBER: Numeric input
|
|
116990
|
+
- BOOLEAN: Checkbox or toggle
|
|
116991
|
+
- IMAGE: Image picker
|
|
116992
|
+
- DATE: Date picker
|
|
116993
|
+
- DATETIME: Date and time picker
|
|
116994
|
+
- URL: URL input with validation
|
|
116995
|
+
- SELECT: Dropdown with predefined options (must include options array)
|
|
116996
|
+
- COLOR: Color picker
|
|
116997
|
+
</output_structure>
|
|
116998
|
+
|
|
116999
|
+
<examples>
|
|
117000
|
+
|
|
117001
|
+
Example 1 - Site Popup (dynamic parameters needed):
|
|
117002
|
+
Blueprint: A popup that appears on the site with configurable message and timing
|
|
117003
|
+
Extension Name: "site-popup"
|
|
117004
|
+
Output:
|
|
117005
|
+
[
|
|
117006
|
+
{
|
|
117007
|
+
"extensionId": "site-popup",
|
|
117008
|
+
"parameters": [
|
|
117009
|
+
{
|
|
117010
|
+
"key": "headline",
|
|
117011
|
+
"displayName": "Headline",
|
|
117012
|
+
"type": "TEXT",
|
|
117013
|
+
"description": "The main headline shown in the popup",
|
|
117014
|
+
"required": true,
|
|
117015
|
+
"defaultValue": "Sale 20% Off"
|
|
117016
|
+
},
|
|
117017
|
+
{
|
|
117018
|
+
"key": "text",
|
|
117019
|
+
"displayName": "Text",
|
|
117020
|
+
"type": "TEXT",
|
|
117021
|
+
"description": "The message content of the popup",
|
|
117022
|
+
"required": true,
|
|
117023
|
+
"defaultValue": "Sign up and get 20% off on our Winter Sale"
|
|
117024
|
+
},
|
|
117025
|
+
{
|
|
117026
|
+
"key": "imageUrl",
|
|
117027
|
+
"displayName": "Image",
|
|
117028
|
+
"type": "IMAGE",
|
|
117029
|
+
"description": "The image displayed in the popup",
|
|
117030
|
+
"required": false
|
|
117031
|
+
},
|
|
117032
|
+
{
|
|
117033
|
+
"key": "imageTitle",
|
|
117034
|
+
"displayName": "Image Title",
|
|
117035
|
+
"type": "TEXT",
|
|
117036
|
+
"description": "Alt text for the popup image",
|
|
117037
|
+
"required": false
|
|
117038
|
+
},
|
|
117039
|
+
{
|
|
117040
|
+
"key": "activationMode",
|
|
117041
|
+
"displayName": "Activation Mode",
|
|
117042
|
+
"type": "SELECT",
|
|
117043
|
+
"description": "When the popup should be active",
|
|
117044
|
+
"required": true,
|
|
117045
|
+
"defaultValue": "active",
|
|
117046
|
+
"options": ["active", "timed", "disabled"]
|
|
117047
|
+
},
|
|
117048
|
+
{
|
|
117049
|
+
"key": "startDate",
|
|
117050
|
+
"displayName": "Start Date",
|
|
117051
|
+
"type": "DATE",
|
|
117052
|
+
"description": "Start date for timed activation",
|
|
117053
|
+
"required": false
|
|
117054
|
+
},
|
|
117055
|
+
{
|
|
117056
|
+
"key": "endDate",
|
|
117057
|
+
"displayName": "End Date",
|
|
117058
|
+
"type": "DATE",
|
|
117059
|
+
"description": "End date for timed activation",
|
|
117060
|
+
"required": false
|
|
117061
|
+
}
|
|
117062
|
+
]
|
|
117063
|
+
}
|
|
117064
|
+
]
|
|
117065
|
+
|
|
117066
|
+
Example 2 - Static Pixel (minimal dynamic parameters):
|
|
117067
|
+
Blueprint: Add a Facebook Pixel with a hardcoded pixel ID
|
|
117068
|
+
Extension Name: "facebook-pixel"
|
|
117069
|
+
Output:
|
|
117070
|
+
{
|
|
117071
|
+
"key": "enabled",
|
|
117072
|
+
"displayName": "Enable",
|
|
117073
|
+
"type": "BOOLEAN",
|
|
117074
|
+
"description": "Enable or disable this feature",
|
|
117075
|
+
"required": true,
|
|
117076
|
+
"defaultValue": "true"
|
|
117077
|
+
}
|
|
117078
|
+
|
|
117079
|
+
</examples>
|
|
117080
|
+
|
|
117081
|
+
<guidelines>
|
|
117082
|
+
- If there are EMBEDDED_SCRIPT extensions, you MUST always include at least one parameter per extension
|
|
117083
|
+
- At minimum, every embedded script should have an enable/disable parameter to allow site owners to control activation
|
|
117084
|
+
- The extensionId MUST match the exact name of the embedded script extension from the blueprint
|
|
117085
|
+
- Define additional parameters only if they truly need to be configurable by the site owner
|
|
117086
|
+
- Keep parameter keys descriptive and in lowerCamelCase
|
|
117087
|
+
- Provide clear displayName and description for each parameter
|
|
117088
|
+
- Set appropriate required flags based on functionality needs
|
|
117089
|
+
- Choose the most appropriate type for the data
|
|
117090
|
+
- For SELECT types, MUST include the options array with all possible values
|
|
117091
|
+
- Consider grouping related parameters (e.g., activation settings, appearance settings)
|
|
117092
|
+
- Default values should be sensible and demonstrate the expected format
|
|
117093
|
+
</guidelines>
|
|
117094
|
+
|
|
117095
|
+
</DYNAMIC_PARAMETERS_PLANNER_SYSTEM_PROMPT>
|
|
117096
|
+
`;
|
|
117097
|
+
exports2.dynamicParametersPrompt = dynamicParametersPrompt;
|
|
117098
|
+
}
|
|
117099
|
+
});
|
|
117100
|
+
|
|
117101
|
+
// dist/system-prompts/planner/planner.js
|
|
117102
|
+
var require_planner = __commonJS({
|
|
117103
|
+
"dist/system-prompts/planner/planner.js"(exports2) {
|
|
117075
117104
|
"use strict";
|
|
117076
117105
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
117077
|
-
exports2.
|
|
117078
|
-
var
|
|
117079
|
-
var
|
|
117080
|
-
var
|
|
117081
|
-
var
|
|
117082
|
-
|
|
117083
|
-
|
|
117084
|
-
|
|
117085
|
-
|
|
117086
|
-
|
|
117087
|
-
|
|
117088
|
-
|
|
117089
|
-
|
|
117090
|
-
|
|
117091
|
-
}
|
|
117092
|
-
|
|
117093
|
-
fields: zod_1.z.array(ObjectFieldSchema).optional()
|
|
117094
|
-
});
|
|
117095
|
-
var ArraySchema = zod_1.z.object({
|
|
117096
|
-
elementType: FieldTypeEnum.optional(),
|
|
117097
|
-
typeMetadata: zod_1.z.any().optional()
|
|
117098
|
-
// Recursive, simplified for now
|
|
117099
|
-
});
|
|
117100
|
-
var TypeMetadataSchema = zod_1.z.object({
|
|
117101
|
-
reference: ReferenceSchema.optional(),
|
|
117102
|
-
multiReference: MultiReferenceSchema.optional(),
|
|
117103
|
-
object: ObjectSchema.optional(),
|
|
117104
|
-
array: ArraySchema.optional()
|
|
117105
|
-
}).optional();
|
|
117106
|
-
var FieldSchema = zod_1.z.object({
|
|
117107
|
-
key: zod_1.z.string().optional(),
|
|
117108
|
-
displayName: zod_1.z.string().nullable().optional(),
|
|
117109
|
-
type: FieldTypeEnum.optional(),
|
|
117110
|
-
typeMetadata: TypeMetadataSchema,
|
|
117111
|
-
encrypted: zod_1.z.boolean().optional(),
|
|
117112
|
-
description: zod_1.z.string().nullable().optional()
|
|
117113
|
-
});
|
|
117114
|
-
var DataPermissionsSchema = zod_1.z.object({
|
|
117115
|
-
itemRead: AccessLevelEnum.optional(),
|
|
117116
|
-
itemInsert: AccessLevelEnum.optional(),
|
|
117117
|
-
itemUpdate: AccessLevelEnum.optional(),
|
|
117118
|
-
itemRemove: AccessLevelEnum.optional()
|
|
117119
|
-
});
|
|
117120
|
-
exports2.CmsCollectionSchema = zod_1.z.object({
|
|
117121
|
-
id: zod_1.z.string().optional(),
|
|
117122
|
-
displayName: zod_1.z.string().nullable().optional(),
|
|
117123
|
-
displayField: zod_1.z.string().nullable().optional(),
|
|
117124
|
-
fields: zod_1.z.array(FieldSchema).optional(),
|
|
117125
|
-
dataPermissions: DataPermissionsSchema.optional(),
|
|
117126
|
-
initialData: zod_1.z.array(zod_1.z.record(zod_1.z.string(), zod_1.z.any())).optional()
|
|
117127
|
-
});
|
|
117106
|
+
exports2.plannerPrompt = void 0;
|
|
117107
|
+
var apiSpec_1 = require_apiSpec();
|
|
117108
|
+
var data_1 = require_data();
|
|
117109
|
+
var dynamicParameters_1 = require_dynamicParameters();
|
|
117110
|
+
var plannerPrompt = (hasEmbeddedScriptExtensions, hasBackendApiExtensions) => {
|
|
117111
|
+
return `
|
|
117112
|
+
<WIXCLI_PLANNER_SYSTEM_PROMPT>
|
|
117113
|
+
${(0, data_1.cmsPlannerPrompt)()}
|
|
117114
|
+
|
|
117115
|
+
${hasBackendApiExtensions ? (0, apiSpec_1.apiSpecPrompt)() : "No backend API extensions in the blueprint, don't return anything for apiSpec"}
|
|
117116
|
+
|
|
117117
|
+
${hasEmbeddedScriptExtensions ? (0, dynamicParameters_1.dynamicParametersPrompt)() : 'No embeddedScriptParameters needed, no embedded scripts in the blueprint, return an empty array: "embeddedScriptParameters": []'}
|
|
117118
|
+
</WIXCLI_PLANNER_SYSTEM_PROMPT>
|
|
117119
|
+
`;
|
|
117120
|
+
};
|
|
117121
|
+
exports2.plannerPrompt = plannerPrompt;
|
|
117128
117122
|
}
|
|
117129
117123
|
});
|
|
117130
117124
|
|
|
@@ -136488,7 +136482,9 @@ var require_codegen_flow_helpers = __commonJS({
|
|
|
136488
136482
|
return outputDir.startsWith("/") ? outputDir : path_1.default.join(process.cwd(), outputDir);
|
|
136489
136483
|
}
|
|
136490
136484
|
async function getRequiredPermissions(extensions) {
|
|
136491
|
-
const httpClient = (0, http_client_1.createHttpClient)(
|
|
136485
|
+
const httpClient = (0, http_client_1.createHttpClient)({
|
|
136486
|
+
baseURL: "https://manage.wix.com/_api"
|
|
136487
|
+
});
|
|
136492
136488
|
return httpClient.request((0, http_1.getRequiredPermissions)({
|
|
136493
136489
|
relatedApis: getRelatedApis(extensions ?? []),
|
|
136494
136490
|
extensionTypes: getExtensionTypes(extensions ?? [])
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/ditto-codegen-public",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.80",
|
|
4
4
|
"description": "AI-powered Wix CLI app generator - standalone executable",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "node build.mjs",
|
|
@@ -24,5 +24,5 @@
|
|
|
24
24
|
"@wix/ditto-codegen": "1.0.0",
|
|
25
25
|
"esbuild": "^0.25.9"
|
|
26
26
|
},
|
|
27
|
-
"falconPackageHash": "
|
|
27
|
+
"falconPackageHash": "855ad6b5d6b3c026aea6354041ed19744bcde718437d1b74209efc72"
|
|
28
28
|
}
|