You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

DAP迁移至GDAP:寻求替代PartnerCenter命令的Graph API端点

替换PartnerCenter模块cmdlet的Graph API端点方案

针对你提到的两个PowerShell cmdlet,在GDAP模式下可以使用以下Microsoft Graph API端点替代:

1. 替代Get-PartnerAzureBillingAccount

使用GET /billing/billingAccounts端点,调用后返回合作伙伴关联的所有Azure账单账户信息,包含账户ID、名称、账单配置文件等核心数据,与原cmdlet的输出逻辑匹配。

  • 所需权限:BillingAccount.Read.All(需在GDAP租户中分配合作伙伴级权限)
  • 请求示例:
GET https://graph.microsoft.com/v1.0/billing/billingAccounts

2. 替代Set-PartnerAzureBillingPolicy

该cmdlet用于更新指定客户的Azure账单策略,对应的Microsoft Graph端点为PATCH /billing/billingAccounts/{billingAccountId}/customers/{customerId}/policies/default,可设置诸如是否允许客户创建Azure订阅、费用警报阈值等策略项,覆盖原cmdlet的配置功能。

  • 所需权限:CustomerBillingPolicy.ReadWrite.All(需在GDAP租户中分配合作伙伴级权限)
  • 请求示例(以启用客户创建Azure订阅权限为例):
PATCH https://graph.microsoft.com/v1.0/billing/billingAccounts/{billingAccountId}/customers/{customerId}/policies/default
Content-Type: application/json

{
  "allowSubscriptionCreation": true
}

注意:调用前需确保身份已通过GDAP授权,且拥有对应权限范围;{billingAccountId}需替换为合作伙伴的实际账单账户ID,{customerId}替换为目标客户的租户ID或客户ID。

内容的提问来源于stack exchange,提问作者Quinn Favo

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.01 02:31:16