跳到主内容
智客 ZICQ

技能库 智客分类:Agent 工作流 automation-flow-generate

Automation Flow Generate

生成销售力 使用 MCP 工具的流程执行_ metata_ action. 当用户要求创建,构建,或生成一个流时使用——包括Screen,Auto surveting,Record-Triggered(保存前/保存后), Schannex. 还触发了类似流程的请求, 如 \ “ 当创建记录\ ” 、\ “ 每天在\ 时触发 ” 、\ “ 当\ 时发送电子邮件 ” 、 “ 当\ 时更新字段 ” 、 “ 自动 ” 、 “ 工作流程\ ” , 或\ “ flow XML/ metata\ ” 等 。 这是销售力量流动的唯一技能.

5824 安装量

官方网址:skills.sh

技能介绍

先看中文介绍;官方 description 原文单独保留,不改写 SKILL.md。

做什么

生成销售力 使用 MCP 工具的流程执行_ metata_ action

何时用

这个技能

代理如何加载

按 Agent Skills 渐进披露:启动时只加载 name 与 description(约 100 token);任务匹配后才读入整份 SKILL.md 正文;scripts/、references/、assets/ 仅在需要时再读。 本文件正文结构:Goal、When to Use This Skill、Specification、Flow Metadata Specification、Overview、Flow Generation Pipeline。 其中含规范建议的小节:分步指令。

文件分析

文件分析:这是一份仅含 SKILL.md 的指令型技能,代理激活后整份正文进入上下文。

官方 description(原文)

Generate Salesforce Flows using the MCP tool execute_metadata_action. Use when the user asks to create, build, or generate a flow — including Screen, Autolaunched, Record-Triggered (before/after-save), Scheduled. Also trigger for flow-like requests such as \"when a record is created\", \"trigger daily at\", \"send an email when\", \"update the field when\", \"automate\", \"workflow\", or \"flow XML/metadata\". This is the only skill for Salesforce Flow generation.

GoalWhen to Use This SkillSpecificationFlow Metadata SpecificationOverviewFlow Generation PipelineMCP Connection DetailsStep 1 (REQUIRED): Fetch Grounded Object Metadata (`fetchGroundedObjectMetadata`)Step 2 (REQUIRED): Flow Element Selection (`flowElementSelection`)Step 3 (REQUIRED): Flow Element Generation (`flowElementGeneration`)inflightMetadata FormatMANDATORY Decision Logic for inflightMetadata (DATA TYPE: ARRAY)

来源分类:skills.sh agent-skill

SKILL.md 与 Agent 调用

官方规范 ↗
name
automation-flow-generate
description
Generate Salesforce Flows using the MCP tool execute_metadata_action. Use when the user asks to create, build, or generate a flow — including Screen, Autolaunched, Record-Triggered (before/after-save), Scheduled. Also trigger for flow-like requests such as \"when a record is created\", \"trigger daily at\", \"send an email when\", \"update the field when\", \"automate\", \"workflow\", or \"flow XML/metadata\". This is the only skill for Salesforce Flow generation.
  1. 发现技能客户端向 Agent 提供名称与描述目录。
  2. 匹配与调用用户指定或任务匹配后,载入 SKILL.md 指令。
  3. 按需加载按步骤读取参考文档、使用脚本与素材。

具体调用语法与可用工具以目标 Agent 客户端为准。 查看调用机制说明 ↗

安装这个技能

Skills CLI ↗

先选择目标 Agent 和安装范围,保留技能包的附属文件,安装后检查客户端能否发现该技能。

交给 Agent 安装

复制安装指令给支持 Agent Skills 的代理,确认其中的目标目录与客户端匹配。

把 Agent Skill「automation-flow-generate」安装到我的项目:SKILL.md 原文与官方 description 见 https://zicq.com/zh/skills/skl-5ea711e6b2a32828-%E8%87%AA%E5%8A%A8%E6%B5%81%E7%A8%8B%E7%94%9F%E6%88%90.html
请存为 .cursor/skills/automation-flow-generate/SKILL.md 或 .claude/skills/automation-flow-generate/SKILL.md,frontmatter 的 name 与 description 保持原样,不要改写。

