使用Microsoft Graph API我可以在执行时看到我的组织的 Contract :
https://graph.microsoft.com/v1.0/contracts
以下示例回复:
"value": [
{
"id": "107adc54-f77c-4b8b-9cc0-1759e8d0cdfer",
"deletedDateTime": null,
"contractType": "2",
"customerId": "75ace3eb-6bf4-4655-95fd-f3d0610924789",
"defaultDomainName": "test.onmicrosoft.com",
"displayName": "Test Me"
}
如何通过Graph API查询上述 Contract 的subscribedskus . 这有可能吗?
我试过了
https://graph.microsoft.com/v1.0/test.onmicrosoft.com/subscribedSkus
但它返回我的组织订阅的skus而不是 test.onmicrosoft.com
订阅的skus .
请协助 .
1 回答
让我根据过去几天我一直在做的研发来回答这个问题 . 我不认为Microsoft Graph API目前支持 Contracts 对象上的任何其他操作,因为 Contract 文档链接https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/resources/contract仅列出了2种方法 Get contract 和 List contracts
截至目前,获取每个 Contract 的订阅skus的唯一选项是使用相应的tenantid访问每个租户的azure广告实例(使用 endpoints https://login.microsoftonline.com/<tenantid>/oauth2/token获取访问令牌并触发REST调用https://graph.microsoft.com/v1.0/subscribedSkus)