---
title: "POST /v1/{+parent}/sources"
method: POST
path: "/v1/{+parent}/sources"
tags: ["projects"]
---

# POST /v1/{+parent}/sources

`POST /v1/{+parent}/sources`

Creates a new Source in a given project and location.

## Path parameters

- `parent` string, required

## Query parameters

- `requestId` string
- `sourceId` string

## Request body

- Source — Source message describes a specific vm migration Source resource. It contains the source environment information.
  - `aws` AwsSourceDetails — AwsSourceDetails message describes a specific source details for the AWS source type.
    - `state` 'STATE_UNSPECIFIED' | 'PENDING' | 'FAILED' | 'ACTIVE' — Output only. State of the source as determined by the health check.
    - `awsRegion` string — Immutable. The AWS region that the source VMs will be migrated from.
    - `migrationResourcesUserTags` object — User specified tags to add to every M2VM generated resource in AWS. These tags will be set in addition to the default tags that are set as part of the migration process. The tags must not begin with the reserved prefix `m2vm`.
    - `accessKeyCreds` AccessKeyCredentials — Message describing AWS Credentials using access key id and secret.
      - `sessionToken` string — Input only. AWS session token. Used only when AWS security token service (STS) is responsible for creating the temporary credentials.
      - `accessKeyId` string — AWS access key ID.
      - `secretAccessKey` string — Input only. AWS secret access key.
    - `publicIp` string — Output only. The source's public IP. All communication initiated by this source will originate from this IP.
    - `inventorySecurityGroupNames` string[] — AWS security group names to limit the scope of the source inventory.
    - `error` Status — The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors).
      - `details` object[] — A list of messages that carry the error details. There is a common set of message types for APIs to use.
      - `message` string — A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
      - `code` integer — The status code, which should be an enum value of google.rpc.Code.
    - `inventoryTagList` Tag[] — AWS resource tags to limit the scope of the source inventory.
      - `key` string — Required. Key of tag.
      - `value` string — Required. Value of tag.
  - `createTime` string, google-datetime — Output only. The create time timestamp.
  - `name` string — Output only. The Source name.
  - `vmware` VmwareSourceDetails — VmwareSourceDetails message describes a specific source details for the vmware source type.
    - `password` string — Input only. The credentials password. This is write only and can not be read in a GET operation.
    - `vcenterIp` string — The ip address of the vcenter this Source represents.
    - `thumbprint` string — The thumbprint representing the certificate for the vcenter.
    - `username` string — The credentials username.
    - `resolvedVcenterHost` string — The hostname of the vcenter.
  - `description` string — User-provided description of the source.
  - `azure` AzureSourceDetails — AzureSourceDetails message describes a specific source details for the Azure source type.
    - `state` 'STATE_UNSPECIFIED' | 'PENDING' | 'FAILED' | 'ACTIVE' — Output only. State of the source as determined by the health check.
    - `migrationResourcesUserTags` object — User specified tags to add to every M2VM generated resource in Azure. These tags will be set in addition to the default tags that are set as part of the migration process. The tags must not begin with the reserved prefix `m4ce` or `m2vm`.
    - `azureLocation` string — Immutable. The Azure location (region) that the source VMs will be migrated from.
    - `resourceGroupId` string — Output only. The ID of the Azure resource group that contains all resources related to the migration process of this source.
    - `error` Status — The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors).
      - `details` object[] — A list of messages that carry the error details. There is a common set of message types for APIs to use.
      - `message` string — A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
      - `code` integer — The status code, which should be an enum value of google.rpc.Code.
    - `subscriptionId` string — Immutable. Azure subscription ID.
    - `clientSecretCreds` ClientSecretCredentials — Message describing Azure Credentials using tenant ID, client ID and secret.
      - `tenantId` string — Azure tenant ID.
      - `clientId` string — Azure client ID.
      - `clientSecret` string — Input only. Azure client secret.
  - `updateTime` string, google-datetime — Output only. The update time timestamp.
  - `labels` object — The labels of the source.
  - `encryption` Encryption — Encryption message describes the details of the applied encryption.
    - `kmsKey` string — Required. The name of the encryption key that is stored in Google Cloud KMS.

## Response `200`

Successful response

---

[API](https://skmtc.net/google/apis/vmmigration.md) · [All operations](https://skmtc.net/google/apis/vmmigration/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/google/vmmigration/versions/c812c34615f3/schema)