GitHub 完整包 ↗

终端安装 · Skills CLI

需要 Node.js 与 npx。先查看仓库技能列表,确认实际名称。

npx skills add 'https://github.com/forcedotcom/sf-skills' --list

npx skills add 'https://github.com/forcedotcom/sf-skills' --skill 'automation-flow-generate'

CLI 会交互选择目标 Agent,默认安装到项目;用户级安装使用 -g。先通过查看命令核对仓库内容,再用 npx skills list 检查已安装技能。

阅读排版
--- name: automation-flow-generate description: "Generate Salesforce Flows using the MCP tool execute_metadata_action. Use when the user asks to create, build, or generate a flow — including Screen, Autolaunched, Record-Triggered (before/after-save), Scheduled. Also trigger for flow-like requests such as \"when a record is created\", \"trigger daily at\", \"send an email when\", \"update the field when\", \"automate\", \"workflow\", or \"flow XML/metadata\". This is the only skill for Salesforce Flow generation." metadata: version: "1.1" domains: ["Automation"] minApiVersion: "60.0" mcpTools: metadata-experts: tools: ["execute_metadata_action"] semver: ">=1.0.0" --- ## Goal Generate Salesforce Flow metadata by running the required 3-step MCP pipeline (fetchGroundedObjectMetadata → flowElementSelection → flowElementGeneration) and return the flow XML. ## When to Use This Skill Use this skill when you need to: - Create any type of Flow (Screen, Autolaunched, Record-Triggered, Scheduled) - Generate Flow metadata XML - Automate business processes without code - Build user-guided workflows or background automation - Troubleshoot deployment errors related to Flows ## Specification # Flow Metadata Specification ## Overview Salesforce Flows are powerful automation tools that enable complex business process automation without code. Flows can collect and process data through interactive screens, execute logic and calculations, manipulate records, call external services, and trigger based on various events. Flow types include Screen Flows (user-guided), Autolaunched Flows (background processing), Record-Triggered Flows (database events) and Scheduled Flows (time-based). ## Flow Generation Pipeline **MANDATORY: You MUST follow this exact 3-step pipeline. No exceptions. No shortcuts. No skipping steps. Do NOT manually create flow metadata XML or attempt to generate flow metadata outside of this pipeline. Do NOT attempt to use any other tool, API, or method to generate flow metadata. This pipeline is the ONLY supported way to generate flows. Any deviation will produce invalid or broken metadata.** ### MCP Connection Details **All 3 pipeline steps MUST be called using this MCP tool:** - **MCP Tool Name:** `execute_metadata_action` - **The `action` parameter** selects which pipeline step to run: `"fetchGroundedObjectMetadata"`, `"flowElementSelection"`, or `"flowElementGeneration"` Flow generation is a **strict 3-step pipeline**. ALL steps must be called in order. Every step is required. **There is no alternative approach — this is the only way to generate flow metadata:** ### Step 1 (REQUIRED): Fetch Grounded Object Metadata (`fetchGroundedObjectMetadata`) Fetches org schema metadata relevant to the flow generation request. This step is **mandatory** and must always be called first. **Inputs (all required):** - **userPrompt** (STRING, REQUIRED): The user's natural language request - **inflightMetadata** (ARRAY, REQUIRED): Custom objects/fields from local sfdx project. Use empty array `[]` if none needed. **Outputs:** - **groundingMetadata** (STRING): Grounded object metadata for org schema relevant to the request, returned as a JSON string. **You must pass this directly to Step 2 — it is already a string and does not need to be serialized again.** ### Step 2 (REQUIRED): Flow Element Selection (`flowElementSelection`) Selects flow elements (assignments, decisions, record ops, etc.) and their connections based on the user prompt and grounded metadata. This step is **mandatory** and must be called after Step 1. **Inputs (all required):** - **userPrompt** (STRING, REQUIRED): The user's natural language request (**must be the same value as Step 1**) - **groundingMetadata** (STRING, REQUIRED): Org schema metadata (**must be the exact string returned from Step 1 output** — pass it directly, do NOT serialize it again) - **operationId** (STRING, REQUIRED): Operation ID (use empty string `""` for first call) **Outputs:** - **operationId** (STRING): Operation ID. **You must pass this to Step 3.** - **userOutput** (STRING): Reasoning for next steps. You can show this to the user. ### Step 3 (REQUIRED): Flow Element Generation (`flowElementGeneration`) Generates flow metadata element by element. This step is **mandatory** and must be called after Step 2. **Must be called repeatedly in a loop until `isComplete` is `true`.** **Inputs (all required):** - **operationId** (STRING, REQUIRED): Operation ID **from Step 2 output** - **requestSource** (STRING, REQUIRED): The source of the request. Use **`"A4V"`** to get flow metadata in XML format. **Outputs:** - **isComplete** (BOOLEAN): Indicates if the flow generation is complete. **You must check this value.** - **result** (STRING): Result of the flow element generation. Contains the final flow metadata **only when `isComplete` is `true`**. **MANDATORY: Loop until complete. NEVER pause or ask the user to confirm continuation.** - A flow can have **any number of elements**. Each call generates one element at a time, so you may need **many** iterations. - Call `flowElementGeneration` with the `operationId` from Step 2 and `requestSource` (use `"A4V"` for XML output, empty string or other value for JSON). - Check the `isComplete` output and the `result` field after each call. - If `isComplete` is `false` **and no errors are returned**, you **MUST** call `flowElementGeneration` again with the **same `operationId`** from Step 2. **Do NOT ask the user if they want to continue. Do NOT pause. Do NOT summarize progress mid-loop. Just keep calling** — there is **no maximum** number of iterations. - When `isComplete` is `true`, extract the flow metadata from the `result` field. - If errors are returned, stop the loop and surface the error to the user. **STRICT CONSTRAINTS (CRITICAL) — These rules apply to the XML returned by the generation pipeline:** - DO NOT modify the content, values, or child nodes inside any block. - DO NOT add new nodes, tags, attributes, or text (do not add missing labels, X/Y coordinates, etc.). - DO NOT remove any existing nodes. **Canvas mode.** A net-new canvas-based flow needs a `` `CanvasMode`=`AUTO_LAYOUT_CANVAS` entry (independent of `BuilderType`) or it opens in **Free-Form**. STRICT CONSTRAINTS forbid hand-editing the XML, so this must come from the generation pipeline — if the returned XML lacks it, surface a pipeline gap; do NOT hand-edit. (Non-canvas types like `CustomerLifecycle` carry none — don't flag those.) ## inflightMetadata Format **DATA TYPE: ARRAY (not string)** **STRICT NAMING CONVENTION - MUST FOLLOW EXACTLY:** | Property | Correct Name | Do NOT Use | |----------|-------------|---------------| | Object API name | `apiName` | `objectApiName`, `name`, `objectName` | | Field API name | `apiName` | `fieldApiName`, `name`, `fieldName` | | Field type | `type` | `fieldType`, `dataType` | | Lookup target | `referenceTo` | `relatedTo`, `lookupTo`, `reference` | When custom objects are needed (sample format showing multiple field data types): ```json [ { "type": "CustomObject", "apiName": "CustomerRequest__c", "label": "Customer Request", "fields": [ { "apiName": "Status__c", "type": "Picklist", "label": "Status", "values": ["New", "In Progress", "Completed"] }, { "apiName": "Priority__c", "type": "Number", "label": "Priority" }, { "apiName": "AssignedTo__c", "type": "Lookup", "label": "Assigned To", "referenceTo": "User" }, { "apiName": "Description__c", "type": "Textarea", "label": "Description" }, { "apiName": "Email__c", "type": "Email", "label": "Contact Email" }, { "apiName": "DueDate__c", "type": "Date", "label": "Due Date" }, { "apiName": "IsUrgent__c", "type": "Boolean", "label": "Is Urgent" }, { "apiName": "Amount__c", "type": "Currency", "label": "Amount" } ], "relationships": [] } ] ``` **Supported field types**: Text, Textarea, Number, Picklist, Lookup, Email, Phone, URL, Date, Datetime, Boolean, Checkbox, Currency, Percent When no custom objects needed: ```json [] ``` ### MANDATORY Decision Logic for inflightMetadata (DATA TYPE: ARRAY) 1. **REQUIRED - First**: Scan the local sfdx project for custom objects and fields that are relevant to the user's flow request. 2. **If relevant custom objects ARE found**: You MUST extract and pass them as an array of structured objects (see format above) 3. **If NO relevant custom objects found**: You MUST pass an empty array `[]` (NOT the string `"[]"`) 4. **NEVER**: Pass text descriptions, instructions, or string representations in inflightMetadata 5. **MANDATORY**: The data type MUST be ARRAY, not STRING **Instructions for Vibes when custom objects ARE relevant:** - Extract the object metadata and map to JSON properties: - `apiName`: The object's API name (with `__c` suffix for custom objects) - `label`: The object's display label - `type`: Set to `"CustomObject"` - `fields`: Array of field objects, each containing: - `apiName`: The field's API name (with `__c` suffix for custom fields) - `type`: The field type (Text, Number, Picklist, Lookup, etc.) - `label`: The field's display label - `values`: (Picklist only) Array of picklist values - `referenceTo`: (Lookup only) The target object API name - Include only objects and fields that are relevant to the flow being generated ## Mandatory Enhancement Rules - **userPrompt**: REQUIRED. - If the user requests a **single flow**: use the user's prompt as-is. - If the user requests **multiple flows**: you MUST **split** the request and write a **separate, focused `userPrompt` for each individual flow**. Each `userPrompt` must describe only ONE flow. Do NOT pass the entire multi-flow request as a single `userPrompt`. See the multiple flows section below for examples. - **inflightMetadata**: REQUIRED. Always use ARRAY data type. - MUST use `[]` (empty array) when no custom objects needed - MUST use structured array of objects when custom objects are relevant - NEVER use string `"[]"` - this is incorrect - NEVER use text descriptions - only structured object metadata ## Flow Pattern Guidance The pipeline selects flow elements from your `userPrompt`. Vague prompts lead the pipeline to pick wrong structures, producing metadata that fails deployment. When the request matches one of the patterns below, make the intent explicit in the `userPrompt` you pass to Step 1 and Step 2 so the pipeline selects the correct elements. ### Scheduled flows ("daily", "weekly", "every Sunday", "runs once a week at 10PM") A recurring, time-based flow is a **Scheduled** flow. The schedule lives on the **start element**: `triggerType` is `Scheduled` and a `` block holds `` (e.g. `Weekly`), ``, and ``. Do NOT expect `startDate`/`startTime` on a `FlowScheduledPath` element — a scheduled flow's cadence is on ``, not a scheduled path. To select records for a scheduled flow, put the record criteria in the **start element's filters** (with `

