canonical: https://jentic.com/apis/googleapis.com/vmmigration

# Google VM Migration API

The VM Migration API (Migrate to Virtual Machines) programmatically migrates VMware, AWS, and Azure virtual machine workloads to Google Compute Engine. It exposes sources, datacenter connectors, migrating VMs, clone and cutover jobs, replication cycles, groups, and target projects so platform teams can script migration waves, observe replication health, and finalize cutovers. It replaces a console-driven workflow with end-to-end automation suitable for large fleet migrations.

## For AI agents

Drive VM migrations from VMware, AWS, or Azure into Compute Engine so an agent can script source registration, replication, clone tests, and cutover without console clicks.

## Scope

Does not handle Compute Engine day-2 operations, network design, or cost optimization - use for orchestrating VM migration from VMware, AWS, and Azure into Compute Engine only.

## Capabilities

- Register on-premises VMware sources or public-cloud sources for migration
- Provision and upgrade datacenter connector appliances that stream replication data
- List migrating VMs in a source and filter by replication state
- Trigger clone jobs to validate workload behavior in Compute Engine before cutover
- Pause, resume, and finalize migration cutovers for individual VMs or groups
- Group related migrating VMs to coordinate cutover waves
- Inspect replication cycles to surface stalls and progress percentages

## Use cases

### Wave-Based VMware to Compute Engine Migration

Platform teams migrate hundreds of VMware VMs to Compute Engine in coordinated waves by registering a vCenter source, attaching VMs to migration groups, and scripting clone-test, cutover, and finalize steps per wave. The VM Migration API exposes group operations like addGroupMigration and removeGroupMigration so the wave orchestration code can be checked into version control instead of executed by hand. Replication health is queryable per cycle to spot stalls early.

Example prompt: Add 12 migrating VMs to a wave group and trigger finalizeMigration on each in sequence after replication completes

### Cross-Cloud Lift and Shift

Engineering teams moving workloads off AWS or Azure register the public cloud as a source, let replication stream changes into Google Cloud, run clone jobs to validate, and then cut over with finalizeMigration. The API tracks each migrating VM through cycles and exposes pause and resume controls that the orchestration system uses to coordinate downtime windows. This compresses a multi-quarter datacenter exit into a sequence of automated waves.

Example prompt: Register an AWS source, list migrating VMs, and trigger clone jobs on the application tier

### Migration Cutover Validation

Before finalizing a production cutover, SREs run clone jobs that bring up the migrating VM in Compute Engine for smoke testing. The VM Migration API exposes clone job lifecycle endpoints so the validation pipeline can spin up the clone, run automated checks, and tear it down without affecting replication. Once the validation passes, the same API issues the finalize call.

Example prompt: Trigger a clone job for a database VM, run health checks against the clone, then delete the clone job

### AI Agent Migration Operator

An AI agent integrated through Jentic responds to platform-team prompts like 'finalize all completed migrations for the payments group' by listing migrating VMs in a group, filtering for replication state, and chaining finalizeMigration calls. Because the API uses OAuth 2.0 with the cloud-platform scope, Jentic isolates the token in your Jentic One instance and exposes only a scoped reference to the agent.

Example prompt: Search Jentic for finalize VM migration, load the schema, and call it for each ready VM in the payments group

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| POST | /v1/{+migratingVm}:finalizeMigration | Finalize the cutover for a migrating VM |
| POST | /v1/{+migratingVm}:pauseMigration | Pause replication for a migrating VM |
| POST | /v1/{+group}:addGroupMigration | Add a migrating VM to a wave group |
| POST | /v1/{+group}:removeGroupMigration | Remove a migrating VM from a wave group |
| POST | /v1/{+datacenterConnector}:upgradeAppliance | Upgrade the datacenter connector appliance |

## Key resources

- **Sources** — Register VMware vCenter, AWS, and Azure sources for migration
- **DatacenterConnectors** — On-prem appliances that stream replication data; supports list, get, and upgrade operations
- **MigratingVms** — Per-VM lifecycle including clone, finalize, pause, resume, and replication cycles
- **Groups** — Wave grouping for coordinated cutover; supports addGroupMigration and removeGroupMigration
- **TargetProjects** — Compute Engine target projects that receive migrated VMs

## Why Jentic

- **Setup:** Wiring the VM Migration API by hand means setting up a Google service account, granting the cloud-platform scope, building the migrating-VM and group resource names, and polling long-running migration operations yourself. Through Jentic you install once, import the VM Migration API from the API Directory, store the service-account credential once, and your agent calls it.
- **Permission scoping:** VM Migration carries the migrating VM and group resource name in the URL path (/v1/{migratingVm}:finalizeMigration), so a rule can pin your agent to one migrating VM or group: it can act on that resource and nothing else. You choose the operations it may call, so cutover steps like finalizeMigration are not included unless you add them.
- **Credential handling:** Your VM Migration service-account credential 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 'pause a vm migration' or 'add a VM to a wave group', and Jentic returns the matching VM Migration v1 operation with its path-template input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Compute Engine API** — Manage the target VMs that VM Migration delivers into Compute Engine
- **VMware Engine API** — Run native VMware in Google Cloud rather than migrating off VMware
- **Cloud IAM API** — Grant the service accounts that VM Migration uses access to source and target projects
- **Cloud Monitoring API** — Track replication progress and alert on stalled migrations

## FAQ

### What authentication does the VM Migration API use?

The VM Migration API uses OAuth 2.0 with the https://www.googleapis.com/auth/cloud-platform scope. Through Jentic, the OAuth token is stored encrypted in your Jentic One instance and only a scoped reference is exposed to the agent at execution time.

### Can I migrate VMs from AWS and Azure with the VM Migration API, not just VMware?

Yes. The sources resource accepts AWS, Azure, and VMware source types. After registering a source you list migrating VMs and drive their lifecycle through the same set of endpoints regardless of source type, including clone, finalize, pause, and resume.

### What are the rate limits for the VM Migration API?

Default project quotas allow 600 requests per minute on control-plane operations and a smaller limit on long-running migration operations like clone and finalize. Higher quotas can be requested in the Google Cloud Console for fleet-scale migrations.

### How do I finalize a VM cutover through Jentic with the VM Migration API?

Install Jentic with pip install jentic, search for finalize VM migration, load the schema for POST /v1/{+migratingVm}:finalizeMigration, then call it with the migratingVm resource name. Confirm the migrating VM is in READY_TO_PROMOTE state first by reading the VM resource.

### Does the VM Migration API support migration groups for coordinated cutovers?

Yes. Use POST /v1/{+group}:addGroupMigration to attach VMs to a group and POST /v1/{+group}:removeGroupMigration to detach them. Groups are useful for wave orchestration where related VMs must cut over together.

### Why does my upgradeAppliance call fail on the datacenter connector?

Appliance upgrade requires the datacenter connector to be in OFFLINE or ACTIVE state with a network path to Google's update endpoints. Verify the appliance health from a Get request and confirm outbound connectivity from the on-prem environment before retrying.

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

Yes. Because you self-host Jentic One, your own rules decide which VM Migration operations and credentials the agent may use. Since the API carries the migrating VM or group resource name in the URL path, such as /v1/{migratingVm}:finalizeMigration, you can pin the agent to a single migrating VM or group so it acts on that resource and nothing else. You also choose which operations it can call, so sensitive cutover steps like finalizeMigration, pauseMigration, or addGroupMigration are excluded unless you add them.
