platform-custom-lightning-type-generate

Generates Salesforce Custom Lightning Type schemas, editor configs, and renderer configs for Einstein Agent actions.

Updated Jul 2, 2026
One-click install
npx skills add https://github.com/padjei/SF_Build --skill platform-custom-lightning-type-generate-padjei
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: platform-custom-lightning-type-generate
Source: https://github.com/padjei/SF_Build/tree/main/.claude/skills/platform-custom-lightning-type-generate
Command: npx skills add https://github.com/padjei/SF_Build --skill platform-custom-lightning-type-generate-padjei

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) and assets (resource) components.

What problem does it solve? Creating Custom Lightning Types (CLTs) for Salesforce Einstein Agent actions requires strict adherence to a metaschema with many non-obvious validation rules, and small mistakes like including $schema or items cause deployment failures. This Skill encodes the full CLT specification, generation workflow, and error-fix mappings so deployments validate on the first attempt. ## Core Features & Use Cases - Schema Generation: Produces valid schema.json files with correct root object structure, primitive lightning:type identifiers, CLT references (c__<CLTName>), and Apex class types (@apexClassType/...). - Editor & Renderer Configs: Creates editor.json and renderer.json using componentOverrides and layout patterns, including widget/mosaic rendition via a dedicated UEM workflow. - Deployment Troubleshooting: Maps common validation errors (unknown keywords, invalid targets, attribute mapping mismatches) to concrete fixes. - Use Case: When building an Einstein Agent action that returns structured output, use this Skill to generate the CLT bundle under lightningTypes/<TypeName>/ with schema, editor, and renderer files that pass org validation. ## Quick Start Ask the AI to create a Custom Lightning Type schema for an Einstein Agent action with the fields you need, and it will generate a deployable CLT bundle.

Frequently Asked Questions about platform-custom-lightning-type-generate

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a Custom Lightning Type for Einstein Agent actions?▼

Create a schema.json with type object, title, lightning:type set to lightning__objectType, and unevaluatedProperties false, then place it in lightningTypes/<TypeName>/. Add editor.json and renderer.json under lightningDesktopGenAi/ only when custom UI is needed.

Why does my Custom Lightning Type schema fail validation?▼

Common causes are including the $schema field, using the items keyword on arrays, adding examples with strict validation, or setting lightning:type on nested objects. Remove the offending keyword and keep the schema minimal since unknown keywords fail when unevaluatedProperties is false.

How do I reference another CLT or Apex class in a schema?▼

Use lightning:type set to c__<CLTName> to reference another deployed Custom Lightning Type, or @apexClassType/namespace__ClassName for server-side Apex structures. The referenced CLT must be deployed to the org before the parent CLT.

Can I use arrays in Custom Lightning Type schemas?▼

Arrays are heavily restricted: root-level arrays must use lightning__listType without items, and nested arrays must only include type array with no lightning:type or items. The CLT metaschema may reject the items keyword entirely.

Why does my custom LWC fail as a CLT editor or renderer component?▼

The component's js-meta.xml file is missing the required target configuration. Add lightning__AgentforceInput for editor components and lightning__AgentforceOutput for renderer components, otherwise deployment fails with an invalid target configuration error.

How do I build a widget or mosaic rendition for a CLT?▼

Follow the widget-rendition workflow: parse the CLT schema, discover available UEM blocks via discoverUiComponents, fetch component schemas with getUiComponentSchemas, then build the UEM tree into renderer.componentOverrides with definition tile/mosaic. Bind data using {!$attrs.propertyName} placeholders.