为 Dataverse 表批量生成示例记录,便于测试和演示 Power Pages 站点。
复制安装指令,让 AI 自动完成配置 · 推荐新手
请帮我安装 askskill 上的 "add-sample-data" 技能: 1. 下载 https://raw.githubusercontent.com/microsoft/power-platform-skills/main/plugins/power-pages/skills/add-sample-data/SKILL.md 2. 保存为 ~/.claude/skills/add-sample-data/SKILL.md 3. 装好后重载技能,告诉我可以用了
请为我的 Power Pages 站点相关的 Dataverse 表生成一批演示数据,包括联系人、订单和支持工单,每张表各插入 20 条记录,并保证字段值看起来真实、彼此有关联。
向指定 Dataverse 表写入一组结构合理、可用于演示页面效果的示例记录。
请为测试环境中的 Dataverse 表插入种子数据,重点覆盖不同状态、日期范围和必填字段组合,方便我测试 Power Pages 表单和列表页面。
生成覆盖多种测试场景的种子记录,帮助验证页面展示与交互逻辑。
帮我向 Dataverse 中的客户、项目和发票表添加示例业务数据,用于销售演示。请确保客户与项目、项目与发票之间存在合理关联。
插入一批具备业务关联的示例数据,可直接用于销售或产品演示。
Plugin check: Run
node "${CLAUDE_PLUGIN_ROOT}/scripts/check-version.js"— if it outputs a message, show it to the user before proceeding.
Populate Dataverse tables with sample records via OData API so users can test and demo their Power Pages sites.
Initial request: $ARGUMENTS
Goal: Confirm PAC CLI auth, acquire an Azure CLI token, and verify API access
Actions:
${CLAUDE_PLUGIN_ROOT}/references/dataverse-prerequisites.md to verify PAC CLI auth, acquire an Azure CLI token, and confirm API access. Note the environment URL as for subsequent script calls.<envUrl>Output: Authenticated session with valid token and confirmed API access
Goal: Find the custom tables available in the user's Dataverse environment
Actions:
.datamodel-manifest.json (Preferred)Check if .datamodel-manifest.json exists in the project root (written by the setup-datamodel skill). If it exists, read it -- it already contains table logical names, display names, and column info.
See ${CLAUDE_PLUGIN_ROOT}/references/datamodel-manifest-schema.md for the full manifest schema.
If no manifest exists, discover custom tables via OData:
node "${CLAUDE_PLUGIN_ROOT}/scripts/dataverse-request.js" <envUrl> GET "EntityDefinitions?\$select=LogicalName,DisplayName,EntitySetName&\$filter=IsCustomEntity eq true"
For each discovered table, fetch its custom columns:
node "${CLAUDE_PLUGIN_ROOT}/scripts/dataverse-request.js" <envUrl> GET "EntityDefinitions(LogicalName='<table>')/Attributes?\$select=LogicalName,DisplayName,AttributeType,RequiredLevel&\$filter=IsCustomAttribute eq true"
Show the user the list of discovered tables with their columns so they can choose which to populate.
Output: List of discovered tables with their columns presented to the user
Goal: Gather user preferences on which tables to populate and how many records to create
Actions:
Use AskUserQuestion to ask which tables they want to populate (use multiSelect: true). List all discovered tables as options.
Use AskUserQuestion to ask how many sample records per table:
| Option | Description |
|---|---|
| 5 records | Quick test -- just enough to verify the setup |
| 10 records | Light demo data for basic testing |
| 25 records | Fuller dataset for realistic demos |
| Custom | Let the user specify a number |
Analyze relationships between selected tables. Parent/referenced tables must be inserted first so their IDs are available for child/referencing table lookups.
Build the insertion order:
Output: Confirmed table selection, record count, and insertion order
Goal: Generate contextually appropriate sample records and get user approval before inserting
Actions:
…
为 Power Apps 代码应用接入 Azure DevOps 连接器,便于查询工单、提报缺陷与管理流水线。
帮助你将 Power Pages Web API 集成到前端,并完成权限配置与部署上线。