canonical: https://jentic.com/apis/azure.com/vm-insights-onboarding

# Microsoft Azure VM Insights Onboarding

Jentic publishes the only available OpenAPI specification for VM Insights Onboarding, keeping it validated and agent-ready. The Azure VM Insights Onboarding API exposes a single Microsoft.Insights resource - vmInsightsOnboardingStatuses/default - that returns whether a given VM, VM Scale Set, or resource group is onboarded to VM Insights along with its associated Log Analytics workspace and data status. Agents use it to audit observability coverage, gate deployments on monitoring being present, and drive VM Insights enablement workflows. Authentication uses Azure Active Directory OAuth 2.0.

## For AI agents

Reads the VM Insights onboarding status (workspace, data status, onboarded yes/no) for a VM, Scale Set, or resource group so agents can audit observability coverage.

## Scope

Does not enable VM Insights, install agents, or query metrics - use the Microsoft.OperationsManagement, Data Collection Rule, and Monitor Metrics APIs for those; this API only reports onboarding status.

## Capabilities

- Check whether a specific VM is onboarded to VM Insights and which Log Analytics workspace receives its data
- Audit a Virtual Machine Scale Set's VM Insights onboarding status to confirm observability coverage before scaling out
- Sweep a resource group and report which resources have VM Insights enabled and which do not
- Gate a deployment pipeline on a successful VM Insights onboarding check before promoting a workload
- Drive an enablement campaign by listing un-onboarded resources for an internal observability dashboard

## Use cases

### Pre-deploy observability gate

A deployment pipeline that promotes new Scale Sets needs to confirm VM Insights is collecting performance and map data before traffic shifts. The agent calls GET /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default with the Scale Set's resource URI, asserts onboardingStatus is 'onboarded' and dataStatus is 'present', and only then proceeds. Failures route to a remediation step.

Example prompt: Call GET /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default for the Scale Set resource URI and fail the pipeline unless onboardingStatus='onboarded' and dataStatus='present'.

### Subscription-wide coverage audit

An observability team auditing a subscription needs a list of VMs and Scale Sets whose VM Insights status is anything other than 'onboarded'. The agent enumerates compute resources via the Compute API, calls this endpoint for each resource URI, and emits a report grouped by resource group. The result drives the enablement backlog for the next sprint.

Example prompt: For each VM and Scale Set resource id in subscription SUB123, GET /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default; collect entries where onboardingStatus != 'onboarded' and write a CSV grouped by resource group.

### Workspace mapping for cost attribution

FinOps teams attributing Log Analytics ingestion cost to workloads need to know which workspace each VM is sending data to. This endpoint returns workspaceResourceId per resource. The agent maps every onboarded resource to its workspace and joins to Log Analytics ingestion volumes for an accurate cost split.

Example prompt: Pull onboarding statuses for every VM in resource group 'platform-rg' and emit a JSON map of vmId to workspaceResourceId.

### Agent-driven onboarding remediation via Jentic

An ops agent receiving an alert that a workload lacks VM Insights can call this endpoint through Jentic to confirm, then chain into the Microsoft.OperationsManagement and DCR APIs to onboard the resource. Jentic exposes the operation with the resourceUri parameter declared so the agent only needs to compose the resource id.

Example prompt: Search Jentic for 'vm insights onboarding status', execute the GET for resource URI '/subscriptions/SUB123/resourceGroups/web-rg/providers/Microsoft.Compute/virtualMachines/web-01', and return onboardingStatus plus workspaceResourceId.

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default | Get the VM Insights onboarding status for a resource |

## Key resources

- **vmInsightsOnboardingStatuses** — Read-only status object returning onboardingStatus, dataStatus, and workspaceResourceId for a VM, Scale Set, or resource group

## Why Jentic

- **Setup:** Reading VM Insights onboarding status by hand means acquiring Azure Active Directory OAuth 2.0 tokens, targeting the management.azure.com ARM control plane, and building the /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default path from a full resource id yourself. Through Jentic you install once, import VM Insights Onboarding from the API Directory, store the Azure AD credential once, and your agent calls it.
- **Permission scoping:** This API takes the target resource id as a URL path parameter (/{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default), so a rule can pin your agent to one resource and nothing else. The surface is a single read operation, so the agent can only fetch onboarding status and cannot change any configuration.
- **Credential handling:** Your Azure AD token is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'check VM Insights onboarding status', and Jentic returns the GET on /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default with the resourceUri parameter declared, ready to fill with the target ARM id.

## Related APIs

- **MonitorManagementClient** — Configures Azure Monitor metrics, alerts, and diagnostic settings alongside VM Insights
- **Microsoft.Insights** — Broader Microsoft.Insights provider including diagnostic settings and metric definitions
- **ApplicationInsightsManagementClient** — Application-level observability via Application Insights

## FAQ

### Why is there no official OpenAPI spec for VM Insights Onboarding?

Microsoft Azure does not publish an OpenAPI specification. Jentic generates and maintains this spec so that AI agents and developers can call VM Insights Onboarding via structured tooling. It is validated against the live API and kept up to date. Get started with Jentic One, the self-hosted execution layer .

### What authentication does the VM Insights Onboarding API use?

Azure Active Directory OAuth 2.0 with the user_impersonation scope against https://login.microsoftonline.com/common/oauth2/authorize. Through Jentic the AAD client secret stays encrypted in the vault and the agent only sees a scoped bearer token at call time.

### Can I check whether a VM is onboarded to VM Insights with this API?

Yes. GET /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default returns onboardingStatus and dataStatus along with the linked Log Analytics workspaceResourceId. resourceUri is the full ARM id of the VM, Scale Set, or resource group.

### What are the rate limits for the VM Insights Onboarding API?

Calls go through Azure Resource Manager and inherit the standard ARM read throttling envelope (roughly 12,000 reads per hour per subscription). The endpoint is read-only and lightweight; respect Retry-After on a 429.

### How do I check VM Insights onboarding through Jentic?

Run pip install jentic, then client.search('vm insights onboarding status'), client.load on the returned GET on /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default, and client.execute with resourceUri set to the ARM id of the VM or Scale Set. Jentic injects the AAD bearer token from the vault.

### Can this API onboard a VM to VM Insights?

No. This endpoint only reports status. To enable VM Insights, use the Microsoft.OperationsManagement solutions API and the Data Collection Rule (DCR) APIs to associate the VM with the correct Log Analytics workspace and DCR.

### Can I limit what my agent is allowed to do with the VM Insights Onboarding API?

Yes. Because you run Jentic One yourself, your own rules decide which operations and credentials the agent may use, and this API exposes only a single read call: GET /{resourceUri}/providers/Microsoft.Insights/vmInsightsOnboardingStatuses/default. Since the target resource is a URL path parameter, you can pin the agent to one specific VM, Scale Set, or resource group and no other, and the read-only surface means it can fetch onboarding status but cannot change any monitoring configuration. Your Azure AD credential stays with your instance and is attached only when the agent runs an operation you have allowed.
