다음 샘플 쿼리는
이러한 쿼리를 실행하는 방법
Azure Resource Graph 인터페이스에서 이러한 쿼리를 실행할 수 있습니다. 단계별 지침은 다음 빠른 시작 가이드를 참조하세요.
- Azure 포털을 사용하여 Resource Graph 쿼리 실행
- Azure CLI를 사용하여 Resource Graph 쿼리 실행
- Azure PowerShell 사용하여 Resource Graph 쿼리 실행
- REST API를 사용하여 Azure Resource Graph 쿼리 실행
개수 및 분포
모든 리소스의 총 수
PowerPlatformResources
| count
리소스 종류별 총 개수
PowerPlatformResources
| summarize resourceCount = count() by type
| order by resourceCount
환경별 개수
PowerPlatformResources
| extend properties = parse_json(properties)
| extend environmentId = tostring(properties.environmentId)
| summarize resourceCount = count() by environmentId
| order by resourceCount desc
지역별 개수
PowerPlatformResources
| summarize resourceCount = count() by location
| order by resourceCount desc
항목 수별 상위 소유자
PowerPlatformResources
| extend properties = parse_json(properties)
| extend ownerId = tostring(properties.ownerId)
| summarize resourceCount = count() by ownerId
| order by resourceCount desc
리소스 조회
테넌트에서 단일 에이전트 찾기
PowerPlatformResources
| where type == "microsoft.copilotstudio/agents"
| where name == "[Enter the agent's ID]"
Tip
에이전트를 볼 때 Copilot Studio URL 또는 인벤토리 테이블의 이름 열에서 에이전트의 ID를 찾을 수 있습니다.
하네스별 에이전트 수 계산
Microsoft Copilot 하네스, Copilot Chat 하네스 또는 표준 하네스를 사용하여 만든 에이전트의 분석을 보여 줍니다.
Power Platform 관리 센터의 Harness 열에서 관리>Copilot Studio 아래에 있는 에이전트의 하네스를 볼 수 있습니다. 해당 열은 사용자 인터페이스 열에만 해당합니다. Harness는 아직 에이전트 메타데이터로 반환되지 않으므로 이 쿼리는 인벤토리가 반환하는 필드에서 파생합니다. properties.isCLIAgentproperties.modelproperties.createdIn
properties.harness 필드를 사용할 수 있게 되면 대신 직접 쿼리할 수 있습니다. 필드 정의는 Microsoft Copilot Studio 에이전트 인벤토리 스키마를 참조하세요.
PowerPlatformResources
| where type == "microsoft.copilotstudio/agents"
| extend properties = parse_json(properties)
| extend
isCLIAgent = tobool(properties.isCLIAgent),
model = tostring(properties.model),
createdIn = tostring(properties.createdIn)
| extend harness = case(
isCLIAgent == true, "GitHub Copilot",
model =~ "Microsoft 365 Copilot" or createdIn =~ "Microsoft 365 Copilot Agent Builder", "Copilot Chat",
"Standard")
| summarize agentCount = count() by harness
| order by agentCount desc
하네스를 사용하여 에이전트 나열
각 에이전트와 해당 하네스에 대해 한 행씩 반환하므로, 에이전트 수를 단순히 세는 데 그치지 않고 개별 에이전트를 찾아 조치를 취할 수 있습니다. Microsoft Copilot 하네스로 빌드된 에이전트만 반환하도록 where 줄의 주석 처리를 제거합니다.
PowerPlatformResources
| where type == "microsoft.copilotstudio/agents"
| extend properties = parse_json(properties)
| extend
isCLIAgent = tobool(properties.isCLIAgent),
model = tostring(properties.model),
createdIn = tostring(properties.createdIn)
| extend harness = case(
isCLIAgent == true, "GitHub Copilot",
model =~ "Microsoft 365 Copilot" or createdIn =~ "Microsoft 365 Copilot Agent Builder", "Copilot Chat",
"Standard")
//| where harness == "GitHub Copilot"
| project agentName = tostring(properties.displayName),
agentId = name,
harness,
environmentId = tostring(properties.environmentId),
ownerId = tostring(properties.ownerId),
createdAt = todatetime(properties.createdAt)
| order by harness asc, createdAt desc
지난 24시간 동안 만든 항목
PowerPlatformResources
| extend properties = parse_json(properties)
| extend createdAt = todatetime(properties.createdAt)
| where createdAt >= ago(24h)
Power Pages 쿼리(미리 보기)
Power Pages 쿼리는 microsoft.powerpages/sites 리소스 유형을 사용합니다. Power Pages 인벤토리는 전역 관리자, Power Platform 관리자 및 Dynamics 365 관리자만 사용할 수 있습니다.
Power Pages 사이트 나열
이 쿼리는 환경, 소유자 및 만들기 및 수정 날짜가 있는 Power Pages 사이트의 테넌트 전체 인벤토리를 반환합니다.
PowerPlatformResources
| where type =~ "microsoft.powerpages/sites"
| extend properties = parse_json(properties)
| project siteName = tostring(properties.displayName),
siteId = name,
environmentId = tostring(properties.environmentId),
ownerId = tostring(properties.ownerId),
createdOn = todatetime(properties.createdAt),
lastModifiedOn = todatetime(properties.lastModifiedAt)
| order by siteName asc
환경별 Power Pages 사이트 수
이 쿼리는 Power Pages 사이트가 가장 많은 환경을 보여 줍니다.
PowerPlatformResources
| where type =~ "microsoft.powerpages/sites"
| extend properties = parse_json(properties)
| extend environmentId = tostring(properties.environmentId)
| summarize siteCount = count() by environmentId
| order by siteCount desc
소유자별 Power Pages 사이트 수
이 쿼리는 소유권 검토 및 비즈니스 연속성 계획을 지원하기 위해 가장 많은 수의 Power Pages 사이트와 연결된 소유자를 보여줍니다.
PowerPlatformResources
| where type =~ "microsoft.powerpages/sites"
| extend properties = parse_json(properties)
| extend ownerId = tostring(properties.ownerId)
| summarize siteCount = count() by ownerId
| order by siteCount desc
익명 액세스가 사용하도록 설정된 사이트 Power Pages
이 쿼리는 인벤토리 메타데이터가 익명 액세스가 허용되었음을 나타내는 사이트를 찾습니다.
PowerPlatformResources
| where type =~ "microsoft.powerpages/sites"
| extend properties = parse_json(properties)
| extend anonymousAccessEnabled = tobool(properties.anonymousAccessAllowed)
| where anonymousAccessEnabled == true
| project siteName = tostring(properties.displayName),
siteId = name,
environmentId = tostring(properties.environmentId),
websiteUrl = tostring(properties.siteUrl)
| order by siteName asc
최근에 만든 Power Pages 사이트
이 쿼리는 지난 30일 동안 만든 사이트를 반환합니다. 필요에 따라 주기를 조정합니다.
PowerPlatformResources
| where type =~ "microsoft.powerpages/sites"
| extend properties = parse_json(properties)
| extend createdOn = todatetime(properties.createdAt)
| where createdOn >= ago(30d)
| project siteName = tostring(properties.displayName),
siteId = name,
environmentId = tostring(properties.environmentId),
ownerId = tostring(properties.ownerId),
createdOn
| order by createdOn desc
사용자 지정 도메인을 사용하는 Power Pages 사이트
이 쿼리는 인벤토리 메타데이터에 사용자 지정 사이트 URL이 포함된 사이트를 반환합니다.
PowerPlatformResources
| where type =~ "microsoft.powerpages/sites"
| extend properties = parse_json(properties)
| extend customDomain = tostring(properties.customSiteUrl)
| where isnotempty(customDomain)
| project siteName = tostring(properties.displayName),
siteId = name,
environmentId = tostring(properties.environmentId),
websiteUrl = tostring(properties.siteUrl),
customDomain
| order by siteName asc
다른 Power Platform 리소스와 함께 사용하는 Power Pages
이 쿼리는 Power Pages 사이트를 포함하여 Power Platform 전체의 유형 및 환경별 리소스 수를 요약합니다. 환경 ID가 없는 레코드는 제외됩니다.
PowerPlatformResources
| extend properties = parse_json(properties)
| extend environmentId = tostring(properties.environmentId)
| where isnotempty(environmentId)
| summarize resourceCount = count() by environmentId, type
| order by environmentId asc, resourceCount desc
커넥터 쿼리
다음 쿼리는 커넥터 인벤토리에 포함된 리소스 유형 전반의 커넥터 사용량을 분석합니다. 각 쿼리는 properties.powerPlatformConnectors 캔버스 앱, 모델 기반 앱, Copilot 관리되는 런타임에서 빌드된 앱, 클라우드 흐름, 에이전트 흐름, 워크플로 에이전트 흐름, 표준 하네스 또는 Microsoft Copilot 하네스의 Copilot Studio 에이전트 및 Microsoft 365 Copilot 에이전트 작성기에서 만든 에이전트에서 내보낸 배열에서 작동합니다. Copilot 관리형 런타임에서 빌드된 앱은 microsoft.powerapps/apps 하위 형식의 microsoftApp 형식을 사용합니다. 쿼리는 동일한 형식을 사용하지만 커넥터 데이터를 내보내지 않는 App Builder 앱을 제외합니다.
Power Platform 리소스에서 사용되는 상위 커넥터
가장 고유한 리소스에서 사용하는 커넥터를 나열합니다. 테넌트 전체에서 채택을 지배하는 커넥터를 이해하는 데 유용합니다.
PowerPlatformResources
| where type in (
"microsoft.powerapps/canvasapps",
"microsoft.powerapps/modeldrivenapps",
"microsoft.powerapps/apps",
"microsoft.powerautomate/cloudflows",
"microsoft.powerautomate/agentflows",
"microsoft.powerautomate/m365agentflows",
"microsoft.copilotstudio/agents")
| extend properties = parse_json(properties)
| where type != "microsoft.powerapps/apps" or tostring(properties.subType) == "microsoftApp"
| mv-expand connector = properties.powerPlatformConnectors
| extend connectorId = tostring(connector.connectorId)
| where isnotempty(connectorId)
| summarize ResourceCount = dcount(name) by connectorId
| order by ResourceCount desc
| take 10
리소스당 커넥터 수 분포
0, 1, 2 이상의 커넥터를 사용하는 리소스 수를 보여 줍니다. 복잡도 이상치를 식별하는 데 유용합니다.
PowerPlatformResources
| where type in (
"microsoft.powerapps/canvasapps",
"microsoft.powerapps/modeldrivenapps",
"microsoft.powerapps/apps",
"microsoft.powerautomate/cloudflows",
"microsoft.powerautomate/agentflows",
"microsoft.powerautomate/m365agentflows",
"microsoft.copilotstudio/agents")
| extend properties = parse_json(properties)
| where type != "microsoft.powerapps/apps" or tostring(properties.subType) == "microsoftApp"
| extend connectorCount = array_length(properties.powerPlatformConnectors)
| summarize ResourceCount = count() by toint(connectorCount)
| order by connectorCount asc
특정 커넥터를 사용하는 모든 리소스 찾기
shared_sharepointonline를 검색하려는 커넥터로 바꾸세요. 이 쿼리는 커넥터에 알려진 문제가 있거나, 사용되지 않거나, 새 라이선스가 필요한 경우 영향 분석에 유용합니다.
PowerPlatformResources
| where type in (
"microsoft.powerapps/canvasapps",
"microsoft.powerapps/modeldrivenapps",
"microsoft.powerapps/apps",
"microsoft.powerautomate/cloudflows",
"microsoft.powerautomate/agentflows",
"microsoft.powerautomate/m365agentflows",
"microsoft.copilotstudio/agents")
| extend properties = parse_json(properties)
| where type != "microsoft.powerapps/apps" or tostring(properties.subType) == "microsoftApp"
| mv-expand connector = properties.powerPlatformConnectors
| where tostring(connector.connectorId) == "shared_sharepointonline"
| project resourceName = tostring(properties.displayName),
resourceId = name,
resourceType = type,
environmentId = tostring(properties.environmentId),
operationsUsed = connector.operations
환경별 커넥터 사용량
모든 환경에서 사용되는 모든 커넥터를 사용하는 고유 리소스 수와 함께 나열합니다. 이 목록은 채택 패턴을 이해하고 DLP 정책 결정을 알리는 데 유용합니다.
PowerPlatformResources
| where type in (
"microsoft.powerapps/canvasapps",
"microsoft.powerapps/modeldrivenapps",
"microsoft.powerapps/apps",
"microsoft.powerautomate/cloudflows",
"microsoft.powerautomate/agentflows",
"microsoft.powerautomate/m365agentflows",
"microsoft.copilotstudio/agents")
| extend properties = parse_json(properties)
| where type != "microsoft.powerapps/apps" or tostring(properties.subType) == "microsoftApp"
| mv-expand connector = properties.powerPlatformConnectors
| extend connectorId = tostring(connector.connectorId)
| where isnotempty(connectorId)
| extend environmentId = tostring(properties.environmentId)
| summarize ResourceCount = dcount(name) by environmentId, connectorId
| order by environmentId asc, ResourceCount desc