为 Power Apps 代码应用接入 SharePoint,支持列表、文档与站点集成
复制安装指令,让 AI 自动完成配置 · 推荐新手
请帮我安装 askskill 上的 "add-sharepoint" 技能: 1. 下载 https://raw.githubusercontent.com/microsoft/power-platform-skills/main/plugins/code-apps/skills/add-sharepoint/SKILL.md 2. 保存为 ~/.claude/skills/add-sharepoint/SKILL.md 3. 装好后重载技能,告诉我可以用了
为我的 Power Apps 代码应用添加 SharePoint Online 连接器,并连接站点中的“项目任务”列表,给出所需配置步骤和示例代码。
返回连接器配置说明、连接列表的方法,以及读取列表数据的示例代码。
帮我在 Power Apps 代码应用中接入 SharePoint 文档库,能够列出文件、上传文档并读取文件元数据,请生成实现示例。
返回文档库接入方案,以及文件查询、上传和元数据读取的示例代码。
在我的 Power Apps 代码应用中添加 SharePoint Online 连接器,并创建一个新的“客户反馈”SharePoint 列表,包含姓名、反馈内容和提交时间字段。
返回创建列表的配置步骤、字段定义建议,以及新建列表的实现示例。
📋 Shared Instructions: shared-instructions.md - Cross-cutting concerns.
References:
Two paths: existing lists (skip to Step 6) or new lists (full workflow).
Check for memory-bank.md per shared-instructions.md.
Ask the user:
If lists already exist: Skip to Step 6.
If creating new lists:
EnterPlanMode, present the list designs with columns and typesExitPlanModeSee api-authentication-reference.md for full details.
az account show # Verify Azure CLI logged in
$api = Initialize-SharePointGraphApi -SiteUrl "https://<tenant>.sharepoint.com/sites/<site-name>"
$headers = $api.Headers
$siteId = $api.SiteId
Requires Sites.Manage.All permission.
Always query existing lists first before creating:
$existingLists = Invoke-RestMethod -Uri "https://graph.microsoft.com/v1.0/sites/$siteId/lists?`$select=id,displayName,description,list&`$filter=list/hidden eq false" -Headers $headers
See list-management-reference.md for Find-SimilarLists, Compare-ListSchemas, and Get-ListSchema functions.
Present findings to user with AskUserQuestion:
Get explicit confirmation before creating. Use safe functions from list-management-reference.md:
New-SharePointListIfNotExistsAdd-SharePointColumnIfNotExistsAdd-SharePointLookupColumn (for cross-list references)Find the SharePoint Online connection ID (see connector-reference.md):
Run the /list-connections skill. Find the SharePoint Online connection in the output. If none exists, direct the user to create one using the environment-specific Connections URL — construct it from the active environment ID in context (from power.config.json or a prior step): https://make.powerapps.com/environments/<environment-id>/connections → + New connection → search for the connector → Create.
List available SharePoint sites the user has access to:
npx power-apps list-datasets -a sharepointonline -c <connection-id>
Present the sites to the user and ask which one(s) they want to connect to. If the user already specified a site URL, confirm it appears in the list.
If npx power-apps list-datasets fails or returns no results:
npx power-apps logout, then retry — the CLI will re-prompt browser login.…
为 Power Apps 代码应用接入 Azure DevOps 连接器,便于查询工单、提报缺陷与管理流水线。
为 Power Apps 代码应用添加 Teams 连接器,实现消息发送与频道协作集成。