相关技能

Agent 工作流

Skill Creator

创造有效技能指南。 当用户想创造出新的技能(或更新现有的技能),以专业知识,工作流程,或工具集成来扩展克洛德的能力时,应该使用这种技能.

Agent 工作流

Clawdhub

使用ClawdHub CLI搜索,安装,更新并发布从taladhub.com的代理技能. 需要获取苍蝇上的新技能时使用,将安装的技能同步到最新版本或特定版本,或者发布 npm-instainddhub CLI 的新/更新的技能文件夹.

Agent 工作流

Agent Team Orchestration

管弦乐团多代理团队,任务设定周期,交接协议,审查工作流程. 使用时间: (1)建立2+特派员队伍,具有不同专业,(2)确定任务路线和生命周期(收录框_ spec_建设_审查_完成),(3)在特派员之间制定交接协议,(4)建立审查和质量关口,(5)管理特派员之间的交流和文物共享.

Agent 工作流

Superpowers

Spec-first,TDD,子代理驱动的软件开发工作流程. 当:(1)构建任何新功能或应用——触发脑暴_计划_子代理执行回路,(2)调试出一个bug或测试失败——触发系统性的根起过程,(3)用户说"让我们构建","帮助我计划","我想添加X",或"这个被打破",(4)完成一个功…