consumer-goods-rtr-datacloud-export-configure
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSetup RTR Data Cloud Export
设置RTR Data Cloud导出
Configures the Data-Cloud-targeted RTR exports: the system setting, a scoped SF Data Sync, an record (with its ) for Data Cloud export, and the export trigger/status/abort REST calls. Standalone and self-contained — runs on its own, or as a delegated step invoked by , which passes through its own already-collected username, dry-run flag, and GenieAdmin confirmation result.
Data_Cloud_EnabledRTR_Report_Configuration__cKPI_Set__cconsumer-goods-tpe-dashboard-configureDistinct from a sibling CSV-export RTR skill (if present in this org's checkout): that skill targets for CSV export to the CGCloud Processing Services host. This skill targets Data Cloud export. Same underlying object and Apex patterns, different values and shape — this skill does not invoke or depend on that sibling.
Usage__c IN ('integrationmeta','reportmeta')RTR_Report_Configuration__cKPI_Set__cUsage__cJSON__cFor now, this skill only supports () — it is hardcoded, never asked as an input. (account-plan measures) is not yet wired up.
Usage__c = 'datacloudpromotionmeasuresmeta'JSON__c.object = "promotionmeasures"datacloudaccountplanmeasuresmeta配置面向Data Cloud的RTR导出:系统设置、范围化SF Data Sync、用于Data Cloud导出的记录(及其),以及导出触发/状态/中止REST调用。本技能独立且自包含——可单独运行,也可作为由调用的委托步骤,该调用会传递其已收集的用户名、试运行标志和GenieAdmin确认结果。
Data_Cloud_EnabledRTR_Report_Configuration__cKPI_Set__cconsumer-goods-tpe-dashboard-configure与同级CSV导出RTR技能不同(如果本组织的检查项中存在该技能):该技能针对,用于将CSV导出到CGCloud Processing Services主机。而本技能针对Data Cloud导出。两者基于相同的对象和 Apex模式,但值和结构不同——本技能不会调用或依赖该同级技能。
Usage__c IN ('integrationmeta','reportmeta')RTR_Report_Configuration__cKPI_Set__cUsage__cJSON__c目前,本技能仅支持()——此为硬编码设置,不会作为输入询问用户。(客户计划指标)尚未接入。
Usage__c = 'datacloudpromotionmeasuresmeta'JSON__c.object = "promotionmeasures"datacloudaccountplanmeasuresmetaInputs and namespace detection
输入与命名空间检测
Read before starting. It covers:
references/inputs-and-namespace.md- The username/dry-run/GenieAdmin/TPM-Admin/namespace inputs that must be collected (or passed through by a calling skill) before Phase 1.
- The Sales Org / KPI Set / measure-codes / date-from inputs that Phase 6 collects lazily, per Sales Org, only once its existing-config check comes back empty.
- The namespace-detection procedure () and the four
scripts/detect-namespace.js/NS/NS_SEGMENT/NS_APEXderivations used throughout every phase below.NS_FIELD - (Apex template rendering) and
scripts/render-apex.js(name-to-id lookups) both loadscripts/resolve-id-by-name.jsto escape substituted/queried literals for safe SOQL/Apex interpolation.scripts/soql-escape.js
开始前请阅读,其中涵盖:
references/inputs-and-namespace.md- 第1阶段前必须收集(或由调用技能传递)的用户名/试运行/GenieAdmin/TPM-Admin/命名空间输入项。
- 第6阶段针对每个销售组织延迟收集的销售组织/KPI集/指标代码/起始日期输入项,仅当现有配置检查结果为空时才会收集。
- 命名空间检测流程(),以及以下所有阶段中使用的四个派生值
scripts/detect-namespace.js/NS/NS_SEGMENT/NS_APEX。NS_FIELD - (Apex模板渲染)和
scripts/render-apex.js(名称转ID查询)均加载scripts/resolve-id-by-name.js,对替换/查询的字面量进行转义,以确保SOQL/Apex插值的安全性。scripts/soql-escape.js
Phases
阶段
Full step-by-step commands, queries, and Apex templates for every phase are in . Run phases in order.
references/procedure.md| Phase | Summary |
|---|---|
| 1 | Verify/assign |
| 2 | Upsert the |
| 3 | Trigger a scoped SF Data Sync against |
| 4 | Poll/verify that sync completed ( |
| 5 | Verify the |
| 6 | Loop, one Sales Org at a time: resolve Sales Org Name → Id, reuse an existing |
| 7 | Once Phase 6's loop is fully done, trigger the export once per configured Sales Org via |
| 8 | Poll each Sales Org's export status ( |
| 9 | Once every Sales Org has finished polling, ask the user to sync the |
| 10 | Abort an in-flight export via |
| 11 | Report pass/blocked/pending per phase. |
每个阶段的完整分步命令、查询和Apex模板均位于中。请按顺序运行各阶段。
references/procedure.md| 阶段 | 摘要 |
|---|---|
| 1 | 验证/分配 |
| 2 | 通过匿名Apex插入或更新 |
| 3 | 在捕获基准 |
| 4 | 轮询/验证同步是否完成(状态为 |
| 5 | 验证 |
| 6 | 循环处理每个销售组织:将销售组织名称解析为ID,重用现有 |
| 7 | 第6阶段循环完成后,通过 |
| 8 | 通过 |
| 9 | 所有销售组织的轮询完成后,要求用户手动同步 |
| 10 | 通过 |
| 11 | 按阶段报告通过/阻塞/待处理状态。 |
Rules
规则
- Never assign a permission set, write a record, or trigger a sync/export without an explicit user go-ahead first.
- Never guess or hardcode — identify the sync's
Batch_Name__crow by recency against the captured baseline Id, and log the full row set.Batch_Run_Status__c - Never attempt to programmatically add a missing picklist value — the user must add it manually via Setup (link in Phase 5,
Usage__c).references/procedure.md - Never ask for a Usage type — this skill is hardcoded to /
Usage__c = 'datacloudpromotionmeasuresmeta'for now.JSON__c.object = "promotionmeasures" - When the requested export type is anything other than promotion measures (e.g. /account-plan measures): state the limitation, then stop or ask if the user wants the promotion-measures export instead for that Sales Org. Do not provide field-by-field manual configuration instructions for the unsupported path — no suggested
datacloudaccountplanmeasuresmeta/Usage__cvalues, no picklist-add walkthrough. Offering a workaround recipe for the exact path this skill refuses is scope creep, not help. Report the run as blocked, not partially-passed.JSON__c - Never skip Phase 6's existence check (keyed on +
Usage__c) — and never overwrite an existingSales_Organization__cfound by that check without a separate, explicit user go-ahead.RTR_Report_Configuration__c - Never trigger Phase 7's export before Phase 6's per-Sales-Org loop is fully done — always ask whether to add another Sales Org before moving from Phase 6 to Phase 7.
- Always give the user a chance to supply a custom (Phase 6 step 4) — default to
Internal_Name__c(no hyphen) only if they decline. This value is also"Data 360 Promotion Measures Export <Sales Org Name>"in Phase 7's export — never invent a different one for that call.metaname - Phase 7 exports once per Sales Org, never once for the whole run.
- Both the Sales Org and the KPI Set are given as Names by the user, resolved to Ids by query — this skill never creates a , a
Sales_Organization__c, or KPI Set junction rows.KPI_Set__c - Never sync a Sales Org's config in Phase 6 unless this run actually created it — reusing an existing config as-is is a no-op, no sync call.
- Never call the abort endpoint unless the user explicitly asks to abort.
- Never claim Phase 9 is done on Phase 8's status alone — always get the user's explicit confirmation that the
ReadyData Stream was synced, once for the whole batch, before moving to Phase 10.promotionmeasures - Never hardcode the namespace in a REST path, Apex snippet, or SOQL query — always use the caller-passed or self-detected /
NS/NS_SEGMENT/NS_APEX.NS_FIELD - This skill only calls Apex classes, REST endpoints, or the anonymous-Apex templates in its own
globaldirectory — never ascripts//publicmethod directly, and never a script or template from outside this skill's own directory.private
- 未经用户明确许可,绝不分配权限集、写入记录或触发同步/导出操作。
- 绝不猜测或硬编码——根据捕获的基准ID,按最新性识别同步的
Batch_Name__c行,并记录完整行集。Batch_Run_Status__c - 绝不尝试通过程序化方式添加缺失的选择列表值——用户必须通过Setup手动添加(第5阶段和
Usage__c中的链接)。references/procedure.md - 绝不询问使用类型——目前本技能硬编码为/
Usage__c = 'datacloudpromotionmeasuresmeta'。JSON__c.object = "promotionmeasures" - 当请求的导出类型为促销指标以外的类型(例如/客户计划指标):说明限制,然后停止操作或询问用户是否要为该销售组织改为使用促销指标导出。不得为不支持的路径提供逐字段手动配置说明——不得建议
datacloudaccountplanmeasuresmeta/Usage__c值,不得提供选择列表添加步骤。为技能拒绝的路径提供变通方案属于超出范围,并非帮助。将运行状态报告为阻塞,而非部分通过。JSON__c - 绝不跳过第6阶段的存在性检查(基于+
Usage__c)——且未经用户单独明确许可,绝不覆盖通过该检查找到的现有Sales_Organization__c。RTR_Report_Configuration__c - 第6阶段的销售组织循环完全完成前,绝不触发第7阶段的导出——从第6阶段进入第7阶段前,始终询问是否添加其他销售组织。
- 始终给用户提供自定义的机会(第6阶段第4步)——仅当用户拒绝时,默认使用
Internal_Name__c(无连字符)。该值同时也是第7阶段导出中的"Data 360 Promotion Measures Export <Sales Org Name>"——绝不为该调用创建其他值。metaname - 第7阶段为每个销售组织导出一次,绝不针对整个运行过程导出一次。
- 销售组织和KPI集均由用户提供名称,通过查询解析为ID——本技能绝不创建、
Sales_Organization__c或KPI集关联行。KPI_Set__c - 仅当本次运行实际创建了销售组织的配置时,才在第6阶段同步该配置——按原样重用现有配置为无操作,无需调用同步。
- 仅当用户明确要求中止时,才调用中止端点。
- 绝不仅根据第8阶段的状态就宣称第9阶段已完成——在进入第10阶段前,始终获取用户明确确认
Ready数据流已同步(针对整个批次确认一次)。promotionmeasures - 绝不硬编码REST路径、Apex片段或SOQL查询中的命名空间——始终使用调用方传递或自行检测的/
NS/NS_SEGMENT/NS_APEX。NS_FIELD - 本技能仅调用Apex类、REST端点或自身
global目录中的匿名Apex模板——绝不直接调用scripts//public方法,也绝不使用本技能目录以外的脚本或模板。private
Report
报告
At the end of a run, give the user a structured status per phase (1-10): pass / blocked / pending, with the specific blocking reason and remediation click-path where applicable (e.g. the Setup path for a missing picklist value). Call out anything skipped due to dry-run or a declined confirmation.
When invoked via delegation (the calling skill used the tool to reach this file, rather than the user directly): this report is an intermediate result, not the end of the task. Return it to the calling skill and let it continue with its own next phase — do not present this report to the user as the final answer and stop. Only surface this report directly to the user when this skill was invoked standalone.
Skill运行结束时,向用户提供按阶段(1-10)划分的结构化状态:通过/阻塞/待处理,以及具体的阻塞原因和相应的修复路径(例如,缺失选择列表值的Setup路径)。标注因试运行或用户拒绝确认而跳过的任何操作。
当通过委托调用时(调用技能使用工具访问本文件,而非用户直接调用):本报告为中间结果,并非任务终点。需将其返回给调用技能,由该技能继续执行自身的下一阶段——不得将本报告作为最终答案呈现给用户并停止操作。仅当本技能被独立调用时,才直接向用户展示本报告。
Skill