@googleapis/vmmigration 13.0.1 → 14.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +30 -0
- package/build/v1.d.ts +3620 -2
- package/build/v1.js +33 -0
- package/build/v1.js.map +1 -1
- package/build/v1alpha1.d.ts +3642 -2
- package/build/v1alpha1.js +33 -0
- package/build/v1alpha1.js.map +1 -1
- package/package.json +1 -1
- package/v1.ts +3702 -5
- package/v1alpha1.ts +3724 -5
package/v1.ts
CHANGED
|
@@ -714,6 +714,10 @@ export namespace vmmigration_v1 {
|
|
|
714
714
|
* Compute instance scheduling information (if empty default is used).
|
|
715
715
|
*/
|
|
716
716
|
computeScheduling?: Schema$ComputeScheduling;
|
|
717
|
+
/**
|
|
718
|
+
* Optional. Additional replica zones of the target regional disks. If this list is not empty a regional disk will be created. The first supported zone would be the one stated in the zone field. The rest are taken from this list. Please refer to the [regional disk creation API](https://cloud.google.com/compute/docs/regions-zones/global-regional-zonal-resources) for further details about regional vs zonal disks. If not specified, a zonal disk will be created in the same zone the VM is created.
|
|
719
|
+
*/
|
|
720
|
+
diskReplicaZones?: string[] | null;
|
|
717
721
|
/**
|
|
718
722
|
* The disk type to use in the VM.
|
|
719
723
|
*/
|
|
@@ -807,6 +811,10 @@ export namespace vmmigration_v1 {
|
|
|
807
811
|
* Compute instance scheduling information (if empty default is used).
|
|
808
812
|
*/
|
|
809
813
|
computeScheduling?: Schema$ComputeScheduling;
|
|
814
|
+
/**
|
|
815
|
+
* Optional. Additional replica zones of the target regional disks. If this list is not empty a regional disk will be created. The first supported zone would be the one stated in the zone field. The rest are taken from this list. Please refer to the [regional disk creation API](https://cloud.google.com/compute/docs/regions-zones/global-regional-zonal-resources) for further details about regional vs zonal disks. If not specified, a zonal disk will be created in the same zone the VM is created.
|
|
816
|
+
*/
|
|
817
|
+
diskReplicaZones?: string[] | null;
|
|
810
818
|
/**
|
|
811
819
|
* The disk type to use in the VM.
|
|
812
820
|
*/
|
|
@@ -1252,6 +1260,27 @@ export namespace vmmigration_v1 {
|
|
|
1252
1260
|
*/
|
|
1253
1261
|
kmsKey?: string | null;
|
|
1254
1262
|
}
|
|
1263
|
+
/**
|
|
1264
|
+
* Expiration holds information about the expiration of a MigratingVm.
|
|
1265
|
+
*/
|
|
1266
|
+
export interface Schema$Expiration {
|
|
1267
|
+
/**
|
|
1268
|
+
* Output only. Timestamp of when this resource is considered expired.
|
|
1269
|
+
*/
|
|
1270
|
+
expireTime?: string | null;
|
|
1271
|
+
/**
|
|
1272
|
+
* Output only. Describes whether the expiration can be extended.
|
|
1273
|
+
*/
|
|
1274
|
+
extendable?: boolean | null;
|
|
1275
|
+
/**
|
|
1276
|
+
* Output only. The number of times expiration was extended.
|
|
1277
|
+
*/
|
|
1278
|
+
extensionCount?: number | null;
|
|
1279
|
+
}
|
|
1280
|
+
/**
|
|
1281
|
+
* Request message for 'ExtendMigrationRequest' request.
|
|
1282
|
+
*/
|
|
1283
|
+
export interface Schema$ExtendMigrationRequest {}
|
|
1255
1284
|
/**
|
|
1256
1285
|
* Response message for fetchInventory.
|
|
1257
1286
|
*/
|
|
@@ -1740,7 +1769,7 @@ export namespace vmmigration_v1 {
|
|
|
1740
1769
|
*/
|
|
1741
1770
|
description?: string | null;
|
|
1742
1771
|
/**
|
|
1743
|
-
* Immutable. The encryption to apply to the machine image.
|
|
1772
|
+
* Immutable. The encryption to apply to the machine image. If the Image Import resource has an encryption, this field must be set to the same encryption key.
|
|
1744
1773
|
*/
|
|
1745
1774
|
encryption?: Schema$Encryption;
|
|
1746
1775
|
/**
|
|
@@ -1756,7 +1785,7 @@ export namespace vmmigration_v1 {
|
|
|
1756
1785
|
*/
|
|
1757
1786
|
machineImageParametersOverrides?: Schema$MachineImageParametersOverrides;
|
|
1758
1787
|
/**
|
|
1759
|
-
* Optional. The network interfaces to create with the instance created by the machine image. Internal and external IP addresses are ignored for machine image import.
|
|
1788
|
+
* Optional. The network interfaces to create with the instance created by the machine image. Internal and external IP addresses, and network tiers are ignored for machine image import.
|
|
1760
1789
|
*/
|
|
1761
1790
|
networkInterfaces?: Schema$NetworkInterface[];
|
|
1762
1791
|
/**
|
|
@@ -1832,6 +1861,10 @@ export namespace vmmigration_v1 {
|
|
|
1832
1861
|
* Output only. Provides details on the state of the Migrating VM in case of an error in replication.
|
|
1833
1862
|
*/
|
|
1834
1863
|
error?: Schema$Status;
|
|
1864
|
+
/**
|
|
1865
|
+
* Output only. Provides details about the expiration state of the migrating VM.
|
|
1866
|
+
*/
|
|
1867
|
+
expiration?: Schema$Expiration;
|
|
1835
1868
|
/**
|
|
1836
1869
|
* Output only. The group this migrating vm is included in, if any. The group is represented by the full path of the appropriate Group resource.
|
|
1837
1870
|
*/
|
|
@@ -2688,6 +2721,56 @@ export namespace vmmigration_v1 {
|
|
|
2688
2721
|
|
|
2689
2722
|
/**
|
|
2690
2723
|
* Gets information about a location.
|
|
2724
|
+
* @example
|
|
2725
|
+
* ```js
|
|
2726
|
+
* // Before running the sample:
|
|
2727
|
+
* // - Enable the API at:
|
|
2728
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
2729
|
+
* // - Login into gcloud by running:
|
|
2730
|
+
* // ```sh
|
|
2731
|
+
* // $ gcloud auth application-default login
|
|
2732
|
+
* // ```
|
|
2733
|
+
* // - Install the npm module by running:
|
|
2734
|
+
* // ```sh
|
|
2735
|
+
* // $ npm install googleapis
|
|
2736
|
+
* // ```
|
|
2737
|
+
*
|
|
2738
|
+
* const {google} = require('googleapis');
|
|
2739
|
+
* const vmmigration = google.vmmigration('v1');
|
|
2740
|
+
*
|
|
2741
|
+
* async function main() {
|
|
2742
|
+
* const auth = new google.auth.GoogleAuth({
|
|
2743
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
2744
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
2745
|
+
* });
|
|
2746
|
+
*
|
|
2747
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
2748
|
+
* const authClient = await auth.getClient();
|
|
2749
|
+
* google.options({auth: authClient});
|
|
2750
|
+
*
|
|
2751
|
+
* // Do the magic
|
|
2752
|
+
* const res = await vmmigration.projects.locations.get({
|
|
2753
|
+
* // Resource name for the location.
|
|
2754
|
+
* name: 'projects/my-project/locations/my-location',
|
|
2755
|
+
* });
|
|
2756
|
+
* console.log(res.data);
|
|
2757
|
+
*
|
|
2758
|
+
* // Example response
|
|
2759
|
+
* // {
|
|
2760
|
+
* // "displayName": "my_displayName",
|
|
2761
|
+
* // "labels": {},
|
|
2762
|
+
* // "locationId": "my_locationId",
|
|
2763
|
+
* // "metadata": {},
|
|
2764
|
+
* // "name": "my_name"
|
|
2765
|
+
* // }
|
|
2766
|
+
* }
|
|
2767
|
+
*
|
|
2768
|
+
* main().catch(e => {
|
|
2769
|
+
* console.error(e);
|
|
2770
|
+
* throw e;
|
|
2771
|
+
* });
|
|
2772
|
+
*
|
|
2773
|
+
* ```
|
|
2691
2774
|
*
|
|
2692
2775
|
* @param params - Parameters for request
|
|
2693
2776
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -2776,6 +2859,61 @@ export namespace vmmigration_v1 {
|
|
|
2776
2859
|
|
|
2777
2860
|
/**
|
|
2778
2861
|
* Lists information about the supported locations for this service.
|
|
2862
|
+
* @example
|
|
2863
|
+
* ```js
|
|
2864
|
+
* // Before running the sample:
|
|
2865
|
+
* // - Enable the API at:
|
|
2866
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
2867
|
+
* // - Login into gcloud by running:
|
|
2868
|
+
* // ```sh
|
|
2869
|
+
* // $ gcloud auth application-default login
|
|
2870
|
+
* // ```
|
|
2871
|
+
* // - Install the npm module by running:
|
|
2872
|
+
* // ```sh
|
|
2873
|
+
* // $ npm install googleapis
|
|
2874
|
+
* // ```
|
|
2875
|
+
*
|
|
2876
|
+
* const {google} = require('googleapis');
|
|
2877
|
+
* const vmmigration = google.vmmigration('v1');
|
|
2878
|
+
*
|
|
2879
|
+
* async function main() {
|
|
2880
|
+
* const auth = new google.auth.GoogleAuth({
|
|
2881
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
2882
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
2883
|
+
* });
|
|
2884
|
+
*
|
|
2885
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
2886
|
+
* const authClient = await auth.getClient();
|
|
2887
|
+
* google.options({auth: authClient});
|
|
2888
|
+
*
|
|
2889
|
+
* // Do the magic
|
|
2890
|
+
* const res = await vmmigration.projects.locations.list({
|
|
2891
|
+
* // Optional. A list of extra location types that should be used as conditions for controlling the visibility of the locations.
|
|
2892
|
+
* extraLocationTypes: 'placeholder-value',
|
|
2893
|
+
* // A filter to narrow down results to a preferred subset. The filtering language accepts strings like `"displayName=tokyo"`, and is documented in more detail in [AIP-160](https://google.aip.dev/160).
|
|
2894
|
+
* filter: 'placeholder-value',
|
|
2895
|
+
* // The resource that owns the locations collection, if applicable.
|
|
2896
|
+
* name: 'projects/my-project',
|
|
2897
|
+
* // The maximum number of results to return. If not set, the service selects a default.
|
|
2898
|
+
* pageSize: 'placeholder-value',
|
|
2899
|
+
* // A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.
|
|
2900
|
+
* pageToken: 'placeholder-value',
|
|
2901
|
+
* });
|
|
2902
|
+
* console.log(res.data);
|
|
2903
|
+
*
|
|
2904
|
+
* // Example response
|
|
2905
|
+
* // {
|
|
2906
|
+
* // "locations": [],
|
|
2907
|
+
* // "nextPageToken": "my_nextPageToken"
|
|
2908
|
+
* // }
|
|
2909
|
+
* }
|
|
2910
|
+
*
|
|
2911
|
+
* main().catch(e => {
|
|
2912
|
+
* console.error(e);
|
|
2913
|
+
* throw e;
|
|
2914
|
+
* });
|
|
2915
|
+
*
|
|
2916
|
+
* ```
|
|
2779
2917
|
*
|
|
2780
2918
|
* @param params - Parameters for request
|
|
2781
2919
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -2907,6 +3045,64 @@ export namespace vmmigration_v1 {
|
|
|
2907
3045
|
|
|
2908
3046
|
/**
|
|
2909
3047
|
* Adds a MigratingVm to a Group.
|
|
3048
|
+
* @example
|
|
3049
|
+
* ```js
|
|
3050
|
+
* // Before running the sample:
|
|
3051
|
+
* // - Enable the API at:
|
|
3052
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
3053
|
+
* // - Login into gcloud by running:
|
|
3054
|
+
* // ```sh
|
|
3055
|
+
* // $ gcloud auth application-default login
|
|
3056
|
+
* // ```
|
|
3057
|
+
* // - Install the npm module by running:
|
|
3058
|
+
* // ```sh
|
|
3059
|
+
* // $ npm install googleapis
|
|
3060
|
+
* // ```
|
|
3061
|
+
*
|
|
3062
|
+
* const {google} = require('googleapis');
|
|
3063
|
+
* const vmmigration = google.vmmigration('v1');
|
|
3064
|
+
*
|
|
3065
|
+
* async function main() {
|
|
3066
|
+
* const auth = new google.auth.GoogleAuth({
|
|
3067
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
3068
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
3069
|
+
* });
|
|
3070
|
+
*
|
|
3071
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
3072
|
+
* const authClient = await auth.getClient();
|
|
3073
|
+
* google.options({auth: authClient});
|
|
3074
|
+
*
|
|
3075
|
+
* // Do the magic
|
|
3076
|
+
* const res = await vmmigration.projects.locations.groups.addGroupMigration({
|
|
3077
|
+
* // Required. The full path name of the Group to add to.
|
|
3078
|
+
* group: 'projects/my-project/locations/my-location/groups/my-group',
|
|
3079
|
+
*
|
|
3080
|
+
* // Request body metadata
|
|
3081
|
+
* requestBody: {
|
|
3082
|
+
* // request body parameters
|
|
3083
|
+
* // {
|
|
3084
|
+
* // "migratingVm": "my_migratingVm"
|
|
3085
|
+
* // }
|
|
3086
|
+
* },
|
|
3087
|
+
* });
|
|
3088
|
+
* console.log(res.data);
|
|
3089
|
+
*
|
|
3090
|
+
* // Example response
|
|
3091
|
+
* // {
|
|
3092
|
+
* // "done": false,
|
|
3093
|
+
* // "error": {},
|
|
3094
|
+
* // "metadata": {},
|
|
3095
|
+
* // "name": "my_name",
|
|
3096
|
+
* // "response": {}
|
|
3097
|
+
* // }
|
|
3098
|
+
* }
|
|
3099
|
+
*
|
|
3100
|
+
* main().catch(e => {
|
|
3101
|
+
* console.error(e);
|
|
3102
|
+
* throw e;
|
|
3103
|
+
* });
|
|
3104
|
+
*
|
|
3105
|
+
* ```
|
|
2910
3106
|
*
|
|
2911
3107
|
* @param params - Parameters for request
|
|
2912
3108
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -2999,6 +3195,73 @@ export namespace vmmigration_v1 {
|
|
|
2999
3195
|
|
|
3000
3196
|
/**
|
|
3001
3197
|
* Creates a new Group in a given project and location.
|
|
3198
|
+
* @example
|
|
3199
|
+
* ```js
|
|
3200
|
+
* // Before running the sample:
|
|
3201
|
+
* // - Enable the API at:
|
|
3202
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
3203
|
+
* // - Login into gcloud by running:
|
|
3204
|
+
* // ```sh
|
|
3205
|
+
* // $ gcloud auth application-default login
|
|
3206
|
+
* // ```
|
|
3207
|
+
* // - Install the npm module by running:
|
|
3208
|
+
* // ```sh
|
|
3209
|
+
* // $ npm install googleapis
|
|
3210
|
+
* // ```
|
|
3211
|
+
*
|
|
3212
|
+
* const {google} = require('googleapis');
|
|
3213
|
+
* const vmmigration = google.vmmigration('v1');
|
|
3214
|
+
*
|
|
3215
|
+
* async function main() {
|
|
3216
|
+
* const auth = new google.auth.GoogleAuth({
|
|
3217
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
3218
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
3219
|
+
* });
|
|
3220
|
+
*
|
|
3221
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
3222
|
+
* const authClient = await auth.getClient();
|
|
3223
|
+
* google.options({auth: authClient});
|
|
3224
|
+
*
|
|
3225
|
+
* // Do the magic
|
|
3226
|
+
* const res = await vmmigration.projects.locations.groups.create({
|
|
3227
|
+
* // Required. The group identifier.
|
|
3228
|
+
* groupId: 'placeholder-value',
|
|
3229
|
+
* // Required. The Group's parent.
|
|
3230
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
3231
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
3232
|
+
* requestId: 'placeholder-value',
|
|
3233
|
+
*
|
|
3234
|
+
* // Request body metadata
|
|
3235
|
+
* requestBody: {
|
|
3236
|
+
* // request body parameters
|
|
3237
|
+
* // {
|
|
3238
|
+
* // "createTime": "my_createTime",
|
|
3239
|
+
* // "description": "my_description",
|
|
3240
|
+
* // "displayName": "my_displayName",
|
|
3241
|
+
* // "migrationTargetType": "my_migrationTargetType",
|
|
3242
|
+
* // "name": "my_name",
|
|
3243
|
+
* // "updateTime": "my_updateTime"
|
|
3244
|
+
* // }
|
|
3245
|
+
* },
|
|
3246
|
+
* });
|
|
3247
|
+
* console.log(res.data);
|
|
3248
|
+
*
|
|
3249
|
+
* // Example response
|
|
3250
|
+
* // {
|
|
3251
|
+
* // "done": false,
|
|
3252
|
+
* // "error": {},
|
|
3253
|
+
* // "metadata": {},
|
|
3254
|
+
* // "name": "my_name",
|
|
3255
|
+
* // "response": {}
|
|
3256
|
+
* // }
|
|
3257
|
+
* }
|
|
3258
|
+
*
|
|
3259
|
+
* main().catch(e => {
|
|
3260
|
+
* console.error(e);
|
|
3261
|
+
* throw e;
|
|
3262
|
+
* });
|
|
3263
|
+
*
|
|
3264
|
+
* ```
|
|
3002
3265
|
*
|
|
3003
3266
|
* @param params - Parameters for request
|
|
3004
3267
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3090,6 +3353,58 @@ export namespace vmmigration_v1 {
|
|
|
3090
3353
|
|
|
3091
3354
|
/**
|
|
3092
3355
|
* Deletes a single Group.
|
|
3356
|
+
* @example
|
|
3357
|
+
* ```js
|
|
3358
|
+
* // Before running the sample:
|
|
3359
|
+
* // - Enable the API at:
|
|
3360
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
3361
|
+
* // - Login into gcloud by running:
|
|
3362
|
+
* // ```sh
|
|
3363
|
+
* // $ gcloud auth application-default login
|
|
3364
|
+
* // ```
|
|
3365
|
+
* // - Install the npm module by running:
|
|
3366
|
+
* // ```sh
|
|
3367
|
+
* // $ npm install googleapis
|
|
3368
|
+
* // ```
|
|
3369
|
+
*
|
|
3370
|
+
* const {google} = require('googleapis');
|
|
3371
|
+
* const vmmigration = google.vmmigration('v1');
|
|
3372
|
+
*
|
|
3373
|
+
* async function main() {
|
|
3374
|
+
* const auth = new google.auth.GoogleAuth({
|
|
3375
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
3376
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
3377
|
+
* });
|
|
3378
|
+
*
|
|
3379
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
3380
|
+
* const authClient = await auth.getClient();
|
|
3381
|
+
* google.options({auth: authClient});
|
|
3382
|
+
*
|
|
3383
|
+
* // Do the magic
|
|
3384
|
+
* const res = await vmmigration.projects.locations.groups.delete({
|
|
3385
|
+
* // Required. The Group name.
|
|
3386
|
+
* name: 'projects/my-project/locations/my-location/groups/my-group',
|
|
3387
|
+
* // Optional. A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
3388
|
+
* requestId: 'placeholder-value',
|
|
3389
|
+
* });
|
|
3390
|
+
* console.log(res.data);
|
|
3391
|
+
*
|
|
3392
|
+
* // Example response
|
|
3393
|
+
* // {
|
|
3394
|
+
* // "done": false,
|
|
3395
|
+
* // "error": {},
|
|
3396
|
+
* // "metadata": {},
|
|
3397
|
+
* // "name": "my_name",
|
|
3398
|
+
* // "response": {}
|
|
3399
|
+
* // }
|
|
3400
|
+
* }
|
|
3401
|
+
*
|
|
3402
|
+
* main().catch(e => {
|
|
3403
|
+
* console.error(e);
|
|
3404
|
+
* throw e;
|
|
3405
|
+
* });
|
|
3406
|
+
*
|
|
3407
|
+
* ```
|
|
3093
3408
|
*
|
|
3094
3409
|
* @param params - Parameters for request
|
|
3095
3410
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3178,6 +3493,57 @@ export namespace vmmigration_v1 {
|
|
|
3178
3493
|
|
|
3179
3494
|
/**
|
|
3180
3495
|
* Gets details of a single Group.
|
|
3496
|
+
* @example
|
|
3497
|
+
* ```js
|
|
3498
|
+
* // Before running the sample:
|
|
3499
|
+
* // - Enable the API at:
|
|
3500
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
3501
|
+
* // - Login into gcloud by running:
|
|
3502
|
+
* // ```sh
|
|
3503
|
+
* // $ gcloud auth application-default login
|
|
3504
|
+
* // ```
|
|
3505
|
+
* // - Install the npm module by running:
|
|
3506
|
+
* // ```sh
|
|
3507
|
+
* // $ npm install googleapis
|
|
3508
|
+
* // ```
|
|
3509
|
+
*
|
|
3510
|
+
* const {google} = require('googleapis');
|
|
3511
|
+
* const vmmigration = google.vmmigration('v1');
|
|
3512
|
+
*
|
|
3513
|
+
* async function main() {
|
|
3514
|
+
* const auth = new google.auth.GoogleAuth({
|
|
3515
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
3516
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
3517
|
+
* });
|
|
3518
|
+
*
|
|
3519
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
3520
|
+
* const authClient = await auth.getClient();
|
|
3521
|
+
* google.options({auth: authClient});
|
|
3522
|
+
*
|
|
3523
|
+
* // Do the magic
|
|
3524
|
+
* const res = await vmmigration.projects.locations.groups.get({
|
|
3525
|
+
* // Required. The group name.
|
|
3526
|
+
* name: 'projects/my-project/locations/my-location/groups/my-group',
|
|
3527
|
+
* });
|
|
3528
|
+
* console.log(res.data);
|
|
3529
|
+
*
|
|
3530
|
+
* // Example response
|
|
3531
|
+
* // {
|
|
3532
|
+
* // "createTime": "my_createTime",
|
|
3533
|
+
* // "description": "my_description",
|
|
3534
|
+
* // "displayName": "my_displayName",
|
|
3535
|
+
* // "migrationTargetType": "my_migrationTargetType",
|
|
3536
|
+
* // "name": "my_name",
|
|
3537
|
+
* // "updateTime": "my_updateTime"
|
|
3538
|
+
* // }
|
|
3539
|
+
* }
|
|
3540
|
+
*
|
|
3541
|
+
* main().catch(e => {
|
|
3542
|
+
* console.error(e);
|
|
3543
|
+
* throw e;
|
|
3544
|
+
* });
|
|
3545
|
+
*
|
|
3546
|
+
* ```
|
|
3181
3547
|
*
|
|
3182
3548
|
* @param params - Parameters for request
|
|
3183
3549
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3266,6 +3632,62 @@ export namespace vmmigration_v1 {
|
|
|
3266
3632
|
|
|
3267
3633
|
/**
|
|
3268
3634
|
* Lists Groups in a given project and location.
|
|
3635
|
+
* @example
|
|
3636
|
+
* ```js
|
|
3637
|
+
* // Before running the sample:
|
|
3638
|
+
* // - Enable the API at:
|
|
3639
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
3640
|
+
* // - Login into gcloud by running:
|
|
3641
|
+
* // ```sh
|
|
3642
|
+
* // $ gcloud auth application-default login
|
|
3643
|
+
* // ```
|
|
3644
|
+
* // - Install the npm module by running:
|
|
3645
|
+
* // ```sh
|
|
3646
|
+
* // $ npm install googleapis
|
|
3647
|
+
* // ```
|
|
3648
|
+
*
|
|
3649
|
+
* const {google} = require('googleapis');
|
|
3650
|
+
* const vmmigration = google.vmmigration('v1');
|
|
3651
|
+
*
|
|
3652
|
+
* async function main() {
|
|
3653
|
+
* const auth = new google.auth.GoogleAuth({
|
|
3654
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
3655
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
3656
|
+
* });
|
|
3657
|
+
*
|
|
3658
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
3659
|
+
* const authClient = await auth.getClient();
|
|
3660
|
+
* google.options({auth: authClient});
|
|
3661
|
+
*
|
|
3662
|
+
* // Do the magic
|
|
3663
|
+
* const res = await vmmigration.projects.locations.groups.list({
|
|
3664
|
+
* // Optional. The filter request.
|
|
3665
|
+
* filter: 'placeholder-value',
|
|
3666
|
+
* // Optional. the order by fields for the result.
|
|
3667
|
+
* orderBy: 'placeholder-value',
|
|
3668
|
+
* // Optional. The maximum number of groups to return. The service may return fewer than this value. If unspecified, at most 500 groups will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
3669
|
+
* pageSize: 'placeholder-value',
|
|
3670
|
+
* // Required. A page token, received from a previous `ListGroups` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListGroups` must match the call that provided the page token.
|
|
3671
|
+
* pageToken: 'placeholder-value',
|
|
3672
|
+
* // Required. The parent, which owns this collection of groups.
|
|
3673
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
3674
|
+
* });
|
|
3675
|
+
* console.log(res.data);
|
|
3676
|
+
*
|
|
3677
|
+
* // Example response
|
|
3678
|
+
* // {
|
|
3679
|
+
* // "groups": [],
|
|
3680
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
3681
|
+
* // "unreachable": []
|
|
3682
|
+
* // }
|
|
3683
|
+
* }
|
|
3684
|
+
*
|
|
3685
|
+
* main().catch(e => {
|
|
3686
|
+
* console.error(e);
|
|
3687
|
+
* throw e;
|
|
3688
|
+
* });
|
|
3689
|
+
*
|
|
3690
|
+
* ```
|
|
3269
3691
|
*
|
|
3270
3692
|
* @param params - Parameters for request
|
|
3271
3693
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3357,6 +3779,73 @@ export namespace vmmigration_v1 {
|
|
|
3357
3779
|
|
|
3358
3780
|
/**
|
|
3359
3781
|
* Updates the parameters of a single Group.
|
|
3782
|
+
* @example
|
|
3783
|
+
* ```js
|
|
3784
|
+
* // Before running the sample:
|
|
3785
|
+
* // - Enable the API at:
|
|
3786
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
3787
|
+
* // - Login into gcloud by running:
|
|
3788
|
+
* // ```sh
|
|
3789
|
+
* // $ gcloud auth application-default login
|
|
3790
|
+
* // ```
|
|
3791
|
+
* // - Install the npm module by running:
|
|
3792
|
+
* // ```sh
|
|
3793
|
+
* // $ npm install googleapis
|
|
3794
|
+
* // ```
|
|
3795
|
+
*
|
|
3796
|
+
* const {google} = require('googleapis');
|
|
3797
|
+
* const vmmigration = google.vmmigration('v1');
|
|
3798
|
+
*
|
|
3799
|
+
* async function main() {
|
|
3800
|
+
* const auth = new google.auth.GoogleAuth({
|
|
3801
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
3802
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
3803
|
+
* });
|
|
3804
|
+
*
|
|
3805
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
3806
|
+
* const authClient = await auth.getClient();
|
|
3807
|
+
* google.options({auth: authClient});
|
|
3808
|
+
*
|
|
3809
|
+
* // Do the magic
|
|
3810
|
+
* const res = await vmmigration.projects.locations.groups.patch({
|
|
3811
|
+
* // Output only. The Group name.
|
|
3812
|
+
* name: 'projects/my-project/locations/my-location/groups/my-group',
|
|
3813
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
3814
|
+
* requestId: 'placeholder-value',
|
|
3815
|
+
* // Field mask is used to specify the fields to be overwritten in the Group resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
|
|
3816
|
+
* updateMask: 'placeholder-value',
|
|
3817
|
+
*
|
|
3818
|
+
* // Request body metadata
|
|
3819
|
+
* requestBody: {
|
|
3820
|
+
* // request body parameters
|
|
3821
|
+
* // {
|
|
3822
|
+
* // "createTime": "my_createTime",
|
|
3823
|
+
* // "description": "my_description",
|
|
3824
|
+
* // "displayName": "my_displayName",
|
|
3825
|
+
* // "migrationTargetType": "my_migrationTargetType",
|
|
3826
|
+
* // "name": "my_name",
|
|
3827
|
+
* // "updateTime": "my_updateTime"
|
|
3828
|
+
* // }
|
|
3829
|
+
* },
|
|
3830
|
+
* });
|
|
3831
|
+
* console.log(res.data);
|
|
3832
|
+
*
|
|
3833
|
+
* // Example response
|
|
3834
|
+
* // {
|
|
3835
|
+
* // "done": false,
|
|
3836
|
+
* // "error": {},
|
|
3837
|
+
* // "metadata": {},
|
|
3838
|
+
* // "name": "my_name",
|
|
3839
|
+
* // "response": {}
|
|
3840
|
+
* // }
|
|
3841
|
+
* }
|
|
3842
|
+
*
|
|
3843
|
+
* main().catch(e => {
|
|
3844
|
+
* console.error(e);
|
|
3845
|
+
* throw e;
|
|
3846
|
+
* });
|
|
3847
|
+
*
|
|
3848
|
+
* ```
|
|
3360
3849
|
*
|
|
3361
3850
|
* @param params - Parameters for request
|
|
3362
3851
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3445,6 +3934,64 @@ export namespace vmmigration_v1 {
|
|
|
3445
3934
|
|
|
3446
3935
|
/**
|
|
3447
3936
|
* Removes a MigratingVm from a Group.
|
|
3937
|
+
* @example
|
|
3938
|
+
* ```js
|
|
3939
|
+
* // Before running the sample:
|
|
3940
|
+
* // - Enable the API at:
|
|
3941
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
3942
|
+
* // - Login into gcloud by running:
|
|
3943
|
+
* // ```sh
|
|
3944
|
+
* // $ gcloud auth application-default login
|
|
3945
|
+
* // ```
|
|
3946
|
+
* // - Install the npm module by running:
|
|
3947
|
+
* // ```sh
|
|
3948
|
+
* // $ npm install googleapis
|
|
3949
|
+
* // ```
|
|
3950
|
+
*
|
|
3951
|
+
* const {google} = require('googleapis');
|
|
3952
|
+
* const vmmigration = google.vmmigration('v1');
|
|
3953
|
+
*
|
|
3954
|
+
* async function main() {
|
|
3955
|
+
* const auth = new google.auth.GoogleAuth({
|
|
3956
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
3957
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
3958
|
+
* });
|
|
3959
|
+
*
|
|
3960
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
3961
|
+
* const authClient = await auth.getClient();
|
|
3962
|
+
* google.options({auth: authClient});
|
|
3963
|
+
*
|
|
3964
|
+
* // Do the magic
|
|
3965
|
+
* const res = await vmmigration.projects.locations.groups.removeGroupMigration({
|
|
3966
|
+
* // Required. The name of the Group.
|
|
3967
|
+
* group: 'projects/my-project/locations/my-location/groups/my-group',
|
|
3968
|
+
*
|
|
3969
|
+
* // Request body metadata
|
|
3970
|
+
* requestBody: {
|
|
3971
|
+
* // request body parameters
|
|
3972
|
+
* // {
|
|
3973
|
+
* // "migratingVm": "my_migratingVm"
|
|
3974
|
+
* // }
|
|
3975
|
+
* },
|
|
3976
|
+
* });
|
|
3977
|
+
* console.log(res.data);
|
|
3978
|
+
*
|
|
3979
|
+
* // Example response
|
|
3980
|
+
* // {
|
|
3981
|
+
* // "done": false,
|
|
3982
|
+
* // "error": {},
|
|
3983
|
+
* // "metadata": {},
|
|
3984
|
+
* // "name": "my_name",
|
|
3985
|
+
* // "response": {}
|
|
3986
|
+
* // }
|
|
3987
|
+
* }
|
|
3988
|
+
*
|
|
3989
|
+
* main().catch(e => {
|
|
3990
|
+
* console.error(e);
|
|
3991
|
+
* throw e;
|
|
3992
|
+
* });
|
|
3993
|
+
*
|
|
3994
|
+
* ```
|
|
3448
3995
|
*
|
|
3449
3996
|
* @param params - Parameters for request
|
|
3450
3997
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3657,6 +4204,74 @@ export namespace vmmigration_v1 {
|
|
|
3657
4204
|
|
|
3658
4205
|
/**
|
|
3659
4206
|
* Creates a new ImageImport in a given project.
|
|
4207
|
+
* @example
|
|
4208
|
+
* ```js
|
|
4209
|
+
* // Before running the sample:
|
|
4210
|
+
* // - Enable the API at:
|
|
4211
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
4212
|
+
* // - Login into gcloud by running:
|
|
4213
|
+
* // ```sh
|
|
4214
|
+
* // $ gcloud auth application-default login
|
|
4215
|
+
* // ```
|
|
4216
|
+
* // - Install the npm module by running:
|
|
4217
|
+
* // ```sh
|
|
4218
|
+
* // $ npm install googleapis
|
|
4219
|
+
* // ```
|
|
4220
|
+
*
|
|
4221
|
+
* const {google} = require('googleapis');
|
|
4222
|
+
* const vmmigration = google.vmmigration('v1');
|
|
4223
|
+
*
|
|
4224
|
+
* async function main() {
|
|
4225
|
+
* const auth = new google.auth.GoogleAuth({
|
|
4226
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
4227
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
4228
|
+
* });
|
|
4229
|
+
*
|
|
4230
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
4231
|
+
* const authClient = await auth.getClient();
|
|
4232
|
+
* google.options({auth: authClient});
|
|
4233
|
+
*
|
|
4234
|
+
* // Do the magic
|
|
4235
|
+
* const res = await vmmigration.projects.locations.imageImports.create({
|
|
4236
|
+
* // Required. The image import identifier. This value maximum length is 63 characters, and valid characters are /a-z-/. It must start with an english letter and must not end with a hyphen.
|
|
4237
|
+
* imageImportId: 'placeholder-value',
|
|
4238
|
+
* // Required. The ImageImport's parent.
|
|
4239
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
4240
|
+
* // Optional. A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
4241
|
+
* requestId: 'placeholder-value',
|
|
4242
|
+
*
|
|
4243
|
+
* // Request body metadata
|
|
4244
|
+
* requestBody: {
|
|
4245
|
+
* // request body parameters
|
|
4246
|
+
* // {
|
|
4247
|
+
* // "cloudStorageUri": "my_cloudStorageUri",
|
|
4248
|
+
* // "createTime": "my_createTime",
|
|
4249
|
+
* // "diskImageTargetDefaults": {},
|
|
4250
|
+
* // "encryption": {},
|
|
4251
|
+
* // "machineImageTargetDefaults": {},
|
|
4252
|
+
* // "name": "my_name",
|
|
4253
|
+
* // "recentImageImportJobs": []
|
|
4254
|
+
* // }
|
|
4255
|
+
* },
|
|
4256
|
+
* });
|
|
4257
|
+
* console.log(res.data);
|
|
4258
|
+
*
|
|
4259
|
+
* // Example response
|
|
4260
|
+
* // {
|
|
4261
|
+
* // "done": false,
|
|
4262
|
+
* // "error": {},
|
|
4263
|
+
* // "metadata": {},
|
|
4264
|
+
* // "name": "my_name",
|
|
4265
|
+
* // "response": {}
|
|
4266
|
+
* // }
|
|
4267
|
+
* }
|
|
4268
|
+
*
|
|
4269
|
+
* main().catch(e => {
|
|
4270
|
+
* console.error(e);
|
|
4271
|
+
* throw e;
|
|
4272
|
+
* });
|
|
4273
|
+
*
|
|
4274
|
+
* ```
|
|
3660
4275
|
*
|
|
3661
4276
|
* @param params - Parameters for request
|
|
3662
4277
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3748,6 +4363,58 @@ export namespace vmmigration_v1 {
|
|
|
3748
4363
|
|
|
3749
4364
|
/**
|
|
3750
4365
|
* Deletes a single ImageImport.
|
|
4366
|
+
* @example
|
|
4367
|
+
* ```js
|
|
4368
|
+
* // Before running the sample:
|
|
4369
|
+
* // - Enable the API at:
|
|
4370
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
4371
|
+
* // - Login into gcloud by running:
|
|
4372
|
+
* // ```sh
|
|
4373
|
+
* // $ gcloud auth application-default login
|
|
4374
|
+
* // ```
|
|
4375
|
+
* // - Install the npm module by running:
|
|
4376
|
+
* // ```sh
|
|
4377
|
+
* // $ npm install googleapis
|
|
4378
|
+
* // ```
|
|
4379
|
+
*
|
|
4380
|
+
* const {google} = require('googleapis');
|
|
4381
|
+
* const vmmigration = google.vmmigration('v1');
|
|
4382
|
+
*
|
|
4383
|
+
* async function main() {
|
|
4384
|
+
* const auth = new google.auth.GoogleAuth({
|
|
4385
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
4386
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
4387
|
+
* });
|
|
4388
|
+
*
|
|
4389
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
4390
|
+
* const authClient = await auth.getClient();
|
|
4391
|
+
* google.options({auth: authClient});
|
|
4392
|
+
*
|
|
4393
|
+
* // Do the magic
|
|
4394
|
+
* const res = await vmmigration.projects.locations.imageImports.delete({
|
|
4395
|
+
* // Required. The ImageImport name.
|
|
4396
|
+
* name: 'projects/my-project/locations/my-location/imageImports/my-imageImport',
|
|
4397
|
+
* // Optional. A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and t he request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
4398
|
+
* requestId: 'placeholder-value',
|
|
4399
|
+
* });
|
|
4400
|
+
* console.log(res.data);
|
|
4401
|
+
*
|
|
4402
|
+
* // Example response
|
|
4403
|
+
* // {
|
|
4404
|
+
* // "done": false,
|
|
4405
|
+
* // "error": {},
|
|
4406
|
+
* // "metadata": {},
|
|
4407
|
+
* // "name": "my_name",
|
|
4408
|
+
* // "response": {}
|
|
4409
|
+
* // }
|
|
4410
|
+
* }
|
|
4411
|
+
*
|
|
4412
|
+
* main().catch(e => {
|
|
4413
|
+
* console.error(e);
|
|
4414
|
+
* throw e;
|
|
4415
|
+
* });
|
|
4416
|
+
*
|
|
4417
|
+
* ```
|
|
3751
4418
|
*
|
|
3752
4419
|
* @param params - Parameters for request
|
|
3753
4420
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3836,6 +4503,58 @@ export namespace vmmigration_v1 {
|
|
|
3836
4503
|
|
|
3837
4504
|
/**
|
|
3838
4505
|
* Gets details of a single ImageImport.
|
|
4506
|
+
* @example
|
|
4507
|
+
* ```js
|
|
4508
|
+
* // Before running the sample:
|
|
4509
|
+
* // - Enable the API at:
|
|
4510
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
4511
|
+
* // - Login into gcloud by running:
|
|
4512
|
+
* // ```sh
|
|
4513
|
+
* // $ gcloud auth application-default login
|
|
4514
|
+
* // ```
|
|
4515
|
+
* // - Install the npm module by running:
|
|
4516
|
+
* // ```sh
|
|
4517
|
+
* // $ npm install googleapis
|
|
4518
|
+
* // ```
|
|
4519
|
+
*
|
|
4520
|
+
* const {google} = require('googleapis');
|
|
4521
|
+
* const vmmigration = google.vmmigration('v1');
|
|
4522
|
+
*
|
|
4523
|
+
* async function main() {
|
|
4524
|
+
* const auth = new google.auth.GoogleAuth({
|
|
4525
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
4526
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
4527
|
+
* });
|
|
4528
|
+
*
|
|
4529
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
4530
|
+
* const authClient = await auth.getClient();
|
|
4531
|
+
* google.options({auth: authClient});
|
|
4532
|
+
*
|
|
4533
|
+
* // Do the magic
|
|
4534
|
+
* const res = await vmmigration.projects.locations.imageImports.get({
|
|
4535
|
+
* // Required. The ImageImport name.
|
|
4536
|
+
* name: 'projects/my-project/locations/my-location/imageImports/my-imageImport',
|
|
4537
|
+
* });
|
|
4538
|
+
* console.log(res.data);
|
|
4539
|
+
*
|
|
4540
|
+
* // Example response
|
|
4541
|
+
* // {
|
|
4542
|
+
* // "cloudStorageUri": "my_cloudStorageUri",
|
|
4543
|
+
* // "createTime": "my_createTime",
|
|
4544
|
+
* // "diskImageTargetDefaults": {},
|
|
4545
|
+
* // "encryption": {},
|
|
4546
|
+
* // "machineImageTargetDefaults": {},
|
|
4547
|
+
* // "name": "my_name",
|
|
4548
|
+
* // "recentImageImportJobs": []
|
|
4549
|
+
* // }
|
|
4550
|
+
* }
|
|
4551
|
+
*
|
|
4552
|
+
* main().catch(e => {
|
|
4553
|
+
* console.error(e);
|
|
4554
|
+
* throw e;
|
|
4555
|
+
* });
|
|
4556
|
+
*
|
|
4557
|
+
* ```
|
|
3839
4558
|
*
|
|
3840
4559
|
* @param params - Parameters for request
|
|
3841
4560
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -3924,6 +4643,62 @@ export namespace vmmigration_v1 {
|
|
|
3924
4643
|
|
|
3925
4644
|
/**
|
|
3926
4645
|
* Lists ImageImports in a given project.
|
|
4646
|
+
* @example
|
|
4647
|
+
* ```js
|
|
4648
|
+
* // Before running the sample:
|
|
4649
|
+
* // - Enable the API at:
|
|
4650
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
4651
|
+
* // - Login into gcloud by running:
|
|
4652
|
+
* // ```sh
|
|
4653
|
+
* // $ gcloud auth application-default login
|
|
4654
|
+
* // ```
|
|
4655
|
+
* // - Install the npm module by running:
|
|
4656
|
+
* // ```sh
|
|
4657
|
+
* // $ npm install googleapis
|
|
4658
|
+
* // ```
|
|
4659
|
+
*
|
|
4660
|
+
* const {google} = require('googleapis');
|
|
4661
|
+
* const vmmigration = google.vmmigration('v1');
|
|
4662
|
+
*
|
|
4663
|
+
* async function main() {
|
|
4664
|
+
* const auth = new google.auth.GoogleAuth({
|
|
4665
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
4666
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
4667
|
+
* });
|
|
4668
|
+
*
|
|
4669
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
4670
|
+
* const authClient = await auth.getClient();
|
|
4671
|
+
* google.options({auth: authClient});
|
|
4672
|
+
*
|
|
4673
|
+
* // Do the magic
|
|
4674
|
+
* const res = await vmmigration.projects.locations.imageImports.list({
|
|
4675
|
+
* // Optional. The filter request (according to AIP-160).
|
|
4676
|
+
* filter: 'placeholder-value',
|
|
4677
|
+
* // Optional. The order by fields for the result (according to AIP-132). Currently ordering is only possible by "name" field.
|
|
4678
|
+
* orderBy: 'placeholder-value',
|
|
4679
|
+
* // Optional. The maximum number of targets to return. The service may return fewer than this value. If unspecified, at most 500 targets will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
4680
|
+
* pageSize: 'placeholder-value',
|
|
4681
|
+
* // Optional. A page token, received from a previous `ListImageImports` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListImageImports` must match the call that provided the page token.
|
|
4682
|
+
* pageToken: 'placeholder-value',
|
|
4683
|
+
* // Required. The parent, which owns this collection of targets.
|
|
4684
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
4685
|
+
* });
|
|
4686
|
+
* console.log(res.data);
|
|
4687
|
+
*
|
|
4688
|
+
* // Example response
|
|
4689
|
+
* // {
|
|
4690
|
+
* // "imageImports": [],
|
|
4691
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
4692
|
+
* // "unreachable": []
|
|
4693
|
+
* // }
|
|
4694
|
+
* }
|
|
4695
|
+
*
|
|
4696
|
+
* main().catch(e => {
|
|
4697
|
+
* console.error(e);
|
|
4698
|
+
* throw e;
|
|
4699
|
+
* });
|
|
4700
|
+
*
|
|
4701
|
+
* ```
|
|
3927
4702
|
*
|
|
3928
4703
|
* @param params - Parameters for request
|
|
3929
4704
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4086,6 +4861,63 @@ export namespace vmmigration_v1 {
|
|
|
4086
4861
|
|
|
4087
4862
|
/**
|
|
4088
4863
|
* Initiates the cancellation of a running clone job.
|
|
4864
|
+
* @example
|
|
4865
|
+
* ```js
|
|
4866
|
+
* // Before running the sample:
|
|
4867
|
+
* // - Enable the API at:
|
|
4868
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
4869
|
+
* // - Login into gcloud by running:
|
|
4870
|
+
* // ```sh
|
|
4871
|
+
* // $ gcloud auth application-default login
|
|
4872
|
+
* // ```
|
|
4873
|
+
* // - Install the npm module by running:
|
|
4874
|
+
* // ```sh
|
|
4875
|
+
* // $ npm install googleapis
|
|
4876
|
+
* // ```
|
|
4877
|
+
*
|
|
4878
|
+
* const {google} = require('googleapis');
|
|
4879
|
+
* const vmmigration = google.vmmigration('v1');
|
|
4880
|
+
*
|
|
4881
|
+
* async function main() {
|
|
4882
|
+
* const auth = new google.auth.GoogleAuth({
|
|
4883
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
4884
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
4885
|
+
* });
|
|
4886
|
+
*
|
|
4887
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
4888
|
+
* const authClient = await auth.getClient();
|
|
4889
|
+
* google.options({auth: authClient});
|
|
4890
|
+
*
|
|
4891
|
+
* // Do the magic
|
|
4892
|
+
* const res =
|
|
4893
|
+
* await vmmigration.projects.locations.imageImports.imageImportJobs.cancel({
|
|
4894
|
+
* // Required. The image import job id.
|
|
4895
|
+
* name: 'projects/my-project/locations/my-location/imageImports/my-imageImport/imageImportJobs/my-imageImportJob',
|
|
4896
|
+
*
|
|
4897
|
+
* // Request body metadata
|
|
4898
|
+
* requestBody: {
|
|
4899
|
+
* // request body parameters
|
|
4900
|
+
* // {}
|
|
4901
|
+
* },
|
|
4902
|
+
* });
|
|
4903
|
+
* console.log(res.data);
|
|
4904
|
+
*
|
|
4905
|
+
* // Example response
|
|
4906
|
+
* // {
|
|
4907
|
+
* // "done": false,
|
|
4908
|
+
* // "error": {},
|
|
4909
|
+
* // "metadata": {},
|
|
4910
|
+
* // "name": "my_name",
|
|
4911
|
+
* // "response": {}
|
|
4912
|
+
* // }
|
|
4913
|
+
* }
|
|
4914
|
+
*
|
|
4915
|
+
* main().catch(e => {
|
|
4916
|
+
* console.error(e);
|
|
4917
|
+
* throw e;
|
|
4918
|
+
* });
|
|
4919
|
+
*
|
|
4920
|
+
* ```
|
|
4089
4921
|
*
|
|
4090
4922
|
* @param params - Parameters for request
|
|
4091
4923
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4175,6 +5007,63 @@ export namespace vmmigration_v1 {
|
|
|
4175
5007
|
|
|
4176
5008
|
/**
|
|
4177
5009
|
* Gets details of a single ImageImportJob.
|
|
5010
|
+
* @example
|
|
5011
|
+
* ```js
|
|
5012
|
+
* // Before running the sample:
|
|
5013
|
+
* // - Enable the API at:
|
|
5014
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
5015
|
+
* // - Login into gcloud by running:
|
|
5016
|
+
* // ```sh
|
|
5017
|
+
* // $ gcloud auth application-default login
|
|
5018
|
+
* // ```
|
|
5019
|
+
* // - Install the npm module by running:
|
|
5020
|
+
* // ```sh
|
|
5021
|
+
* // $ npm install googleapis
|
|
5022
|
+
* // ```
|
|
5023
|
+
*
|
|
5024
|
+
* const {google} = require('googleapis');
|
|
5025
|
+
* const vmmigration = google.vmmigration('v1');
|
|
5026
|
+
*
|
|
5027
|
+
* async function main() {
|
|
5028
|
+
* const auth = new google.auth.GoogleAuth({
|
|
5029
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
5030
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
5031
|
+
* });
|
|
5032
|
+
*
|
|
5033
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
5034
|
+
* const authClient = await auth.getClient();
|
|
5035
|
+
* google.options({auth: authClient});
|
|
5036
|
+
*
|
|
5037
|
+
* // Do the magic
|
|
5038
|
+
* const res =
|
|
5039
|
+
* await vmmigration.projects.locations.imageImports.imageImportJobs.get({
|
|
5040
|
+
* // Required. The ImageImportJob name.
|
|
5041
|
+
* name: 'projects/my-project/locations/my-location/imageImports/my-imageImport/imageImportJobs/my-imageImportJob',
|
|
5042
|
+
* });
|
|
5043
|
+
* console.log(res.data);
|
|
5044
|
+
*
|
|
5045
|
+
* // Example response
|
|
5046
|
+
* // {
|
|
5047
|
+
* // "cloudStorageUri": "my_cloudStorageUri",
|
|
5048
|
+
* // "createTime": "my_createTime",
|
|
5049
|
+
* // "createdResources": [],
|
|
5050
|
+
* // "diskImageTargetDetails": {},
|
|
5051
|
+
* // "endTime": "my_endTime",
|
|
5052
|
+
* // "errors": [],
|
|
5053
|
+
* // "machineImageTargetDetails": {},
|
|
5054
|
+
* // "name": "my_name",
|
|
5055
|
+
* // "state": "my_state",
|
|
5056
|
+
* // "steps": [],
|
|
5057
|
+
* // "warnings": []
|
|
5058
|
+
* // }
|
|
5059
|
+
* }
|
|
5060
|
+
*
|
|
5061
|
+
* main().catch(e => {
|
|
5062
|
+
* console.error(e);
|
|
5063
|
+
* throw e;
|
|
5064
|
+
* });
|
|
5065
|
+
*
|
|
5066
|
+
* ```
|
|
4178
5067
|
*
|
|
4179
5068
|
* @param params - Parameters for request
|
|
4180
5069
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4264,6 +5153,64 @@ export namespace vmmigration_v1 {
|
|
|
4264
5153
|
|
|
4265
5154
|
/**
|
|
4266
5155
|
* Lists ImageImportJobs in a given project.
|
|
5156
|
+
* @example
|
|
5157
|
+
* ```js
|
|
5158
|
+
* // Before running the sample:
|
|
5159
|
+
* // - Enable the API at:
|
|
5160
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
5161
|
+
* // - Login into gcloud by running:
|
|
5162
|
+
* // ```sh
|
|
5163
|
+
* // $ gcloud auth application-default login
|
|
5164
|
+
* // ```
|
|
5165
|
+
* // - Install the npm module by running:
|
|
5166
|
+
* // ```sh
|
|
5167
|
+
* // $ npm install googleapis
|
|
5168
|
+
* // ```
|
|
5169
|
+
*
|
|
5170
|
+
* const {google} = require('googleapis');
|
|
5171
|
+
* const vmmigration = google.vmmigration('v1');
|
|
5172
|
+
*
|
|
5173
|
+
* async function main() {
|
|
5174
|
+
* const auth = new google.auth.GoogleAuth({
|
|
5175
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
5176
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
5177
|
+
* });
|
|
5178
|
+
*
|
|
5179
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
5180
|
+
* const authClient = await auth.getClient();
|
|
5181
|
+
* google.options({auth: authClient});
|
|
5182
|
+
*
|
|
5183
|
+
* // Do the magic
|
|
5184
|
+
* const res =
|
|
5185
|
+
* await vmmigration.projects.locations.imageImports.imageImportJobs.list({
|
|
5186
|
+
* // Optional. The filter request (according to AIP-160).
|
|
5187
|
+
* filter: 'placeholder-value',
|
|
5188
|
+
* // Optional. The order by fields for the result (according to AIP-132). Currently ordering is only possible by "name" field.
|
|
5189
|
+
* orderBy: 'placeholder-value',
|
|
5190
|
+
* // Optional. The maximum number of targets to return. The service may return fewer than this value. If unspecified, at most 500 targets will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
5191
|
+
* pageSize: 'placeholder-value',
|
|
5192
|
+
* // Optional. A page token, received from a previous `ListImageImportJobs` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListImageImportJobs` must match the call that provided the page token.
|
|
5193
|
+
* pageToken: 'placeholder-value',
|
|
5194
|
+
* // Required. The parent, which owns this collection of targets.
|
|
5195
|
+
* parent:
|
|
5196
|
+
* 'projects/my-project/locations/my-location/imageImports/my-imageImport',
|
|
5197
|
+
* });
|
|
5198
|
+
* console.log(res.data);
|
|
5199
|
+
*
|
|
5200
|
+
* // Example response
|
|
5201
|
+
* // {
|
|
5202
|
+
* // "imageImportJobs": [],
|
|
5203
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
5204
|
+
* // "unreachable": []
|
|
5205
|
+
* // }
|
|
5206
|
+
* }
|
|
5207
|
+
*
|
|
5208
|
+
* main().catch(e => {
|
|
5209
|
+
* console.error(e);
|
|
5210
|
+
* throw e;
|
|
5211
|
+
* });
|
|
5212
|
+
*
|
|
5213
|
+
* ```
|
|
4267
5214
|
*
|
|
4268
5215
|
* @param params - Parameters for request
|
|
4269
5216
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4410,6 +5357,56 @@ export namespace vmmigration_v1 {
|
|
|
4410
5357
|
|
|
4411
5358
|
/**
|
|
4412
5359
|
* Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of `1`, corresponding to `Code.CANCELLED`.
|
|
5360
|
+
* @example
|
|
5361
|
+
* ```js
|
|
5362
|
+
* // Before running the sample:
|
|
5363
|
+
* // - Enable the API at:
|
|
5364
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
5365
|
+
* // - Login into gcloud by running:
|
|
5366
|
+
* // ```sh
|
|
5367
|
+
* // $ gcloud auth application-default login
|
|
5368
|
+
* // ```
|
|
5369
|
+
* // - Install the npm module by running:
|
|
5370
|
+
* // ```sh
|
|
5371
|
+
* // $ npm install googleapis
|
|
5372
|
+
* // ```
|
|
5373
|
+
*
|
|
5374
|
+
* const {google} = require('googleapis');
|
|
5375
|
+
* const vmmigration = google.vmmigration('v1');
|
|
5376
|
+
*
|
|
5377
|
+
* async function main() {
|
|
5378
|
+
* const auth = new google.auth.GoogleAuth({
|
|
5379
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
5380
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
5381
|
+
* });
|
|
5382
|
+
*
|
|
5383
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
5384
|
+
* const authClient = await auth.getClient();
|
|
5385
|
+
* google.options({auth: authClient});
|
|
5386
|
+
*
|
|
5387
|
+
* // Do the magic
|
|
5388
|
+
* const res = await vmmigration.projects.locations.operations.cancel({
|
|
5389
|
+
* // The name of the operation resource to be cancelled.
|
|
5390
|
+
* name: 'projects/my-project/locations/my-location/operations/my-operation',
|
|
5391
|
+
*
|
|
5392
|
+
* // Request body metadata
|
|
5393
|
+
* requestBody: {
|
|
5394
|
+
* // request body parameters
|
|
5395
|
+
* // {}
|
|
5396
|
+
* },
|
|
5397
|
+
* });
|
|
5398
|
+
* console.log(res.data);
|
|
5399
|
+
*
|
|
5400
|
+
* // Example response
|
|
5401
|
+
* // {}
|
|
5402
|
+
* }
|
|
5403
|
+
*
|
|
5404
|
+
* main().catch(e => {
|
|
5405
|
+
* console.error(e);
|
|
5406
|
+
* throw e;
|
|
5407
|
+
* });
|
|
5408
|
+
*
|
|
5409
|
+
* ```
|
|
4413
5410
|
*
|
|
4414
5411
|
* @param params - Parameters for request
|
|
4415
5412
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4498,6 +5495,50 @@ export namespace vmmigration_v1 {
|
|
|
4498
5495
|
|
|
4499
5496
|
/**
|
|
4500
5497
|
* Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
|
|
5498
|
+
* @example
|
|
5499
|
+
* ```js
|
|
5500
|
+
* // Before running the sample:
|
|
5501
|
+
* // - Enable the API at:
|
|
5502
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
5503
|
+
* // - Login into gcloud by running:
|
|
5504
|
+
* // ```sh
|
|
5505
|
+
* // $ gcloud auth application-default login
|
|
5506
|
+
* // ```
|
|
5507
|
+
* // - Install the npm module by running:
|
|
5508
|
+
* // ```sh
|
|
5509
|
+
* // $ npm install googleapis
|
|
5510
|
+
* // ```
|
|
5511
|
+
*
|
|
5512
|
+
* const {google} = require('googleapis');
|
|
5513
|
+
* const vmmigration = google.vmmigration('v1');
|
|
5514
|
+
*
|
|
5515
|
+
* async function main() {
|
|
5516
|
+
* const auth = new google.auth.GoogleAuth({
|
|
5517
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
5518
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
5519
|
+
* });
|
|
5520
|
+
*
|
|
5521
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
5522
|
+
* const authClient = await auth.getClient();
|
|
5523
|
+
* google.options({auth: authClient});
|
|
5524
|
+
*
|
|
5525
|
+
* // Do the magic
|
|
5526
|
+
* const res = await vmmigration.projects.locations.operations.delete({
|
|
5527
|
+
* // The name of the operation resource to be deleted.
|
|
5528
|
+
* name: 'projects/my-project/locations/my-location/operations/my-operation',
|
|
5529
|
+
* });
|
|
5530
|
+
* console.log(res.data);
|
|
5531
|
+
*
|
|
5532
|
+
* // Example response
|
|
5533
|
+
* // {}
|
|
5534
|
+
* }
|
|
5535
|
+
*
|
|
5536
|
+
* main().catch(e => {
|
|
5537
|
+
* console.error(e);
|
|
5538
|
+
* throw e;
|
|
5539
|
+
* });
|
|
5540
|
+
*
|
|
5541
|
+
* ```
|
|
4501
5542
|
*
|
|
4502
5543
|
* @param params - Parameters for request
|
|
4503
5544
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4586,6 +5627,56 @@ export namespace vmmigration_v1 {
|
|
|
4586
5627
|
|
|
4587
5628
|
/**
|
|
4588
5629
|
* Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.
|
|
5630
|
+
* @example
|
|
5631
|
+
* ```js
|
|
5632
|
+
* // Before running the sample:
|
|
5633
|
+
* // - Enable the API at:
|
|
5634
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
5635
|
+
* // - Login into gcloud by running:
|
|
5636
|
+
* // ```sh
|
|
5637
|
+
* // $ gcloud auth application-default login
|
|
5638
|
+
* // ```
|
|
5639
|
+
* // - Install the npm module by running:
|
|
5640
|
+
* // ```sh
|
|
5641
|
+
* // $ npm install googleapis
|
|
5642
|
+
* // ```
|
|
5643
|
+
*
|
|
5644
|
+
* const {google} = require('googleapis');
|
|
5645
|
+
* const vmmigration = google.vmmigration('v1');
|
|
5646
|
+
*
|
|
5647
|
+
* async function main() {
|
|
5648
|
+
* const auth = new google.auth.GoogleAuth({
|
|
5649
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
5650
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
5651
|
+
* });
|
|
5652
|
+
*
|
|
5653
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
5654
|
+
* const authClient = await auth.getClient();
|
|
5655
|
+
* google.options({auth: authClient});
|
|
5656
|
+
*
|
|
5657
|
+
* // Do the magic
|
|
5658
|
+
* const res = await vmmigration.projects.locations.operations.get({
|
|
5659
|
+
* // The name of the operation resource.
|
|
5660
|
+
* name: 'projects/my-project/locations/my-location/operations/my-operation',
|
|
5661
|
+
* });
|
|
5662
|
+
* console.log(res.data);
|
|
5663
|
+
*
|
|
5664
|
+
* // Example response
|
|
5665
|
+
* // {
|
|
5666
|
+
* // "done": false,
|
|
5667
|
+
* // "error": {},
|
|
5668
|
+
* // "metadata": {},
|
|
5669
|
+
* // "name": "my_name",
|
|
5670
|
+
* // "response": {}
|
|
5671
|
+
* // }
|
|
5672
|
+
* }
|
|
5673
|
+
*
|
|
5674
|
+
* main().catch(e => {
|
|
5675
|
+
* console.error(e);
|
|
5676
|
+
* throw e;
|
|
5677
|
+
* });
|
|
5678
|
+
*
|
|
5679
|
+
* ```
|
|
4589
5680
|
*
|
|
4590
5681
|
* @param params - Parameters for request
|
|
4591
5682
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4674,6 +5765,59 @@ export namespace vmmigration_v1 {
|
|
|
4674
5765
|
|
|
4675
5766
|
/**
|
|
4676
5767
|
* Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.
|
|
5768
|
+
* @example
|
|
5769
|
+
* ```js
|
|
5770
|
+
* // Before running the sample:
|
|
5771
|
+
* // - Enable the API at:
|
|
5772
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
5773
|
+
* // - Login into gcloud by running:
|
|
5774
|
+
* // ```sh
|
|
5775
|
+
* // $ gcloud auth application-default login
|
|
5776
|
+
* // ```
|
|
5777
|
+
* // - Install the npm module by running:
|
|
5778
|
+
* // ```sh
|
|
5779
|
+
* // $ npm install googleapis
|
|
5780
|
+
* // ```
|
|
5781
|
+
*
|
|
5782
|
+
* const {google} = require('googleapis');
|
|
5783
|
+
* const vmmigration = google.vmmigration('v1');
|
|
5784
|
+
*
|
|
5785
|
+
* async function main() {
|
|
5786
|
+
* const auth = new google.auth.GoogleAuth({
|
|
5787
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
5788
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
5789
|
+
* });
|
|
5790
|
+
*
|
|
5791
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
5792
|
+
* const authClient = await auth.getClient();
|
|
5793
|
+
* google.options({auth: authClient});
|
|
5794
|
+
*
|
|
5795
|
+
* // Do the magic
|
|
5796
|
+
* const res = await vmmigration.projects.locations.operations.list({
|
|
5797
|
+
* // The standard list filter.
|
|
5798
|
+
* filter: 'placeholder-value',
|
|
5799
|
+
* // The name of the operation's parent resource.
|
|
5800
|
+
* name: 'projects/my-project/locations/my-location',
|
|
5801
|
+
* // The standard list page size.
|
|
5802
|
+
* pageSize: 'placeholder-value',
|
|
5803
|
+
* // The standard list page token.
|
|
5804
|
+
* pageToken: 'placeholder-value',
|
|
5805
|
+
* });
|
|
5806
|
+
* console.log(res.data);
|
|
5807
|
+
*
|
|
5808
|
+
* // Example response
|
|
5809
|
+
* // {
|
|
5810
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
5811
|
+
* // "operations": []
|
|
5812
|
+
* // }
|
|
5813
|
+
* }
|
|
5814
|
+
*
|
|
5815
|
+
* main().catch(e => {
|
|
5816
|
+
* console.error(e);
|
|
5817
|
+
* throw e;
|
|
5818
|
+
* });
|
|
5819
|
+
*
|
|
5820
|
+
* ```
|
|
4677
5821
|
*
|
|
4678
5822
|
* @param params - Parameters for request
|
|
4679
5823
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4834,6 +5978,76 @@ export namespace vmmigration_v1 {
|
|
|
4834
5978
|
|
|
4835
5979
|
/**
|
|
4836
5980
|
* Creates a new Source in a given project and location.
|
|
5981
|
+
* @example
|
|
5982
|
+
* ```js
|
|
5983
|
+
* // Before running the sample:
|
|
5984
|
+
* // - Enable the API at:
|
|
5985
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
5986
|
+
* // - Login into gcloud by running:
|
|
5987
|
+
* // ```sh
|
|
5988
|
+
* // $ gcloud auth application-default login
|
|
5989
|
+
* // ```
|
|
5990
|
+
* // - Install the npm module by running:
|
|
5991
|
+
* // ```sh
|
|
5992
|
+
* // $ npm install googleapis
|
|
5993
|
+
* // ```
|
|
5994
|
+
*
|
|
5995
|
+
* const {google} = require('googleapis');
|
|
5996
|
+
* const vmmigration = google.vmmigration('v1');
|
|
5997
|
+
*
|
|
5998
|
+
* async function main() {
|
|
5999
|
+
* const auth = new google.auth.GoogleAuth({
|
|
6000
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
6001
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
6002
|
+
* });
|
|
6003
|
+
*
|
|
6004
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
6005
|
+
* const authClient = await auth.getClient();
|
|
6006
|
+
* google.options({auth: authClient});
|
|
6007
|
+
*
|
|
6008
|
+
* // Do the magic
|
|
6009
|
+
* const res = await vmmigration.projects.locations.sources.create({
|
|
6010
|
+
* // Required. The Source's parent.
|
|
6011
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
6012
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
6013
|
+
* requestId: 'placeholder-value',
|
|
6014
|
+
* // Required. The source identifier.
|
|
6015
|
+
* sourceId: 'placeholder-value',
|
|
6016
|
+
*
|
|
6017
|
+
* // Request body metadata
|
|
6018
|
+
* requestBody: {
|
|
6019
|
+
* // request body parameters
|
|
6020
|
+
* // {
|
|
6021
|
+
* // "aws": {},
|
|
6022
|
+
* // "azure": {},
|
|
6023
|
+
* // "createTime": "my_createTime",
|
|
6024
|
+
* // "description": "my_description",
|
|
6025
|
+
* // "encryption": {},
|
|
6026
|
+
* // "labels": {},
|
|
6027
|
+
* // "name": "my_name",
|
|
6028
|
+
* // "updateTime": "my_updateTime",
|
|
6029
|
+
* // "vmware": {}
|
|
6030
|
+
* // }
|
|
6031
|
+
* },
|
|
6032
|
+
* });
|
|
6033
|
+
* console.log(res.data);
|
|
6034
|
+
*
|
|
6035
|
+
* // Example response
|
|
6036
|
+
* // {
|
|
6037
|
+
* // "done": false,
|
|
6038
|
+
* // "error": {},
|
|
6039
|
+
* // "metadata": {},
|
|
6040
|
+
* // "name": "my_name",
|
|
6041
|
+
* // "response": {}
|
|
6042
|
+
* // }
|
|
6043
|
+
* }
|
|
6044
|
+
*
|
|
6045
|
+
* main().catch(e => {
|
|
6046
|
+
* console.error(e);
|
|
6047
|
+
* throw e;
|
|
6048
|
+
* });
|
|
6049
|
+
*
|
|
6050
|
+
* ```
|
|
4837
6051
|
*
|
|
4838
6052
|
* @param params - Parameters for request
|
|
4839
6053
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -4925,6 +6139,58 @@ export namespace vmmigration_v1 {
|
|
|
4925
6139
|
|
|
4926
6140
|
/**
|
|
4927
6141
|
* Deletes a single Source.
|
|
6142
|
+
* @example
|
|
6143
|
+
* ```js
|
|
6144
|
+
* // Before running the sample:
|
|
6145
|
+
* // - Enable the API at:
|
|
6146
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
6147
|
+
* // - Login into gcloud by running:
|
|
6148
|
+
* // ```sh
|
|
6149
|
+
* // $ gcloud auth application-default login
|
|
6150
|
+
* // ```
|
|
6151
|
+
* // - Install the npm module by running:
|
|
6152
|
+
* // ```sh
|
|
6153
|
+
* // $ npm install googleapis
|
|
6154
|
+
* // ```
|
|
6155
|
+
*
|
|
6156
|
+
* const {google} = require('googleapis');
|
|
6157
|
+
* const vmmigration = google.vmmigration('v1');
|
|
6158
|
+
*
|
|
6159
|
+
* async function main() {
|
|
6160
|
+
* const auth = new google.auth.GoogleAuth({
|
|
6161
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
6162
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
6163
|
+
* });
|
|
6164
|
+
*
|
|
6165
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
6166
|
+
* const authClient = await auth.getClient();
|
|
6167
|
+
* google.options({auth: authClient});
|
|
6168
|
+
*
|
|
6169
|
+
* // Do the magic
|
|
6170
|
+
* const res = await vmmigration.projects.locations.sources.delete({
|
|
6171
|
+
* // Required. The Source name.
|
|
6172
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source',
|
|
6173
|
+
* // Optional. A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
6174
|
+
* requestId: 'placeholder-value',
|
|
6175
|
+
* });
|
|
6176
|
+
* console.log(res.data);
|
|
6177
|
+
*
|
|
6178
|
+
* // Example response
|
|
6179
|
+
* // {
|
|
6180
|
+
* // "done": false,
|
|
6181
|
+
* // "error": {},
|
|
6182
|
+
* // "metadata": {},
|
|
6183
|
+
* // "name": "my_name",
|
|
6184
|
+
* // "response": {}
|
|
6185
|
+
* // }
|
|
6186
|
+
* }
|
|
6187
|
+
*
|
|
6188
|
+
* main().catch(e => {
|
|
6189
|
+
* console.error(e);
|
|
6190
|
+
* throw e;
|
|
6191
|
+
* });
|
|
6192
|
+
*
|
|
6193
|
+
* ```
|
|
4928
6194
|
*
|
|
4929
6195
|
* @param params - Parameters for request
|
|
4930
6196
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5013,6 +6279,62 @@ export namespace vmmigration_v1 {
|
|
|
5013
6279
|
|
|
5014
6280
|
/**
|
|
5015
6281
|
* List remote source's inventory of VMs. The remote source is the onprem vCenter (remote in the sense it's not in Compute Engine). The inventory describes the list of existing VMs in that source. Note that this operation lists the VMs on the remote source, as opposed to listing the MigratingVms resources in the vmmigration service.
|
|
6282
|
+
* @example
|
|
6283
|
+
* ```js
|
|
6284
|
+
* // Before running the sample:
|
|
6285
|
+
* // - Enable the API at:
|
|
6286
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
6287
|
+
* // - Login into gcloud by running:
|
|
6288
|
+
* // ```sh
|
|
6289
|
+
* // $ gcloud auth application-default login
|
|
6290
|
+
* // ```
|
|
6291
|
+
* // - Install the npm module by running:
|
|
6292
|
+
* // ```sh
|
|
6293
|
+
* // $ npm install googleapis
|
|
6294
|
+
* // ```
|
|
6295
|
+
*
|
|
6296
|
+
* const {google} = require('googleapis');
|
|
6297
|
+
* const vmmigration = google.vmmigration('v1');
|
|
6298
|
+
*
|
|
6299
|
+
* async function main() {
|
|
6300
|
+
* const auth = new google.auth.GoogleAuth({
|
|
6301
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
6302
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
6303
|
+
* });
|
|
6304
|
+
*
|
|
6305
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
6306
|
+
* const authClient = await auth.getClient();
|
|
6307
|
+
* google.options({auth: authClient});
|
|
6308
|
+
*
|
|
6309
|
+
* // Do the magic
|
|
6310
|
+
* const res = await vmmigration.projects.locations.sources.fetchInventory({
|
|
6311
|
+
* // If this flag is set to true, the source will be queried instead of using cached results. Using this flag will make the call slower.
|
|
6312
|
+
* forceRefresh: 'placeholder-value',
|
|
6313
|
+
* // The maximum number of VMs to return. The service may return fewer than this value. For AWS source: If unspecified, at most 500 VMs will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000. For VMWare source: If unspecified, all VMs will be returned. There is no limit for maximum value.
|
|
6314
|
+
* pageSize: 'placeholder-value',
|
|
6315
|
+
* // A page token, received from a previous `FetchInventory` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `FetchInventory` must match the call that provided the page token.
|
|
6316
|
+
* pageToken: 'placeholder-value',
|
|
6317
|
+
* // Required. The name of the Source.
|
|
6318
|
+
* source: 'projects/my-project/locations/my-location/sources/my-source',
|
|
6319
|
+
* });
|
|
6320
|
+
* console.log(res.data);
|
|
6321
|
+
*
|
|
6322
|
+
* // Example response
|
|
6323
|
+
* // {
|
|
6324
|
+
* // "awsVms": {},
|
|
6325
|
+
* // "azureVms": {},
|
|
6326
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
6327
|
+
* // "updateTime": "my_updateTime",
|
|
6328
|
+
* // "vmwareVms": {}
|
|
6329
|
+
* // }
|
|
6330
|
+
* }
|
|
6331
|
+
*
|
|
6332
|
+
* main().catch(e => {
|
|
6333
|
+
* console.error(e);
|
|
6334
|
+
* throw e;
|
|
6335
|
+
* });
|
|
6336
|
+
*
|
|
6337
|
+
* ```
|
|
5016
6338
|
*
|
|
5017
6339
|
* @param params - Parameters for request
|
|
5018
6340
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5109,6 +6431,60 @@ export namespace vmmigration_v1 {
|
|
|
5109
6431
|
|
|
5110
6432
|
/**
|
|
5111
6433
|
* Gets details of a single Source.
|
|
6434
|
+
* @example
|
|
6435
|
+
* ```js
|
|
6436
|
+
* // Before running the sample:
|
|
6437
|
+
* // - Enable the API at:
|
|
6438
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
6439
|
+
* // - Login into gcloud by running:
|
|
6440
|
+
* // ```sh
|
|
6441
|
+
* // $ gcloud auth application-default login
|
|
6442
|
+
* // ```
|
|
6443
|
+
* // - Install the npm module by running:
|
|
6444
|
+
* // ```sh
|
|
6445
|
+
* // $ npm install googleapis
|
|
6446
|
+
* // ```
|
|
6447
|
+
*
|
|
6448
|
+
* const {google} = require('googleapis');
|
|
6449
|
+
* const vmmigration = google.vmmigration('v1');
|
|
6450
|
+
*
|
|
6451
|
+
* async function main() {
|
|
6452
|
+
* const auth = new google.auth.GoogleAuth({
|
|
6453
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
6454
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
6455
|
+
* });
|
|
6456
|
+
*
|
|
6457
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
6458
|
+
* const authClient = await auth.getClient();
|
|
6459
|
+
* google.options({auth: authClient});
|
|
6460
|
+
*
|
|
6461
|
+
* // Do the magic
|
|
6462
|
+
* const res = await vmmigration.projects.locations.sources.get({
|
|
6463
|
+
* // Required. The Source name.
|
|
6464
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source',
|
|
6465
|
+
* });
|
|
6466
|
+
* console.log(res.data);
|
|
6467
|
+
*
|
|
6468
|
+
* // Example response
|
|
6469
|
+
* // {
|
|
6470
|
+
* // "aws": {},
|
|
6471
|
+
* // "azure": {},
|
|
6472
|
+
* // "createTime": "my_createTime",
|
|
6473
|
+
* // "description": "my_description",
|
|
6474
|
+
* // "encryption": {},
|
|
6475
|
+
* // "labels": {},
|
|
6476
|
+
* // "name": "my_name",
|
|
6477
|
+
* // "updateTime": "my_updateTime",
|
|
6478
|
+
* // "vmware": {}
|
|
6479
|
+
* // }
|
|
6480
|
+
* }
|
|
6481
|
+
*
|
|
6482
|
+
* main().catch(e => {
|
|
6483
|
+
* console.error(e);
|
|
6484
|
+
* throw e;
|
|
6485
|
+
* });
|
|
6486
|
+
*
|
|
6487
|
+
* ```
|
|
5112
6488
|
*
|
|
5113
6489
|
* @param params - Parameters for request
|
|
5114
6490
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5197,6 +6573,62 @@ export namespace vmmigration_v1 {
|
|
|
5197
6573
|
|
|
5198
6574
|
/**
|
|
5199
6575
|
* Lists Sources in a given project and location.
|
|
6576
|
+
* @example
|
|
6577
|
+
* ```js
|
|
6578
|
+
* // Before running the sample:
|
|
6579
|
+
* // - Enable the API at:
|
|
6580
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
6581
|
+
* // - Login into gcloud by running:
|
|
6582
|
+
* // ```sh
|
|
6583
|
+
* // $ gcloud auth application-default login
|
|
6584
|
+
* // ```
|
|
6585
|
+
* // - Install the npm module by running:
|
|
6586
|
+
* // ```sh
|
|
6587
|
+
* // $ npm install googleapis
|
|
6588
|
+
* // ```
|
|
6589
|
+
*
|
|
6590
|
+
* const {google} = require('googleapis');
|
|
6591
|
+
* const vmmigration = google.vmmigration('v1');
|
|
6592
|
+
*
|
|
6593
|
+
* async function main() {
|
|
6594
|
+
* const auth = new google.auth.GoogleAuth({
|
|
6595
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
6596
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
6597
|
+
* });
|
|
6598
|
+
*
|
|
6599
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
6600
|
+
* const authClient = await auth.getClient();
|
|
6601
|
+
* google.options({auth: authClient});
|
|
6602
|
+
*
|
|
6603
|
+
* // Do the magic
|
|
6604
|
+
* const res = await vmmigration.projects.locations.sources.list({
|
|
6605
|
+
* // Optional. The filter request.
|
|
6606
|
+
* filter: 'placeholder-value',
|
|
6607
|
+
* // Optional. the order by fields for the result.
|
|
6608
|
+
* orderBy: 'placeholder-value',
|
|
6609
|
+
* // Optional. The maximum number of sources to return. The service may return fewer than this value. If unspecified, at most 500 sources will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
6610
|
+
* pageSize: 'placeholder-value',
|
|
6611
|
+
* // Required. A page token, received from a previous `ListSources` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListSources` must match the call that provided the page token.
|
|
6612
|
+
* pageToken: 'placeholder-value',
|
|
6613
|
+
* // Required. The parent, which owns this collection of sources.
|
|
6614
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
6615
|
+
* });
|
|
6616
|
+
* console.log(res.data);
|
|
6617
|
+
*
|
|
6618
|
+
* // Example response
|
|
6619
|
+
* // {
|
|
6620
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
6621
|
+
* // "sources": [],
|
|
6622
|
+
* // "unreachable": []
|
|
6623
|
+
* // }
|
|
6624
|
+
* }
|
|
6625
|
+
*
|
|
6626
|
+
* main().catch(e => {
|
|
6627
|
+
* console.error(e);
|
|
6628
|
+
* throw e;
|
|
6629
|
+
* });
|
|
6630
|
+
*
|
|
6631
|
+
* ```
|
|
5200
6632
|
*
|
|
5201
6633
|
* @param params - Parameters for request
|
|
5202
6634
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5288,6 +6720,76 @@ export namespace vmmigration_v1 {
|
|
|
5288
6720
|
|
|
5289
6721
|
/**
|
|
5290
6722
|
* Updates the parameters of a single Source.
|
|
6723
|
+
* @example
|
|
6724
|
+
* ```js
|
|
6725
|
+
* // Before running the sample:
|
|
6726
|
+
* // - Enable the API at:
|
|
6727
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
6728
|
+
* // - Login into gcloud by running:
|
|
6729
|
+
* // ```sh
|
|
6730
|
+
* // $ gcloud auth application-default login
|
|
6731
|
+
* // ```
|
|
6732
|
+
* // - Install the npm module by running:
|
|
6733
|
+
* // ```sh
|
|
6734
|
+
* // $ npm install googleapis
|
|
6735
|
+
* // ```
|
|
6736
|
+
*
|
|
6737
|
+
* const {google} = require('googleapis');
|
|
6738
|
+
* const vmmigration = google.vmmigration('v1');
|
|
6739
|
+
*
|
|
6740
|
+
* async function main() {
|
|
6741
|
+
* const auth = new google.auth.GoogleAuth({
|
|
6742
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
6743
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
6744
|
+
* });
|
|
6745
|
+
*
|
|
6746
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
6747
|
+
* const authClient = await auth.getClient();
|
|
6748
|
+
* google.options({auth: authClient});
|
|
6749
|
+
*
|
|
6750
|
+
* // Do the magic
|
|
6751
|
+
* const res = await vmmigration.projects.locations.sources.patch({
|
|
6752
|
+
* // Output only. The Source name.
|
|
6753
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source',
|
|
6754
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
6755
|
+
* requestId: 'placeholder-value',
|
|
6756
|
+
* // Field mask is used to specify the fields to be overwritten in the Source resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
|
|
6757
|
+
* updateMask: 'placeholder-value',
|
|
6758
|
+
*
|
|
6759
|
+
* // Request body metadata
|
|
6760
|
+
* requestBody: {
|
|
6761
|
+
* // request body parameters
|
|
6762
|
+
* // {
|
|
6763
|
+
* // "aws": {},
|
|
6764
|
+
* // "azure": {},
|
|
6765
|
+
* // "createTime": "my_createTime",
|
|
6766
|
+
* // "description": "my_description",
|
|
6767
|
+
* // "encryption": {},
|
|
6768
|
+
* // "labels": {},
|
|
6769
|
+
* // "name": "my_name",
|
|
6770
|
+
* // "updateTime": "my_updateTime",
|
|
6771
|
+
* // "vmware": {}
|
|
6772
|
+
* // }
|
|
6773
|
+
* },
|
|
6774
|
+
* });
|
|
6775
|
+
* console.log(res.data);
|
|
6776
|
+
*
|
|
6777
|
+
* // Example response
|
|
6778
|
+
* // {
|
|
6779
|
+
* // "done": false,
|
|
6780
|
+
* // "error": {},
|
|
6781
|
+
* // "metadata": {},
|
|
6782
|
+
* // "name": "my_name",
|
|
6783
|
+
* // "response": {}
|
|
6784
|
+
* // }
|
|
6785
|
+
* }
|
|
6786
|
+
*
|
|
6787
|
+
* main().catch(e => {
|
|
6788
|
+
* console.error(e);
|
|
6789
|
+
* throw e;
|
|
6790
|
+
* });
|
|
6791
|
+
*
|
|
6792
|
+
* ```
|
|
5291
6793
|
*
|
|
5292
6794
|
* @param params - Parameters for request
|
|
5293
6795
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5484,6 +6986,82 @@ export namespace vmmigration_v1 {
|
|
|
5484
6986
|
|
|
5485
6987
|
/**
|
|
5486
6988
|
* Creates a new DatacenterConnector in a given Source.
|
|
6989
|
+
* @example
|
|
6990
|
+
* ```js
|
|
6991
|
+
* // Before running the sample:
|
|
6992
|
+
* // - Enable the API at:
|
|
6993
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
6994
|
+
* // - Login into gcloud by running:
|
|
6995
|
+
* // ```sh
|
|
6996
|
+
* // $ gcloud auth application-default login
|
|
6997
|
+
* // ```
|
|
6998
|
+
* // - Install the npm module by running:
|
|
6999
|
+
* // ```sh
|
|
7000
|
+
* // $ npm install googleapis
|
|
7001
|
+
* // ```
|
|
7002
|
+
*
|
|
7003
|
+
* const {google} = require('googleapis');
|
|
7004
|
+
* const vmmigration = google.vmmigration('v1');
|
|
7005
|
+
*
|
|
7006
|
+
* async function main() {
|
|
7007
|
+
* const auth = new google.auth.GoogleAuth({
|
|
7008
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
7009
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
7010
|
+
* });
|
|
7011
|
+
*
|
|
7012
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
7013
|
+
* const authClient = await auth.getClient();
|
|
7014
|
+
* google.options({auth: authClient});
|
|
7015
|
+
*
|
|
7016
|
+
* // Do the magic
|
|
7017
|
+
* const res =
|
|
7018
|
+
* await vmmigration.projects.locations.sources.datacenterConnectors.create({
|
|
7019
|
+
* // Required. The datacenterConnector identifier.
|
|
7020
|
+
* datacenterConnectorId: 'placeholder-value',
|
|
7021
|
+
* // Required. The DatacenterConnector's parent. Required. The Source in where the new DatacenterConnector will be created. For example: `projects/my-project/locations/us-central1/sources/my-source`
|
|
7022
|
+
* parent: 'projects/my-project/locations/my-location/sources/my-source',
|
|
7023
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
7024
|
+
* requestId: 'placeholder-value',
|
|
7025
|
+
*
|
|
7026
|
+
* // Request body metadata
|
|
7027
|
+
* requestBody: {
|
|
7028
|
+
* // request body parameters
|
|
7029
|
+
* // {
|
|
7030
|
+
* // "applianceInfrastructureVersion": "my_applianceInfrastructureVersion",
|
|
7031
|
+
* // "applianceSoftwareVersion": "my_applianceSoftwareVersion",
|
|
7032
|
+
* // "availableVersions": {},
|
|
7033
|
+
* // "bucket": "my_bucket",
|
|
7034
|
+
* // "createTime": "my_createTime",
|
|
7035
|
+
* // "error": {},
|
|
7036
|
+
* // "name": "my_name",
|
|
7037
|
+
* // "registrationId": "my_registrationId",
|
|
7038
|
+
* // "serviceAccount": "my_serviceAccount",
|
|
7039
|
+
* // "state": "my_state",
|
|
7040
|
+
* // "stateTime": "my_stateTime",
|
|
7041
|
+
* // "updateTime": "my_updateTime",
|
|
7042
|
+
* // "upgradeStatus": {},
|
|
7043
|
+
* // "version": "my_version"
|
|
7044
|
+
* // }
|
|
7045
|
+
* },
|
|
7046
|
+
* });
|
|
7047
|
+
* console.log(res.data);
|
|
7048
|
+
*
|
|
7049
|
+
* // Example response
|
|
7050
|
+
* // {
|
|
7051
|
+
* // "done": false,
|
|
7052
|
+
* // "error": {},
|
|
7053
|
+
* // "metadata": {},
|
|
7054
|
+
* // "name": "my_name",
|
|
7055
|
+
* // "response": {}
|
|
7056
|
+
* // }
|
|
7057
|
+
* }
|
|
7058
|
+
*
|
|
7059
|
+
* main().catch(e => {
|
|
7060
|
+
* console.error(e);
|
|
7061
|
+
* throw e;
|
|
7062
|
+
* });
|
|
7063
|
+
*
|
|
7064
|
+
* ```
|
|
5487
7065
|
*
|
|
5488
7066
|
* @param params - Parameters for request
|
|
5489
7067
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5576,6 +7154,59 @@ export namespace vmmigration_v1 {
|
|
|
5576
7154
|
|
|
5577
7155
|
/**
|
|
5578
7156
|
* Deletes a single DatacenterConnector.
|
|
7157
|
+
* @example
|
|
7158
|
+
* ```js
|
|
7159
|
+
* // Before running the sample:
|
|
7160
|
+
* // - Enable the API at:
|
|
7161
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
7162
|
+
* // - Login into gcloud by running:
|
|
7163
|
+
* // ```sh
|
|
7164
|
+
* // $ gcloud auth application-default login
|
|
7165
|
+
* // ```
|
|
7166
|
+
* // - Install the npm module by running:
|
|
7167
|
+
* // ```sh
|
|
7168
|
+
* // $ npm install googleapis
|
|
7169
|
+
* // ```
|
|
7170
|
+
*
|
|
7171
|
+
* const {google} = require('googleapis');
|
|
7172
|
+
* const vmmigration = google.vmmigration('v1');
|
|
7173
|
+
*
|
|
7174
|
+
* async function main() {
|
|
7175
|
+
* const auth = new google.auth.GoogleAuth({
|
|
7176
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
7177
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
7178
|
+
* });
|
|
7179
|
+
*
|
|
7180
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
7181
|
+
* const authClient = await auth.getClient();
|
|
7182
|
+
* google.options({auth: authClient});
|
|
7183
|
+
*
|
|
7184
|
+
* // Do the magic
|
|
7185
|
+
* const res =
|
|
7186
|
+
* await vmmigration.projects.locations.sources.datacenterConnectors.delete({
|
|
7187
|
+
* // Required. The DatacenterConnector name.
|
|
7188
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/datacenterConnectors/my-datacenterConnector',
|
|
7189
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
7190
|
+
* requestId: 'placeholder-value',
|
|
7191
|
+
* });
|
|
7192
|
+
* console.log(res.data);
|
|
7193
|
+
*
|
|
7194
|
+
* // Example response
|
|
7195
|
+
* // {
|
|
7196
|
+
* // "done": false,
|
|
7197
|
+
* // "error": {},
|
|
7198
|
+
* // "metadata": {},
|
|
7199
|
+
* // "name": "my_name",
|
|
7200
|
+
* // "response": {}
|
|
7201
|
+
* // }
|
|
7202
|
+
* }
|
|
7203
|
+
*
|
|
7204
|
+
* main().catch(e => {
|
|
7205
|
+
* console.error(e);
|
|
7206
|
+
* throw e;
|
|
7207
|
+
* });
|
|
7208
|
+
*
|
|
7209
|
+
* ```
|
|
5579
7210
|
*
|
|
5580
7211
|
* @param params - Parameters for request
|
|
5581
7212
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5665,6 +7296,66 @@ export namespace vmmigration_v1 {
|
|
|
5665
7296
|
|
|
5666
7297
|
/**
|
|
5667
7298
|
* Gets details of a single DatacenterConnector.
|
|
7299
|
+
* @example
|
|
7300
|
+
* ```js
|
|
7301
|
+
* // Before running the sample:
|
|
7302
|
+
* // - Enable the API at:
|
|
7303
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
7304
|
+
* // - Login into gcloud by running:
|
|
7305
|
+
* // ```sh
|
|
7306
|
+
* // $ gcloud auth application-default login
|
|
7307
|
+
* // ```
|
|
7308
|
+
* // - Install the npm module by running:
|
|
7309
|
+
* // ```sh
|
|
7310
|
+
* // $ npm install googleapis
|
|
7311
|
+
* // ```
|
|
7312
|
+
*
|
|
7313
|
+
* const {google} = require('googleapis');
|
|
7314
|
+
* const vmmigration = google.vmmigration('v1');
|
|
7315
|
+
*
|
|
7316
|
+
* async function main() {
|
|
7317
|
+
* const auth = new google.auth.GoogleAuth({
|
|
7318
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
7319
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
7320
|
+
* });
|
|
7321
|
+
*
|
|
7322
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
7323
|
+
* const authClient = await auth.getClient();
|
|
7324
|
+
* google.options({auth: authClient});
|
|
7325
|
+
*
|
|
7326
|
+
* // Do the magic
|
|
7327
|
+
* const res =
|
|
7328
|
+
* await vmmigration.projects.locations.sources.datacenterConnectors.get({
|
|
7329
|
+
* // Required. The name of the DatacenterConnector.
|
|
7330
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/datacenterConnectors/my-datacenterConnector',
|
|
7331
|
+
* });
|
|
7332
|
+
* console.log(res.data);
|
|
7333
|
+
*
|
|
7334
|
+
* // Example response
|
|
7335
|
+
* // {
|
|
7336
|
+
* // "applianceInfrastructureVersion": "my_applianceInfrastructureVersion",
|
|
7337
|
+
* // "applianceSoftwareVersion": "my_applianceSoftwareVersion",
|
|
7338
|
+
* // "availableVersions": {},
|
|
7339
|
+
* // "bucket": "my_bucket",
|
|
7340
|
+
* // "createTime": "my_createTime",
|
|
7341
|
+
* // "error": {},
|
|
7342
|
+
* // "name": "my_name",
|
|
7343
|
+
* // "registrationId": "my_registrationId",
|
|
7344
|
+
* // "serviceAccount": "my_serviceAccount",
|
|
7345
|
+
* // "state": "my_state",
|
|
7346
|
+
* // "stateTime": "my_stateTime",
|
|
7347
|
+
* // "updateTime": "my_updateTime",
|
|
7348
|
+
* // "upgradeStatus": {},
|
|
7349
|
+
* // "version": "my_version"
|
|
7350
|
+
* // }
|
|
7351
|
+
* }
|
|
7352
|
+
*
|
|
7353
|
+
* main().catch(e => {
|
|
7354
|
+
* console.error(e);
|
|
7355
|
+
* throw e;
|
|
7356
|
+
* });
|
|
7357
|
+
*
|
|
7358
|
+
* ```
|
|
5668
7359
|
*
|
|
5669
7360
|
* @param params - Parameters for request
|
|
5670
7361
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5754,6 +7445,63 @@ export namespace vmmigration_v1 {
|
|
|
5754
7445
|
|
|
5755
7446
|
/**
|
|
5756
7447
|
* Lists DatacenterConnectors in a given Source.
|
|
7448
|
+
* @example
|
|
7449
|
+
* ```js
|
|
7450
|
+
* // Before running the sample:
|
|
7451
|
+
* // - Enable the API at:
|
|
7452
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
7453
|
+
* // - Login into gcloud by running:
|
|
7454
|
+
* // ```sh
|
|
7455
|
+
* // $ gcloud auth application-default login
|
|
7456
|
+
* // ```
|
|
7457
|
+
* // - Install the npm module by running:
|
|
7458
|
+
* // ```sh
|
|
7459
|
+
* // $ npm install googleapis
|
|
7460
|
+
* // ```
|
|
7461
|
+
*
|
|
7462
|
+
* const {google} = require('googleapis');
|
|
7463
|
+
* const vmmigration = google.vmmigration('v1');
|
|
7464
|
+
*
|
|
7465
|
+
* async function main() {
|
|
7466
|
+
* const auth = new google.auth.GoogleAuth({
|
|
7467
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
7468
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
7469
|
+
* });
|
|
7470
|
+
*
|
|
7471
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
7472
|
+
* const authClient = await auth.getClient();
|
|
7473
|
+
* google.options({auth: authClient});
|
|
7474
|
+
*
|
|
7475
|
+
* // Do the magic
|
|
7476
|
+
* const res =
|
|
7477
|
+
* await vmmigration.projects.locations.sources.datacenterConnectors.list({
|
|
7478
|
+
* // Optional. The filter request.
|
|
7479
|
+
* filter: 'placeholder-value',
|
|
7480
|
+
* // Optional. the order by fields for the result.
|
|
7481
|
+
* orderBy: 'placeholder-value',
|
|
7482
|
+
* // Optional. The maximum number of connectors to return. The service may return fewer than this value. If unspecified, at most 500 sources will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
7483
|
+
* pageSize: 'placeholder-value',
|
|
7484
|
+
* // Required. A page token, received from a previous `ListDatacenterConnectors` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListDatacenterConnectors` must match the call that provided the page token.
|
|
7485
|
+
* pageToken: 'placeholder-value',
|
|
7486
|
+
* // Required. The parent, which owns this collection of connectors.
|
|
7487
|
+
* parent: 'projects/my-project/locations/my-location/sources/my-source',
|
|
7488
|
+
* });
|
|
7489
|
+
* console.log(res.data);
|
|
7490
|
+
*
|
|
7491
|
+
* // Example response
|
|
7492
|
+
* // {
|
|
7493
|
+
* // "datacenterConnectors": [],
|
|
7494
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
7495
|
+
* // "unreachable": []
|
|
7496
|
+
* // }
|
|
7497
|
+
* }
|
|
7498
|
+
*
|
|
7499
|
+
* main().catch(e => {
|
|
7500
|
+
* console.error(e);
|
|
7501
|
+
* throw e;
|
|
7502
|
+
* });
|
|
7503
|
+
*
|
|
7504
|
+
* ```
|
|
5757
7505
|
*
|
|
5758
7506
|
* @param params - Parameters for request
|
|
5759
7507
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -5856,6 +7604,68 @@ export namespace vmmigration_v1 {
|
|
|
5856
7604
|
|
|
5857
7605
|
/**
|
|
5858
7606
|
* Upgrades the appliance relate to this DatacenterConnector to the in-place updateable version.
|
|
7607
|
+
* @example
|
|
7608
|
+
* ```js
|
|
7609
|
+
* // Before running the sample:
|
|
7610
|
+
* // - Enable the API at:
|
|
7611
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
7612
|
+
* // - Login into gcloud by running:
|
|
7613
|
+
* // ```sh
|
|
7614
|
+
* // $ gcloud auth application-default login
|
|
7615
|
+
* // ```
|
|
7616
|
+
* // - Install the npm module by running:
|
|
7617
|
+
* // ```sh
|
|
7618
|
+
* // $ npm install googleapis
|
|
7619
|
+
* // ```
|
|
7620
|
+
*
|
|
7621
|
+
* const {google} = require('googleapis');
|
|
7622
|
+
* const vmmigration = google.vmmigration('v1');
|
|
7623
|
+
*
|
|
7624
|
+
* async function main() {
|
|
7625
|
+
* const auth = new google.auth.GoogleAuth({
|
|
7626
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
7627
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
7628
|
+
* });
|
|
7629
|
+
*
|
|
7630
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
7631
|
+
* const authClient = await auth.getClient();
|
|
7632
|
+
* google.options({auth: authClient});
|
|
7633
|
+
*
|
|
7634
|
+
* // Do the magic
|
|
7635
|
+
* const res =
|
|
7636
|
+
* await vmmigration.projects.locations.sources.datacenterConnectors.upgradeAppliance(
|
|
7637
|
+
* {
|
|
7638
|
+
* // Required. The DatacenterConnector name.
|
|
7639
|
+
* datacenterConnector:
|
|
7640
|
+
* 'projects/my-project/locations/my-location/sources/my-source/datacenterConnectors/my-datacenterConnector',
|
|
7641
|
+
*
|
|
7642
|
+
* // Request body metadata
|
|
7643
|
+
* requestBody: {
|
|
7644
|
+
* // request body parameters
|
|
7645
|
+
* // {
|
|
7646
|
+
* // "requestId": "my_requestId"
|
|
7647
|
+
* // }
|
|
7648
|
+
* },
|
|
7649
|
+
* },
|
|
7650
|
+
* );
|
|
7651
|
+
* console.log(res.data);
|
|
7652
|
+
*
|
|
7653
|
+
* // Example response
|
|
7654
|
+
* // {
|
|
7655
|
+
* // "done": false,
|
|
7656
|
+
* // "error": {},
|
|
7657
|
+
* // "metadata": {},
|
|
7658
|
+
* // "name": "my_name",
|
|
7659
|
+
* // "response": {}
|
|
7660
|
+
* // }
|
|
7661
|
+
* }
|
|
7662
|
+
*
|
|
7663
|
+
* main().catch(e => {
|
|
7664
|
+
* console.error(e);
|
|
7665
|
+
* throw e;
|
|
7666
|
+
* });
|
|
7667
|
+
*
|
|
7668
|
+
* ```
|
|
5859
7669
|
*
|
|
5860
7670
|
* @param params - Parameters for request
|
|
5861
7671
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6043,6 +7853,91 @@ export namespace vmmigration_v1 {
|
|
|
6043
7853
|
|
|
6044
7854
|
/**
|
|
6045
7855
|
* Creates a new MigratingVm in a given Source.
|
|
7856
|
+
* @example
|
|
7857
|
+
* ```js
|
|
7858
|
+
* // Before running the sample:
|
|
7859
|
+
* // - Enable the API at:
|
|
7860
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
7861
|
+
* // - Login into gcloud by running:
|
|
7862
|
+
* // ```sh
|
|
7863
|
+
* // $ gcloud auth application-default login
|
|
7864
|
+
* // ```
|
|
7865
|
+
* // - Install the npm module by running:
|
|
7866
|
+
* // ```sh
|
|
7867
|
+
* // $ npm install googleapis
|
|
7868
|
+
* // ```
|
|
7869
|
+
*
|
|
7870
|
+
* const {google} = require('googleapis');
|
|
7871
|
+
* const vmmigration = google.vmmigration('v1');
|
|
7872
|
+
*
|
|
7873
|
+
* async function main() {
|
|
7874
|
+
* const auth = new google.auth.GoogleAuth({
|
|
7875
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
7876
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
7877
|
+
* });
|
|
7878
|
+
*
|
|
7879
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
7880
|
+
* const authClient = await auth.getClient();
|
|
7881
|
+
* google.options({auth: authClient});
|
|
7882
|
+
*
|
|
7883
|
+
* // Do the magic
|
|
7884
|
+
* const res = await vmmigration.projects.locations.sources.migratingVms.create({
|
|
7885
|
+
* // Required. The migratingVm identifier.
|
|
7886
|
+
* migratingVmId: 'placeholder-value',
|
|
7887
|
+
* // Required. The MigratingVm's parent.
|
|
7888
|
+
* parent: 'projects/my-project/locations/my-location/sources/my-source',
|
|
7889
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
7890
|
+
* requestId: 'placeholder-value',
|
|
7891
|
+
*
|
|
7892
|
+
* // Request body metadata
|
|
7893
|
+
* requestBody: {
|
|
7894
|
+
* // request body parameters
|
|
7895
|
+
* // {
|
|
7896
|
+
* // "awsSourceVmDetails": {},
|
|
7897
|
+
* // "azureSourceVmDetails": {},
|
|
7898
|
+
* // "computeEngineDisksTargetDefaults": {},
|
|
7899
|
+
* // "computeEngineTargetDefaults": {},
|
|
7900
|
+
* // "createTime": "my_createTime",
|
|
7901
|
+
* // "currentSyncInfo": {},
|
|
7902
|
+
* // "cutoverForecast": {},
|
|
7903
|
+
* // "description": "my_description",
|
|
7904
|
+
* // "displayName": "my_displayName",
|
|
7905
|
+
* // "error": {},
|
|
7906
|
+
* // "expiration": {},
|
|
7907
|
+
* // "group": "my_group",
|
|
7908
|
+
* // "labels": {},
|
|
7909
|
+
* // "lastReplicationCycle": {},
|
|
7910
|
+
* // "lastSync": {},
|
|
7911
|
+
* // "name": "my_name",
|
|
7912
|
+
* // "policy": {},
|
|
7913
|
+
* // "recentCloneJobs": [],
|
|
7914
|
+
* // "recentCutoverJobs": [],
|
|
7915
|
+
* // "sourceVmId": "my_sourceVmId",
|
|
7916
|
+
* // "state": "my_state",
|
|
7917
|
+
* // "stateTime": "my_stateTime",
|
|
7918
|
+
* // "updateTime": "my_updateTime",
|
|
7919
|
+
* // "vmwareSourceVmDetails": {}
|
|
7920
|
+
* // }
|
|
7921
|
+
* },
|
|
7922
|
+
* });
|
|
7923
|
+
* console.log(res.data);
|
|
7924
|
+
*
|
|
7925
|
+
* // Example response
|
|
7926
|
+
* // {
|
|
7927
|
+
* // "done": false,
|
|
7928
|
+
* // "error": {},
|
|
7929
|
+
* // "metadata": {},
|
|
7930
|
+
* // "name": "my_name",
|
|
7931
|
+
* // "response": {}
|
|
7932
|
+
* // }
|
|
7933
|
+
* }
|
|
7934
|
+
*
|
|
7935
|
+
* main().catch(e => {
|
|
7936
|
+
* console.error(e);
|
|
7937
|
+
* throw e;
|
|
7938
|
+
* });
|
|
7939
|
+
*
|
|
7940
|
+
* ```
|
|
6046
7941
|
*
|
|
6047
7942
|
* @param params - Parameters for request
|
|
6048
7943
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6135,10 +8030,60 @@ export namespace vmmigration_v1 {
|
|
|
6135
8030
|
|
|
6136
8031
|
/**
|
|
6137
8032
|
* Deletes a single MigratingVm.
|
|
8033
|
+
* @example
|
|
8034
|
+
* ```js
|
|
8035
|
+
* // Before running the sample:
|
|
8036
|
+
* // - Enable the API at:
|
|
8037
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
8038
|
+
* // - Login into gcloud by running:
|
|
8039
|
+
* // ```sh
|
|
8040
|
+
* // $ gcloud auth application-default login
|
|
8041
|
+
* // ```
|
|
8042
|
+
* // - Install the npm module by running:
|
|
8043
|
+
* // ```sh
|
|
8044
|
+
* // $ npm install googleapis
|
|
8045
|
+
* // ```
|
|
6138
8046
|
*
|
|
6139
|
-
*
|
|
6140
|
-
*
|
|
6141
|
-
*
|
|
8047
|
+
* const {google} = require('googleapis');
|
|
8048
|
+
* const vmmigration = google.vmmigration('v1');
|
|
8049
|
+
*
|
|
8050
|
+
* async function main() {
|
|
8051
|
+
* const auth = new google.auth.GoogleAuth({
|
|
8052
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
8053
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
8054
|
+
* });
|
|
8055
|
+
*
|
|
8056
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
8057
|
+
* const authClient = await auth.getClient();
|
|
8058
|
+
* google.options({auth: authClient});
|
|
8059
|
+
*
|
|
8060
|
+
* // Do the magic
|
|
8061
|
+
* const res = await vmmigration.projects.locations.sources.migratingVms.delete({
|
|
8062
|
+
* // Required. The name of the MigratingVm.
|
|
8063
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
8064
|
+
* });
|
|
8065
|
+
* console.log(res.data);
|
|
8066
|
+
*
|
|
8067
|
+
* // Example response
|
|
8068
|
+
* // {
|
|
8069
|
+
* // "done": false,
|
|
8070
|
+
* // "error": {},
|
|
8071
|
+
* // "metadata": {},
|
|
8072
|
+
* // "name": "my_name",
|
|
8073
|
+
* // "response": {}
|
|
8074
|
+
* // }
|
|
8075
|
+
* }
|
|
8076
|
+
*
|
|
8077
|
+
* main().catch(e => {
|
|
8078
|
+
* console.error(e);
|
|
8079
|
+
* throw e;
|
|
8080
|
+
* });
|
|
8081
|
+
*
|
|
8082
|
+
* ```
|
|
8083
|
+
*
|
|
8084
|
+
* @param params - Parameters for request
|
|
8085
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
8086
|
+
* @param callback - Optional callback that handles the response.
|
|
6142
8087
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
6143
8088
|
*/
|
|
6144
8089
|
delete(
|
|
@@ -6222,8 +8167,218 @@ export namespace vmmigration_v1 {
|
|
|
6222
8167
|
}
|
|
6223
8168
|
}
|
|
6224
8169
|
|
|
8170
|
+
/**
|
|
8171
|
+
* Extend the migrating VM time to live.
|
|
8172
|
+
* @example
|
|
8173
|
+
* ```js
|
|
8174
|
+
* // Before running the sample:
|
|
8175
|
+
* // - Enable the API at:
|
|
8176
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
8177
|
+
* // - Login into gcloud by running:
|
|
8178
|
+
* // ```sh
|
|
8179
|
+
* // $ gcloud auth application-default login
|
|
8180
|
+
* // ```
|
|
8181
|
+
* // - Install the npm module by running:
|
|
8182
|
+
* // ```sh
|
|
8183
|
+
* // $ npm install googleapis
|
|
8184
|
+
* // ```
|
|
8185
|
+
*
|
|
8186
|
+
* const {google} = require('googleapis');
|
|
8187
|
+
* const vmmigration = google.vmmigration('v1');
|
|
8188
|
+
*
|
|
8189
|
+
* async function main() {
|
|
8190
|
+
* const auth = new google.auth.GoogleAuth({
|
|
8191
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
8192
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
8193
|
+
* });
|
|
8194
|
+
*
|
|
8195
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
8196
|
+
* const authClient = await auth.getClient();
|
|
8197
|
+
* google.options({auth: authClient});
|
|
8198
|
+
*
|
|
8199
|
+
* // Do the magic
|
|
8200
|
+
* const res =
|
|
8201
|
+
* await vmmigration.projects.locations.sources.migratingVms.extendMigration({
|
|
8202
|
+
* // Required. The name of the MigratingVm.
|
|
8203
|
+
* migratingVm:
|
|
8204
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
8205
|
+
*
|
|
8206
|
+
* // Request body metadata
|
|
8207
|
+
* requestBody: {
|
|
8208
|
+
* // request body parameters
|
|
8209
|
+
* // {}
|
|
8210
|
+
* },
|
|
8211
|
+
* });
|
|
8212
|
+
* console.log(res.data);
|
|
8213
|
+
*
|
|
8214
|
+
* // Example response
|
|
8215
|
+
* // {
|
|
8216
|
+
* // "done": false,
|
|
8217
|
+
* // "error": {},
|
|
8218
|
+
* // "metadata": {},
|
|
8219
|
+
* // "name": "my_name",
|
|
8220
|
+
* // "response": {}
|
|
8221
|
+
* // }
|
|
8222
|
+
* }
|
|
8223
|
+
*
|
|
8224
|
+
* main().catch(e => {
|
|
8225
|
+
* console.error(e);
|
|
8226
|
+
* throw e;
|
|
8227
|
+
* });
|
|
8228
|
+
*
|
|
8229
|
+
* ```
|
|
8230
|
+
*
|
|
8231
|
+
* @param params - Parameters for request
|
|
8232
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
8233
|
+
* @param callback - Optional callback that handles the response.
|
|
8234
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
8235
|
+
*/
|
|
8236
|
+
extendMigration(
|
|
8237
|
+
params: Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration,
|
|
8238
|
+
options: StreamMethodOptions
|
|
8239
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
8240
|
+
extendMigration(
|
|
8241
|
+
params?: Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration,
|
|
8242
|
+
options?: MethodOptions
|
|
8243
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$Operation>>;
|
|
8244
|
+
extendMigration(
|
|
8245
|
+
params: Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration,
|
|
8246
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
8247
|
+
callback: BodyResponseCallback<Readable>
|
|
8248
|
+
): void;
|
|
8249
|
+
extendMigration(
|
|
8250
|
+
params: Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration,
|
|
8251
|
+
options: MethodOptions | BodyResponseCallback<Schema$Operation>,
|
|
8252
|
+
callback: BodyResponseCallback<Schema$Operation>
|
|
8253
|
+
): void;
|
|
8254
|
+
extendMigration(
|
|
8255
|
+
params: Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration,
|
|
8256
|
+
callback: BodyResponseCallback<Schema$Operation>
|
|
8257
|
+
): void;
|
|
8258
|
+
extendMigration(callback: BodyResponseCallback<Schema$Operation>): void;
|
|
8259
|
+
extendMigration(
|
|
8260
|
+
paramsOrCallback?:
|
|
8261
|
+
| Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration
|
|
8262
|
+
| BodyResponseCallback<Schema$Operation>
|
|
8263
|
+
| BodyResponseCallback<Readable>,
|
|
8264
|
+
optionsOrCallback?:
|
|
8265
|
+
| MethodOptions
|
|
8266
|
+
| StreamMethodOptions
|
|
8267
|
+
| BodyResponseCallback<Schema$Operation>
|
|
8268
|
+
| BodyResponseCallback<Readable>,
|
|
8269
|
+
callback?:
|
|
8270
|
+
| BodyResponseCallback<Schema$Operation>
|
|
8271
|
+
| BodyResponseCallback<Readable>
|
|
8272
|
+
):
|
|
8273
|
+
| void
|
|
8274
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$Operation>>
|
|
8275
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
8276
|
+
let params = (paramsOrCallback ||
|
|
8277
|
+
{}) as Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration;
|
|
8278
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
8279
|
+
|
|
8280
|
+
if (typeof paramsOrCallback === 'function') {
|
|
8281
|
+
callback = paramsOrCallback;
|
|
8282
|
+
params =
|
|
8283
|
+
{} as Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration;
|
|
8284
|
+
options = {};
|
|
8285
|
+
}
|
|
8286
|
+
|
|
8287
|
+
if (typeof optionsOrCallback === 'function') {
|
|
8288
|
+
callback = optionsOrCallback;
|
|
8289
|
+
options = {};
|
|
8290
|
+
}
|
|
8291
|
+
|
|
8292
|
+
const rootUrl = options.rootUrl || 'https://vmmigration.googleapis.com/';
|
|
8293
|
+
const parameters = {
|
|
8294
|
+
options: Object.assign(
|
|
8295
|
+
{
|
|
8296
|
+
url: (rootUrl + '/v1/{+migratingVm}:extendMigration').replace(
|
|
8297
|
+
/([^:]\/)\/+/g,
|
|
8298
|
+
'$1'
|
|
8299
|
+
),
|
|
8300
|
+
method: 'POST',
|
|
8301
|
+
apiVersion: '',
|
|
8302
|
+
},
|
|
8303
|
+
options
|
|
8304
|
+
),
|
|
8305
|
+
params,
|
|
8306
|
+
requiredParams: ['migratingVm'],
|
|
8307
|
+
pathParams: ['migratingVm'],
|
|
8308
|
+
context: this.context,
|
|
8309
|
+
};
|
|
8310
|
+
if (callback) {
|
|
8311
|
+
createAPIRequest<Schema$Operation>(
|
|
8312
|
+
parameters,
|
|
8313
|
+
callback as BodyResponseCallback<unknown>
|
|
8314
|
+
);
|
|
8315
|
+
} else {
|
|
8316
|
+
return createAPIRequest<Schema$Operation>(parameters);
|
|
8317
|
+
}
|
|
8318
|
+
}
|
|
8319
|
+
|
|
6225
8320
|
/**
|
|
6226
8321
|
* Marks a migration as completed, deleting migration resources that are no longer being used. Only applicable after cutover is done.
|
|
8322
|
+
* @example
|
|
8323
|
+
* ```js
|
|
8324
|
+
* // Before running the sample:
|
|
8325
|
+
* // - Enable the API at:
|
|
8326
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
8327
|
+
* // - Login into gcloud by running:
|
|
8328
|
+
* // ```sh
|
|
8329
|
+
* // $ gcloud auth application-default login
|
|
8330
|
+
* // ```
|
|
8331
|
+
* // - Install the npm module by running:
|
|
8332
|
+
* // ```sh
|
|
8333
|
+
* // $ npm install googleapis
|
|
8334
|
+
* // ```
|
|
8335
|
+
*
|
|
8336
|
+
* const {google} = require('googleapis');
|
|
8337
|
+
* const vmmigration = google.vmmigration('v1');
|
|
8338
|
+
*
|
|
8339
|
+
* async function main() {
|
|
8340
|
+
* const auth = new google.auth.GoogleAuth({
|
|
8341
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
8342
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
8343
|
+
* });
|
|
8344
|
+
*
|
|
8345
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
8346
|
+
* const authClient = await auth.getClient();
|
|
8347
|
+
* google.options({auth: authClient});
|
|
8348
|
+
*
|
|
8349
|
+
* // Do the magic
|
|
8350
|
+
* const res =
|
|
8351
|
+
* await vmmigration.projects.locations.sources.migratingVms.finalizeMigration(
|
|
8352
|
+
* {
|
|
8353
|
+
* // Required. The name of the MigratingVm.
|
|
8354
|
+
* migratingVm:
|
|
8355
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
8356
|
+
*
|
|
8357
|
+
* // Request body metadata
|
|
8358
|
+
* requestBody: {
|
|
8359
|
+
* // request body parameters
|
|
8360
|
+
* // {}
|
|
8361
|
+
* },
|
|
8362
|
+
* },
|
|
8363
|
+
* );
|
|
8364
|
+
* console.log(res.data);
|
|
8365
|
+
*
|
|
8366
|
+
* // Example response
|
|
8367
|
+
* // {
|
|
8368
|
+
* // "done": false,
|
|
8369
|
+
* // "error": {},
|
|
8370
|
+
* // "metadata": {},
|
|
8371
|
+
* // "name": "my_name",
|
|
8372
|
+
* // "response": {}
|
|
8373
|
+
* // }
|
|
8374
|
+
* }
|
|
8375
|
+
*
|
|
8376
|
+
* main().catch(e => {
|
|
8377
|
+
* console.error(e);
|
|
8378
|
+
* throw e;
|
|
8379
|
+
* });
|
|
8380
|
+
*
|
|
8381
|
+
* ```
|
|
6227
8382
|
*
|
|
6228
8383
|
* @param params - Parameters for request
|
|
6229
8384
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6316,6 +8471,77 @@ export namespace vmmigration_v1 {
|
|
|
6316
8471
|
|
|
6317
8472
|
/**
|
|
6318
8473
|
* Gets details of a single MigratingVm.
|
|
8474
|
+
* @example
|
|
8475
|
+
* ```js
|
|
8476
|
+
* // Before running the sample:
|
|
8477
|
+
* // - Enable the API at:
|
|
8478
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
8479
|
+
* // - Login into gcloud by running:
|
|
8480
|
+
* // ```sh
|
|
8481
|
+
* // $ gcloud auth application-default login
|
|
8482
|
+
* // ```
|
|
8483
|
+
* // - Install the npm module by running:
|
|
8484
|
+
* // ```sh
|
|
8485
|
+
* // $ npm install googleapis
|
|
8486
|
+
* // ```
|
|
8487
|
+
*
|
|
8488
|
+
* const {google} = require('googleapis');
|
|
8489
|
+
* const vmmigration = google.vmmigration('v1');
|
|
8490
|
+
*
|
|
8491
|
+
* async function main() {
|
|
8492
|
+
* const auth = new google.auth.GoogleAuth({
|
|
8493
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
8494
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
8495
|
+
* });
|
|
8496
|
+
*
|
|
8497
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
8498
|
+
* const authClient = await auth.getClient();
|
|
8499
|
+
* google.options({auth: authClient});
|
|
8500
|
+
*
|
|
8501
|
+
* // Do the magic
|
|
8502
|
+
* const res = await vmmigration.projects.locations.sources.migratingVms.get({
|
|
8503
|
+
* // Required. The name of the MigratingVm.
|
|
8504
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
8505
|
+
* // Optional. The level of details of the migrating VM.
|
|
8506
|
+
* view: 'placeholder-value',
|
|
8507
|
+
* });
|
|
8508
|
+
* console.log(res.data);
|
|
8509
|
+
*
|
|
8510
|
+
* // Example response
|
|
8511
|
+
* // {
|
|
8512
|
+
* // "awsSourceVmDetails": {},
|
|
8513
|
+
* // "azureSourceVmDetails": {},
|
|
8514
|
+
* // "computeEngineDisksTargetDefaults": {},
|
|
8515
|
+
* // "computeEngineTargetDefaults": {},
|
|
8516
|
+
* // "createTime": "my_createTime",
|
|
8517
|
+
* // "currentSyncInfo": {},
|
|
8518
|
+
* // "cutoverForecast": {},
|
|
8519
|
+
* // "description": "my_description",
|
|
8520
|
+
* // "displayName": "my_displayName",
|
|
8521
|
+
* // "error": {},
|
|
8522
|
+
* // "expiration": {},
|
|
8523
|
+
* // "group": "my_group",
|
|
8524
|
+
* // "labels": {},
|
|
8525
|
+
* // "lastReplicationCycle": {},
|
|
8526
|
+
* // "lastSync": {},
|
|
8527
|
+
* // "name": "my_name",
|
|
8528
|
+
* // "policy": {},
|
|
8529
|
+
* // "recentCloneJobs": [],
|
|
8530
|
+
* // "recentCutoverJobs": [],
|
|
8531
|
+
* // "sourceVmId": "my_sourceVmId",
|
|
8532
|
+
* // "state": "my_state",
|
|
8533
|
+
* // "stateTime": "my_stateTime",
|
|
8534
|
+
* // "updateTime": "my_updateTime",
|
|
8535
|
+
* // "vmwareSourceVmDetails": {}
|
|
8536
|
+
* // }
|
|
8537
|
+
* }
|
|
8538
|
+
*
|
|
8539
|
+
* main().catch(e => {
|
|
8540
|
+
* console.error(e);
|
|
8541
|
+
* throw e;
|
|
8542
|
+
* });
|
|
8543
|
+
*
|
|
8544
|
+
* ```
|
|
6319
8545
|
*
|
|
6320
8546
|
* @param params - Parameters for request
|
|
6321
8547
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6405,6 +8631,64 @@ export namespace vmmigration_v1 {
|
|
|
6405
8631
|
|
|
6406
8632
|
/**
|
|
6407
8633
|
* Lists MigratingVms in a given Source.
|
|
8634
|
+
* @example
|
|
8635
|
+
* ```js
|
|
8636
|
+
* // Before running the sample:
|
|
8637
|
+
* // - Enable the API at:
|
|
8638
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
8639
|
+
* // - Login into gcloud by running:
|
|
8640
|
+
* // ```sh
|
|
8641
|
+
* // $ gcloud auth application-default login
|
|
8642
|
+
* // ```
|
|
8643
|
+
* // - Install the npm module by running:
|
|
8644
|
+
* // ```sh
|
|
8645
|
+
* // $ npm install googleapis
|
|
8646
|
+
* // ```
|
|
8647
|
+
*
|
|
8648
|
+
* const {google} = require('googleapis');
|
|
8649
|
+
* const vmmigration = google.vmmigration('v1');
|
|
8650
|
+
*
|
|
8651
|
+
* async function main() {
|
|
8652
|
+
* const auth = new google.auth.GoogleAuth({
|
|
8653
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
8654
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
8655
|
+
* });
|
|
8656
|
+
*
|
|
8657
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
8658
|
+
* const authClient = await auth.getClient();
|
|
8659
|
+
* google.options({auth: authClient});
|
|
8660
|
+
*
|
|
8661
|
+
* // Do the magic
|
|
8662
|
+
* const res = await vmmigration.projects.locations.sources.migratingVms.list({
|
|
8663
|
+
* // Optional. The filter request.
|
|
8664
|
+
* filter: 'placeholder-value',
|
|
8665
|
+
* // Optional. the order by fields for the result.
|
|
8666
|
+
* orderBy: 'placeholder-value',
|
|
8667
|
+
* // Optional. The maximum number of migrating VMs to return. The service may return fewer than this value. If unspecified, at most 500 migrating VMs will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
8668
|
+
* pageSize: 'placeholder-value',
|
|
8669
|
+
* // Required. A page token, received from a previous `ListMigratingVms` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListMigratingVms` must match the call that provided the page token.
|
|
8670
|
+
* pageToken: 'placeholder-value',
|
|
8671
|
+
* // Required. The parent, which owns this collection of MigratingVms.
|
|
8672
|
+
* parent: 'projects/my-project/locations/my-location/sources/my-source',
|
|
8673
|
+
* // Optional. The level of details of each migrating VM.
|
|
8674
|
+
* view: 'placeholder-value',
|
|
8675
|
+
* });
|
|
8676
|
+
* console.log(res.data);
|
|
8677
|
+
*
|
|
8678
|
+
* // Example response
|
|
8679
|
+
* // {
|
|
8680
|
+
* // "migratingVms": [],
|
|
8681
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
8682
|
+
* // "unreachable": []
|
|
8683
|
+
* // }
|
|
8684
|
+
* }
|
|
8685
|
+
*
|
|
8686
|
+
* main().catch(e => {
|
|
8687
|
+
* console.error(e);
|
|
8688
|
+
* throw e;
|
|
8689
|
+
* });
|
|
8690
|
+
*
|
|
8691
|
+
* ```
|
|
6408
8692
|
*
|
|
6409
8693
|
* @param params - Parameters for request
|
|
6410
8694
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6499,6 +8783,91 @@ export namespace vmmigration_v1 {
|
|
|
6499
8783
|
|
|
6500
8784
|
/**
|
|
6501
8785
|
* Updates the parameters of a single MigratingVm.
|
|
8786
|
+
* @example
|
|
8787
|
+
* ```js
|
|
8788
|
+
* // Before running the sample:
|
|
8789
|
+
* // - Enable the API at:
|
|
8790
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
8791
|
+
* // - Login into gcloud by running:
|
|
8792
|
+
* // ```sh
|
|
8793
|
+
* // $ gcloud auth application-default login
|
|
8794
|
+
* // ```
|
|
8795
|
+
* // - Install the npm module by running:
|
|
8796
|
+
* // ```sh
|
|
8797
|
+
* // $ npm install googleapis
|
|
8798
|
+
* // ```
|
|
8799
|
+
*
|
|
8800
|
+
* const {google} = require('googleapis');
|
|
8801
|
+
* const vmmigration = google.vmmigration('v1');
|
|
8802
|
+
*
|
|
8803
|
+
* async function main() {
|
|
8804
|
+
* const auth = new google.auth.GoogleAuth({
|
|
8805
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
8806
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
8807
|
+
* });
|
|
8808
|
+
*
|
|
8809
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
8810
|
+
* const authClient = await auth.getClient();
|
|
8811
|
+
* google.options({auth: authClient});
|
|
8812
|
+
*
|
|
8813
|
+
* // Do the magic
|
|
8814
|
+
* const res = await vmmigration.projects.locations.sources.migratingVms.patch({
|
|
8815
|
+
* // Output only. The identifier of the MigratingVm.
|
|
8816
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
8817
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
8818
|
+
* requestId: 'placeholder-value',
|
|
8819
|
+
* // Field mask is used to specify the fields to be overwritten in the MigratingVm resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
|
|
8820
|
+
* updateMask: 'placeholder-value',
|
|
8821
|
+
*
|
|
8822
|
+
* // Request body metadata
|
|
8823
|
+
* requestBody: {
|
|
8824
|
+
* // request body parameters
|
|
8825
|
+
* // {
|
|
8826
|
+
* // "awsSourceVmDetails": {},
|
|
8827
|
+
* // "azureSourceVmDetails": {},
|
|
8828
|
+
* // "computeEngineDisksTargetDefaults": {},
|
|
8829
|
+
* // "computeEngineTargetDefaults": {},
|
|
8830
|
+
* // "createTime": "my_createTime",
|
|
8831
|
+
* // "currentSyncInfo": {},
|
|
8832
|
+
* // "cutoverForecast": {},
|
|
8833
|
+
* // "description": "my_description",
|
|
8834
|
+
* // "displayName": "my_displayName",
|
|
8835
|
+
* // "error": {},
|
|
8836
|
+
* // "expiration": {},
|
|
8837
|
+
* // "group": "my_group",
|
|
8838
|
+
* // "labels": {},
|
|
8839
|
+
* // "lastReplicationCycle": {},
|
|
8840
|
+
* // "lastSync": {},
|
|
8841
|
+
* // "name": "my_name",
|
|
8842
|
+
* // "policy": {},
|
|
8843
|
+
* // "recentCloneJobs": [],
|
|
8844
|
+
* // "recentCutoverJobs": [],
|
|
8845
|
+
* // "sourceVmId": "my_sourceVmId",
|
|
8846
|
+
* // "state": "my_state",
|
|
8847
|
+
* // "stateTime": "my_stateTime",
|
|
8848
|
+
* // "updateTime": "my_updateTime",
|
|
8849
|
+
* // "vmwareSourceVmDetails": {}
|
|
8850
|
+
* // }
|
|
8851
|
+
* },
|
|
8852
|
+
* });
|
|
8853
|
+
* console.log(res.data);
|
|
8854
|
+
*
|
|
8855
|
+
* // Example response
|
|
8856
|
+
* // {
|
|
8857
|
+
* // "done": false,
|
|
8858
|
+
* // "error": {},
|
|
8859
|
+
* // "metadata": {},
|
|
8860
|
+
* // "name": "my_name",
|
|
8861
|
+
* // "response": {}
|
|
8862
|
+
* // }
|
|
8863
|
+
* }
|
|
8864
|
+
*
|
|
8865
|
+
* main().catch(e => {
|
|
8866
|
+
* console.error(e);
|
|
8867
|
+
* throw e;
|
|
8868
|
+
* });
|
|
8869
|
+
*
|
|
8870
|
+
* ```
|
|
6502
8871
|
*
|
|
6503
8872
|
* @param params - Parameters for request
|
|
6504
8873
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6588,6 +8957,64 @@ export namespace vmmigration_v1 {
|
|
|
6588
8957
|
|
|
6589
8958
|
/**
|
|
6590
8959
|
* Pauses a migration for a VM. If cycle tasks are running they will be cancelled, preserving source task data. Further replication cycles will not be triggered while the VM is paused.
|
|
8960
|
+
* @example
|
|
8961
|
+
* ```js
|
|
8962
|
+
* // Before running the sample:
|
|
8963
|
+
* // - Enable the API at:
|
|
8964
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
8965
|
+
* // - Login into gcloud by running:
|
|
8966
|
+
* // ```sh
|
|
8967
|
+
* // $ gcloud auth application-default login
|
|
8968
|
+
* // ```
|
|
8969
|
+
* // - Install the npm module by running:
|
|
8970
|
+
* // ```sh
|
|
8971
|
+
* // $ npm install googleapis
|
|
8972
|
+
* // ```
|
|
8973
|
+
*
|
|
8974
|
+
* const {google} = require('googleapis');
|
|
8975
|
+
* const vmmigration = google.vmmigration('v1');
|
|
8976
|
+
*
|
|
8977
|
+
* async function main() {
|
|
8978
|
+
* const auth = new google.auth.GoogleAuth({
|
|
8979
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
8980
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
8981
|
+
* });
|
|
8982
|
+
*
|
|
8983
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
8984
|
+
* const authClient = await auth.getClient();
|
|
8985
|
+
* google.options({auth: authClient});
|
|
8986
|
+
*
|
|
8987
|
+
* // Do the magic
|
|
8988
|
+
* const res =
|
|
8989
|
+
* await vmmigration.projects.locations.sources.migratingVms.pauseMigration({
|
|
8990
|
+
* // Required. The name of the MigratingVm.
|
|
8991
|
+
* migratingVm:
|
|
8992
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
8993
|
+
*
|
|
8994
|
+
* // Request body metadata
|
|
8995
|
+
* requestBody: {
|
|
8996
|
+
* // request body parameters
|
|
8997
|
+
* // {}
|
|
8998
|
+
* },
|
|
8999
|
+
* });
|
|
9000
|
+
* console.log(res.data);
|
|
9001
|
+
*
|
|
9002
|
+
* // Example response
|
|
9003
|
+
* // {
|
|
9004
|
+
* // "done": false,
|
|
9005
|
+
* // "error": {},
|
|
9006
|
+
* // "metadata": {},
|
|
9007
|
+
* // "name": "my_name",
|
|
9008
|
+
* // "response": {}
|
|
9009
|
+
* // }
|
|
9010
|
+
* }
|
|
9011
|
+
*
|
|
9012
|
+
* main().catch(e => {
|
|
9013
|
+
* console.error(e);
|
|
9014
|
+
* throw e;
|
|
9015
|
+
* });
|
|
9016
|
+
*
|
|
9017
|
+
* ```
|
|
6591
9018
|
*
|
|
6592
9019
|
* @param params - Parameters for request
|
|
6593
9020
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6680,6 +9107,64 @@ export namespace vmmigration_v1 {
|
|
|
6680
9107
|
|
|
6681
9108
|
/**
|
|
6682
9109
|
* Resumes a migration for a VM. When called on a paused migration, will start the process of uploading data and creating snapshots; when called on a completed cut-over migration, will update the migration to active state and start the process of uploading data and creating snapshots.
|
|
9110
|
+
* @example
|
|
9111
|
+
* ```js
|
|
9112
|
+
* // Before running the sample:
|
|
9113
|
+
* // - Enable the API at:
|
|
9114
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
9115
|
+
* // - Login into gcloud by running:
|
|
9116
|
+
* // ```sh
|
|
9117
|
+
* // $ gcloud auth application-default login
|
|
9118
|
+
* // ```
|
|
9119
|
+
* // - Install the npm module by running:
|
|
9120
|
+
* // ```sh
|
|
9121
|
+
* // $ npm install googleapis
|
|
9122
|
+
* // ```
|
|
9123
|
+
*
|
|
9124
|
+
* const {google} = require('googleapis');
|
|
9125
|
+
* const vmmigration = google.vmmigration('v1');
|
|
9126
|
+
*
|
|
9127
|
+
* async function main() {
|
|
9128
|
+
* const auth = new google.auth.GoogleAuth({
|
|
9129
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
9130
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
9131
|
+
* });
|
|
9132
|
+
*
|
|
9133
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
9134
|
+
* const authClient = await auth.getClient();
|
|
9135
|
+
* google.options({auth: authClient});
|
|
9136
|
+
*
|
|
9137
|
+
* // Do the magic
|
|
9138
|
+
* const res =
|
|
9139
|
+
* await vmmigration.projects.locations.sources.migratingVms.resumeMigration({
|
|
9140
|
+
* // Required. The name of the MigratingVm.
|
|
9141
|
+
* migratingVm:
|
|
9142
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
9143
|
+
*
|
|
9144
|
+
* // Request body metadata
|
|
9145
|
+
* requestBody: {
|
|
9146
|
+
* // request body parameters
|
|
9147
|
+
* // {}
|
|
9148
|
+
* },
|
|
9149
|
+
* });
|
|
9150
|
+
* console.log(res.data);
|
|
9151
|
+
*
|
|
9152
|
+
* // Example response
|
|
9153
|
+
* // {
|
|
9154
|
+
* // "done": false,
|
|
9155
|
+
* // "error": {},
|
|
9156
|
+
* // "metadata": {},
|
|
9157
|
+
* // "name": "my_name",
|
|
9158
|
+
* // "response": {}
|
|
9159
|
+
* // }
|
|
9160
|
+
* }
|
|
9161
|
+
*
|
|
9162
|
+
* main().catch(e => {
|
|
9163
|
+
* console.error(e);
|
|
9164
|
+
* throw e;
|
|
9165
|
+
* });
|
|
9166
|
+
*
|
|
9167
|
+
* ```
|
|
6683
9168
|
*
|
|
6684
9169
|
* @param params - Parameters for request
|
|
6685
9170
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6772,6 +9257,64 @@ export namespace vmmigration_v1 {
|
|
|
6772
9257
|
|
|
6773
9258
|
/**
|
|
6774
9259
|
* Starts migration for a VM. Starts the process of uploading data and creating snapshots, in replication cycles scheduled by the policy.
|
|
9260
|
+
* @example
|
|
9261
|
+
* ```js
|
|
9262
|
+
* // Before running the sample:
|
|
9263
|
+
* // - Enable the API at:
|
|
9264
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
9265
|
+
* // - Login into gcloud by running:
|
|
9266
|
+
* // ```sh
|
|
9267
|
+
* // $ gcloud auth application-default login
|
|
9268
|
+
* // ```
|
|
9269
|
+
* // - Install the npm module by running:
|
|
9270
|
+
* // ```sh
|
|
9271
|
+
* // $ npm install googleapis
|
|
9272
|
+
* // ```
|
|
9273
|
+
*
|
|
9274
|
+
* const {google} = require('googleapis');
|
|
9275
|
+
* const vmmigration = google.vmmigration('v1');
|
|
9276
|
+
*
|
|
9277
|
+
* async function main() {
|
|
9278
|
+
* const auth = new google.auth.GoogleAuth({
|
|
9279
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
9280
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
9281
|
+
* });
|
|
9282
|
+
*
|
|
9283
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
9284
|
+
* const authClient = await auth.getClient();
|
|
9285
|
+
* google.options({auth: authClient});
|
|
9286
|
+
*
|
|
9287
|
+
* // Do the magic
|
|
9288
|
+
* const res =
|
|
9289
|
+
* await vmmigration.projects.locations.sources.migratingVms.startMigration({
|
|
9290
|
+
* // Required. The name of the MigratingVm.
|
|
9291
|
+
* migratingVm:
|
|
9292
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
9293
|
+
*
|
|
9294
|
+
* // Request body metadata
|
|
9295
|
+
* requestBody: {
|
|
9296
|
+
* // request body parameters
|
|
9297
|
+
* // {}
|
|
9298
|
+
* },
|
|
9299
|
+
* });
|
|
9300
|
+
* console.log(res.data);
|
|
9301
|
+
*
|
|
9302
|
+
* // Example response
|
|
9303
|
+
* // {
|
|
9304
|
+
* // "done": false,
|
|
9305
|
+
* // "error": {},
|
|
9306
|
+
* // "metadata": {},
|
|
9307
|
+
* // "name": "my_name",
|
|
9308
|
+
* // "response": {}
|
|
9309
|
+
* // }
|
|
9310
|
+
* }
|
|
9311
|
+
*
|
|
9312
|
+
* main().catch(e => {
|
|
9313
|
+
* console.error(e);
|
|
9314
|
+
* throw e;
|
|
9315
|
+
* });
|
|
9316
|
+
*
|
|
9317
|
+
* ```
|
|
6775
9318
|
*
|
|
6776
9319
|
* @param params - Parameters for request
|
|
6777
9320
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -6890,6 +9433,18 @@ export namespace vmmigration_v1 {
|
|
|
6890
9433
|
*/
|
|
6891
9434
|
name?: string;
|
|
6892
9435
|
}
|
|
9436
|
+
export interface Params$Resource$Projects$Locations$Sources$Migratingvms$Extendmigration
|
|
9437
|
+
extends StandardParameters {
|
|
9438
|
+
/**
|
|
9439
|
+
* Required. The name of the MigratingVm.
|
|
9440
|
+
*/
|
|
9441
|
+
migratingVm?: string;
|
|
9442
|
+
|
|
9443
|
+
/**
|
|
9444
|
+
* Request body metadata
|
|
9445
|
+
*/
|
|
9446
|
+
requestBody?: Schema$ExtendMigrationRequest;
|
|
9447
|
+
}
|
|
6893
9448
|
export interface Params$Resource$Projects$Locations$Sources$Migratingvms$Finalizemigration
|
|
6894
9449
|
extends StandardParameters {
|
|
6895
9450
|
/**
|
|
@@ -7005,6 +9560,63 @@ export namespace vmmigration_v1 {
|
|
|
7005
9560
|
|
|
7006
9561
|
/**
|
|
7007
9562
|
* Initiates the cancellation of a running clone job.
|
|
9563
|
+
* @example
|
|
9564
|
+
* ```js
|
|
9565
|
+
* // Before running the sample:
|
|
9566
|
+
* // - Enable the API at:
|
|
9567
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
9568
|
+
* // - Login into gcloud by running:
|
|
9569
|
+
* // ```sh
|
|
9570
|
+
* // $ gcloud auth application-default login
|
|
9571
|
+
* // ```
|
|
9572
|
+
* // - Install the npm module by running:
|
|
9573
|
+
* // ```sh
|
|
9574
|
+
* // $ npm install googleapis
|
|
9575
|
+
* // ```
|
|
9576
|
+
*
|
|
9577
|
+
* const {google} = require('googleapis');
|
|
9578
|
+
* const vmmigration = google.vmmigration('v1');
|
|
9579
|
+
*
|
|
9580
|
+
* async function main() {
|
|
9581
|
+
* const auth = new google.auth.GoogleAuth({
|
|
9582
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
9583
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
9584
|
+
* });
|
|
9585
|
+
*
|
|
9586
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
9587
|
+
* const authClient = await auth.getClient();
|
|
9588
|
+
* google.options({auth: authClient});
|
|
9589
|
+
*
|
|
9590
|
+
* // Do the magic
|
|
9591
|
+
* const res =
|
|
9592
|
+
* await vmmigration.projects.locations.sources.migratingVms.cloneJobs.cancel({
|
|
9593
|
+
* // Required. The clone job id
|
|
9594
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm/cloneJobs/my-cloneJob',
|
|
9595
|
+
*
|
|
9596
|
+
* // Request body metadata
|
|
9597
|
+
* requestBody: {
|
|
9598
|
+
* // request body parameters
|
|
9599
|
+
* // {}
|
|
9600
|
+
* },
|
|
9601
|
+
* });
|
|
9602
|
+
* console.log(res.data);
|
|
9603
|
+
*
|
|
9604
|
+
* // Example response
|
|
9605
|
+
* // {
|
|
9606
|
+
* // "done": false,
|
|
9607
|
+
* // "error": {},
|
|
9608
|
+
* // "metadata": {},
|
|
9609
|
+
* // "name": "my_name",
|
|
9610
|
+
* // "response": {}
|
|
9611
|
+
* // }
|
|
9612
|
+
* }
|
|
9613
|
+
*
|
|
9614
|
+
* main().catch(e => {
|
|
9615
|
+
* console.error(e);
|
|
9616
|
+
* throw e;
|
|
9617
|
+
* });
|
|
9618
|
+
*
|
|
9619
|
+
* ```
|
|
7008
9620
|
*
|
|
7009
9621
|
* @param params - Parameters for request
|
|
7010
9622
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7094,6 +9706,78 @@ export namespace vmmigration_v1 {
|
|
|
7094
9706
|
|
|
7095
9707
|
/**
|
|
7096
9708
|
* Initiates a Clone of a specific migrating VM.
|
|
9709
|
+
* @example
|
|
9710
|
+
* ```js
|
|
9711
|
+
* // Before running the sample:
|
|
9712
|
+
* // - Enable the API at:
|
|
9713
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
9714
|
+
* // - Login into gcloud by running:
|
|
9715
|
+
* // ```sh
|
|
9716
|
+
* // $ gcloud auth application-default login
|
|
9717
|
+
* // ```
|
|
9718
|
+
* // - Install the npm module by running:
|
|
9719
|
+
* // ```sh
|
|
9720
|
+
* // $ npm install googleapis
|
|
9721
|
+
* // ```
|
|
9722
|
+
*
|
|
9723
|
+
* const {google} = require('googleapis');
|
|
9724
|
+
* const vmmigration = google.vmmigration('v1');
|
|
9725
|
+
*
|
|
9726
|
+
* async function main() {
|
|
9727
|
+
* const auth = new google.auth.GoogleAuth({
|
|
9728
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
9729
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
9730
|
+
* });
|
|
9731
|
+
*
|
|
9732
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
9733
|
+
* const authClient = await auth.getClient();
|
|
9734
|
+
* google.options({auth: authClient});
|
|
9735
|
+
*
|
|
9736
|
+
* // Do the magic
|
|
9737
|
+
* const res =
|
|
9738
|
+
* await vmmigration.projects.locations.sources.migratingVms.cloneJobs.create({
|
|
9739
|
+
* // Required. The clone job identifier.
|
|
9740
|
+
* cloneJobId: 'placeholder-value',
|
|
9741
|
+
* // Required. The Clone's parent.
|
|
9742
|
+
* parent:
|
|
9743
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
9744
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
9745
|
+
* requestId: 'placeholder-value',
|
|
9746
|
+
*
|
|
9747
|
+
* // Request body metadata
|
|
9748
|
+
* requestBody: {
|
|
9749
|
+
* // request body parameters
|
|
9750
|
+
* // {
|
|
9751
|
+
* // "computeEngineDisksTargetDetails": {},
|
|
9752
|
+
* // "computeEngineTargetDetails": {},
|
|
9753
|
+
* // "createTime": "my_createTime",
|
|
9754
|
+
* // "endTime": "my_endTime",
|
|
9755
|
+
* // "error": {},
|
|
9756
|
+
* // "name": "my_name",
|
|
9757
|
+
* // "state": "my_state",
|
|
9758
|
+
* // "stateTime": "my_stateTime",
|
|
9759
|
+
* // "steps": []
|
|
9760
|
+
* // }
|
|
9761
|
+
* },
|
|
9762
|
+
* });
|
|
9763
|
+
* console.log(res.data);
|
|
9764
|
+
*
|
|
9765
|
+
* // Example response
|
|
9766
|
+
* // {
|
|
9767
|
+
* // "done": false,
|
|
9768
|
+
* // "error": {},
|
|
9769
|
+
* // "metadata": {},
|
|
9770
|
+
* // "name": "my_name",
|
|
9771
|
+
* // "response": {}
|
|
9772
|
+
* // }
|
|
9773
|
+
* }
|
|
9774
|
+
*
|
|
9775
|
+
* main().catch(e => {
|
|
9776
|
+
* console.error(e);
|
|
9777
|
+
* throw e;
|
|
9778
|
+
* });
|
|
9779
|
+
*
|
|
9780
|
+
* ```
|
|
7097
9781
|
*
|
|
7098
9782
|
* @param params - Parameters for request
|
|
7099
9783
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7186,6 +9870,61 @@ export namespace vmmigration_v1 {
|
|
|
7186
9870
|
|
|
7187
9871
|
/**
|
|
7188
9872
|
* Gets details of a single CloneJob.
|
|
9873
|
+
* @example
|
|
9874
|
+
* ```js
|
|
9875
|
+
* // Before running the sample:
|
|
9876
|
+
* // - Enable the API at:
|
|
9877
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
9878
|
+
* // - Login into gcloud by running:
|
|
9879
|
+
* // ```sh
|
|
9880
|
+
* // $ gcloud auth application-default login
|
|
9881
|
+
* // ```
|
|
9882
|
+
* // - Install the npm module by running:
|
|
9883
|
+
* // ```sh
|
|
9884
|
+
* // $ npm install googleapis
|
|
9885
|
+
* // ```
|
|
9886
|
+
*
|
|
9887
|
+
* const {google} = require('googleapis');
|
|
9888
|
+
* const vmmigration = google.vmmigration('v1');
|
|
9889
|
+
*
|
|
9890
|
+
* async function main() {
|
|
9891
|
+
* const auth = new google.auth.GoogleAuth({
|
|
9892
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
9893
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
9894
|
+
* });
|
|
9895
|
+
*
|
|
9896
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
9897
|
+
* const authClient = await auth.getClient();
|
|
9898
|
+
* google.options({auth: authClient});
|
|
9899
|
+
*
|
|
9900
|
+
* // Do the magic
|
|
9901
|
+
* const res =
|
|
9902
|
+
* await vmmigration.projects.locations.sources.migratingVms.cloneJobs.get({
|
|
9903
|
+
* // Required. The name of the CloneJob.
|
|
9904
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm/cloneJobs/my-cloneJob',
|
|
9905
|
+
* });
|
|
9906
|
+
* console.log(res.data);
|
|
9907
|
+
*
|
|
9908
|
+
* // Example response
|
|
9909
|
+
* // {
|
|
9910
|
+
* // "computeEngineDisksTargetDetails": {},
|
|
9911
|
+
* // "computeEngineTargetDetails": {},
|
|
9912
|
+
* // "createTime": "my_createTime",
|
|
9913
|
+
* // "endTime": "my_endTime",
|
|
9914
|
+
* // "error": {},
|
|
9915
|
+
* // "name": "my_name",
|
|
9916
|
+
* // "state": "my_state",
|
|
9917
|
+
* // "stateTime": "my_stateTime",
|
|
9918
|
+
* // "steps": []
|
|
9919
|
+
* // }
|
|
9920
|
+
* }
|
|
9921
|
+
*
|
|
9922
|
+
* main().catch(e => {
|
|
9923
|
+
* console.error(e);
|
|
9924
|
+
* throw e;
|
|
9925
|
+
* });
|
|
9926
|
+
*
|
|
9927
|
+
* ```
|
|
7189
9928
|
*
|
|
7190
9929
|
* @param params - Parameters for request
|
|
7191
9930
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7275,6 +10014,64 @@ export namespace vmmigration_v1 {
|
|
|
7275
10014
|
|
|
7276
10015
|
/**
|
|
7277
10016
|
* Lists the CloneJobs of a migrating VM. Only 25 most recent CloneJobs are listed.
|
|
10017
|
+
* @example
|
|
10018
|
+
* ```js
|
|
10019
|
+
* // Before running the sample:
|
|
10020
|
+
* // - Enable the API at:
|
|
10021
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
10022
|
+
* // - Login into gcloud by running:
|
|
10023
|
+
* // ```sh
|
|
10024
|
+
* // $ gcloud auth application-default login
|
|
10025
|
+
* // ```
|
|
10026
|
+
* // - Install the npm module by running:
|
|
10027
|
+
* // ```sh
|
|
10028
|
+
* // $ npm install googleapis
|
|
10029
|
+
* // ```
|
|
10030
|
+
*
|
|
10031
|
+
* const {google} = require('googleapis');
|
|
10032
|
+
* const vmmigration = google.vmmigration('v1');
|
|
10033
|
+
*
|
|
10034
|
+
* async function main() {
|
|
10035
|
+
* const auth = new google.auth.GoogleAuth({
|
|
10036
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
10037
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
10038
|
+
* });
|
|
10039
|
+
*
|
|
10040
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
10041
|
+
* const authClient = await auth.getClient();
|
|
10042
|
+
* google.options({auth: authClient});
|
|
10043
|
+
*
|
|
10044
|
+
* // Do the magic
|
|
10045
|
+
* const res =
|
|
10046
|
+
* await vmmigration.projects.locations.sources.migratingVms.cloneJobs.list({
|
|
10047
|
+
* // Optional. The filter request.
|
|
10048
|
+
* filter: 'placeholder-value',
|
|
10049
|
+
* // Optional. the order by fields for the result.
|
|
10050
|
+
* orderBy: 'placeholder-value',
|
|
10051
|
+
* // Optional. The maximum number of clone jobs to return. The service may return fewer than this value. If unspecified, at most 500 clone jobs will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
10052
|
+
* pageSize: 'placeholder-value',
|
|
10053
|
+
* // Required. A page token, received from a previous `ListCloneJobs` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListCloneJobs` must match the call that provided the page token.
|
|
10054
|
+
* pageToken: 'placeholder-value',
|
|
10055
|
+
* // Required. The parent, which owns this collection of source VMs.
|
|
10056
|
+
* parent:
|
|
10057
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
10058
|
+
* });
|
|
10059
|
+
* console.log(res.data);
|
|
10060
|
+
*
|
|
10061
|
+
* // Example response
|
|
10062
|
+
* // {
|
|
10063
|
+
* // "cloneJobs": [],
|
|
10064
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
10065
|
+
* // "unreachable": []
|
|
10066
|
+
* // }
|
|
10067
|
+
* }
|
|
10068
|
+
*
|
|
10069
|
+
* main().catch(e => {
|
|
10070
|
+
* console.error(e);
|
|
10071
|
+
* throw e;
|
|
10072
|
+
* });
|
|
10073
|
+
*
|
|
10074
|
+
* ```
|
|
7278
10075
|
*
|
|
7279
10076
|
* @param params - Parameters for request
|
|
7280
10077
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7439,6 +10236,65 @@ export namespace vmmigration_v1 {
|
|
|
7439
10236
|
|
|
7440
10237
|
/**
|
|
7441
10238
|
* Initiates the cancellation of a running cutover job.
|
|
10239
|
+
* @example
|
|
10240
|
+
* ```js
|
|
10241
|
+
* // Before running the sample:
|
|
10242
|
+
* // - Enable the API at:
|
|
10243
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
10244
|
+
* // - Login into gcloud by running:
|
|
10245
|
+
* // ```sh
|
|
10246
|
+
* // $ gcloud auth application-default login
|
|
10247
|
+
* // ```
|
|
10248
|
+
* // - Install the npm module by running:
|
|
10249
|
+
* // ```sh
|
|
10250
|
+
* // $ npm install googleapis
|
|
10251
|
+
* // ```
|
|
10252
|
+
*
|
|
10253
|
+
* const {google} = require('googleapis');
|
|
10254
|
+
* const vmmigration = google.vmmigration('v1');
|
|
10255
|
+
*
|
|
10256
|
+
* async function main() {
|
|
10257
|
+
* const auth = new google.auth.GoogleAuth({
|
|
10258
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
10259
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
10260
|
+
* });
|
|
10261
|
+
*
|
|
10262
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
10263
|
+
* const authClient = await auth.getClient();
|
|
10264
|
+
* google.options({auth: authClient});
|
|
10265
|
+
*
|
|
10266
|
+
* // Do the magic
|
|
10267
|
+
* const res =
|
|
10268
|
+
* await vmmigration.projects.locations.sources.migratingVms.cutoverJobs.cancel(
|
|
10269
|
+
* {
|
|
10270
|
+
* // Required. The cutover job id
|
|
10271
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm/cutoverJobs/my-cutoverJob',
|
|
10272
|
+
*
|
|
10273
|
+
* // Request body metadata
|
|
10274
|
+
* requestBody: {
|
|
10275
|
+
* // request body parameters
|
|
10276
|
+
* // {}
|
|
10277
|
+
* },
|
|
10278
|
+
* },
|
|
10279
|
+
* );
|
|
10280
|
+
* console.log(res.data);
|
|
10281
|
+
*
|
|
10282
|
+
* // Example response
|
|
10283
|
+
* // {
|
|
10284
|
+
* // "done": false,
|
|
10285
|
+
* // "error": {},
|
|
10286
|
+
* // "metadata": {},
|
|
10287
|
+
* // "name": "my_name",
|
|
10288
|
+
* // "response": {}
|
|
10289
|
+
* // }
|
|
10290
|
+
* }
|
|
10291
|
+
*
|
|
10292
|
+
* main().catch(e => {
|
|
10293
|
+
* console.error(e);
|
|
10294
|
+
* throw e;
|
|
10295
|
+
* });
|
|
10296
|
+
*
|
|
10297
|
+
* ```
|
|
7442
10298
|
*
|
|
7443
10299
|
* @param params - Parameters for request
|
|
7444
10300
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7528,6 +10384,82 @@ export namespace vmmigration_v1 {
|
|
|
7528
10384
|
|
|
7529
10385
|
/**
|
|
7530
10386
|
* Initiates a Cutover of a specific migrating VM. The returned LRO is completed when the cutover job resource is created and the job is initiated.
|
|
10387
|
+
* @example
|
|
10388
|
+
* ```js
|
|
10389
|
+
* // Before running the sample:
|
|
10390
|
+
* // - Enable the API at:
|
|
10391
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
10392
|
+
* // - Login into gcloud by running:
|
|
10393
|
+
* // ```sh
|
|
10394
|
+
* // $ gcloud auth application-default login
|
|
10395
|
+
* // ```
|
|
10396
|
+
* // - Install the npm module by running:
|
|
10397
|
+
* // ```sh
|
|
10398
|
+
* // $ npm install googleapis
|
|
10399
|
+
* // ```
|
|
10400
|
+
*
|
|
10401
|
+
* const {google} = require('googleapis');
|
|
10402
|
+
* const vmmigration = google.vmmigration('v1');
|
|
10403
|
+
*
|
|
10404
|
+
* async function main() {
|
|
10405
|
+
* const auth = new google.auth.GoogleAuth({
|
|
10406
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
10407
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
10408
|
+
* });
|
|
10409
|
+
*
|
|
10410
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
10411
|
+
* const authClient = await auth.getClient();
|
|
10412
|
+
* google.options({auth: authClient});
|
|
10413
|
+
*
|
|
10414
|
+
* // Do the magic
|
|
10415
|
+
* const res =
|
|
10416
|
+
* await vmmigration.projects.locations.sources.migratingVms.cutoverJobs.create(
|
|
10417
|
+
* {
|
|
10418
|
+
* // Required. The cutover job identifier.
|
|
10419
|
+
* cutoverJobId: 'placeholder-value',
|
|
10420
|
+
* // Required. The Cutover's parent.
|
|
10421
|
+
* parent:
|
|
10422
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
10423
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
10424
|
+
* requestId: 'placeholder-value',
|
|
10425
|
+
*
|
|
10426
|
+
* // Request body metadata
|
|
10427
|
+
* requestBody: {
|
|
10428
|
+
* // request body parameters
|
|
10429
|
+
* // {
|
|
10430
|
+
* // "computeEngineDisksTargetDetails": {},
|
|
10431
|
+
* // "computeEngineTargetDetails": {},
|
|
10432
|
+
* // "createTime": "my_createTime",
|
|
10433
|
+
* // "endTime": "my_endTime",
|
|
10434
|
+
* // "error": {},
|
|
10435
|
+
* // "name": "my_name",
|
|
10436
|
+
* // "progressPercent": 0,
|
|
10437
|
+
* // "state": "my_state",
|
|
10438
|
+
* // "stateMessage": "my_stateMessage",
|
|
10439
|
+
* // "stateTime": "my_stateTime",
|
|
10440
|
+
* // "steps": []
|
|
10441
|
+
* // }
|
|
10442
|
+
* },
|
|
10443
|
+
* },
|
|
10444
|
+
* );
|
|
10445
|
+
* console.log(res.data);
|
|
10446
|
+
*
|
|
10447
|
+
* // Example response
|
|
10448
|
+
* // {
|
|
10449
|
+
* // "done": false,
|
|
10450
|
+
* // "error": {},
|
|
10451
|
+
* // "metadata": {},
|
|
10452
|
+
* // "name": "my_name",
|
|
10453
|
+
* // "response": {}
|
|
10454
|
+
* // }
|
|
10455
|
+
* }
|
|
10456
|
+
*
|
|
10457
|
+
* main().catch(e => {
|
|
10458
|
+
* console.error(e);
|
|
10459
|
+
* throw e;
|
|
10460
|
+
* });
|
|
10461
|
+
*
|
|
10462
|
+
* ```
|
|
7531
10463
|
*
|
|
7532
10464
|
* @param params - Parameters for request
|
|
7533
10465
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7620,6 +10552,63 @@ export namespace vmmigration_v1 {
|
|
|
7620
10552
|
|
|
7621
10553
|
/**
|
|
7622
10554
|
* Gets details of a single CutoverJob.
|
|
10555
|
+
* @example
|
|
10556
|
+
* ```js
|
|
10557
|
+
* // Before running the sample:
|
|
10558
|
+
* // - Enable the API at:
|
|
10559
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
10560
|
+
* // - Login into gcloud by running:
|
|
10561
|
+
* // ```sh
|
|
10562
|
+
* // $ gcloud auth application-default login
|
|
10563
|
+
* // ```
|
|
10564
|
+
* // - Install the npm module by running:
|
|
10565
|
+
* // ```sh
|
|
10566
|
+
* // $ npm install googleapis
|
|
10567
|
+
* // ```
|
|
10568
|
+
*
|
|
10569
|
+
* const {google} = require('googleapis');
|
|
10570
|
+
* const vmmigration = google.vmmigration('v1');
|
|
10571
|
+
*
|
|
10572
|
+
* async function main() {
|
|
10573
|
+
* const auth = new google.auth.GoogleAuth({
|
|
10574
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
10575
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
10576
|
+
* });
|
|
10577
|
+
*
|
|
10578
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
10579
|
+
* const authClient = await auth.getClient();
|
|
10580
|
+
* google.options({auth: authClient});
|
|
10581
|
+
*
|
|
10582
|
+
* // Do the magic
|
|
10583
|
+
* const res =
|
|
10584
|
+
* await vmmigration.projects.locations.sources.migratingVms.cutoverJobs.get({
|
|
10585
|
+
* // Required. The name of the CutoverJob.
|
|
10586
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm/cutoverJobs/my-cutoverJob',
|
|
10587
|
+
* });
|
|
10588
|
+
* console.log(res.data);
|
|
10589
|
+
*
|
|
10590
|
+
* // Example response
|
|
10591
|
+
* // {
|
|
10592
|
+
* // "computeEngineDisksTargetDetails": {},
|
|
10593
|
+
* // "computeEngineTargetDetails": {},
|
|
10594
|
+
* // "createTime": "my_createTime",
|
|
10595
|
+
* // "endTime": "my_endTime",
|
|
10596
|
+
* // "error": {},
|
|
10597
|
+
* // "name": "my_name",
|
|
10598
|
+
* // "progressPercent": 0,
|
|
10599
|
+
* // "state": "my_state",
|
|
10600
|
+
* // "stateMessage": "my_stateMessage",
|
|
10601
|
+
* // "stateTime": "my_stateTime",
|
|
10602
|
+
* // "steps": []
|
|
10603
|
+
* // }
|
|
10604
|
+
* }
|
|
10605
|
+
*
|
|
10606
|
+
* main().catch(e => {
|
|
10607
|
+
* console.error(e);
|
|
10608
|
+
* throw e;
|
|
10609
|
+
* });
|
|
10610
|
+
*
|
|
10611
|
+
* ```
|
|
7623
10612
|
*
|
|
7624
10613
|
* @param params - Parameters for request
|
|
7625
10614
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7709,6 +10698,64 @@ export namespace vmmigration_v1 {
|
|
|
7709
10698
|
|
|
7710
10699
|
/**
|
|
7711
10700
|
* Lists the CutoverJobs of a migrating VM. Only 25 most recent CutoverJobs are listed.
|
|
10701
|
+
* @example
|
|
10702
|
+
* ```js
|
|
10703
|
+
* // Before running the sample:
|
|
10704
|
+
* // - Enable the API at:
|
|
10705
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
10706
|
+
* // - Login into gcloud by running:
|
|
10707
|
+
* // ```sh
|
|
10708
|
+
* // $ gcloud auth application-default login
|
|
10709
|
+
* // ```
|
|
10710
|
+
* // - Install the npm module by running:
|
|
10711
|
+
* // ```sh
|
|
10712
|
+
* // $ npm install googleapis
|
|
10713
|
+
* // ```
|
|
10714
|
+
*
|
|
10715
|
+
* const {google} = require('googleapis');
|
|
10716
|
+
* const vmmigration = google.vmmigration('v1');
|
|
10717
|
+
*
|
|
10718
|
+
* async function main() {
|
|
10719
|
+
* const auth = new google.auth.GoogleAuth({
|
|
10720
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
10721
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
10722
|
+
* });
|
|
10723
|
+
*
|
|
10724
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
10725
|
+
* const authClient = await auth.getClient();
|
|
10726
|
+
* google.options({auth: authClient});
|
|
10727
|
+
*
|
|
10728
|
+
* // Do the magic
|
|
10729
|
+
* const res =
|
|
10730
|
+
* await vmmigration.projects.locations.sources.migratingVms.cutoverJobs.list({
|
|
10731
|
+
* // Optional. The filter request.
|
|
10732
|
+
* filter: 'placeholder-value',
|
|
10733
|
+
* // Optional. the order by fields for the result.
|
|
10734
|
+
* orderBy: 'placeholder-value',
|
|
10735
|
+
* // Optional. The maximum number of cutover jobs to return. The service may return fewer than this value. If unspecified, at most 500 cutover jobs will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
10736
|
+
* pageSize: 'placeholder-value',
|
|
10737
|
+
* // Required. A page token, received from a previous `ListCutoverJobs` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListCutoverJobs` must match the call that provided the page token.
|
|
10738
|
+
* pageToken: 'placeholder-value',
|
|
10739
|
+
* // Required. The parent, which owns this collection of migrating VMs.
|
|
10740
|
+
* parent:
|
|
10741
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
10742
|
+
* });
|
|
10743
|
+
* console.log(res.data);
|
|
10744
|
+
*
|
|
10745
|
+
* // Example response
|
|
10746
|
+
* // {
|
|
10747
|
+
* // "cutoverJobs": [],
|
|
10748
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
10749
|
+
* // "unreachable": []
|
|
10750
|
+
* // }
|
|
10751
|
+
* }
|
|
10752
|
+
*
|
|
10753
|
+
* main().catch(e => {
|
|
10754
|
+
* console.error(e);
|
|
10755
|
+
* throw e;
|
|
10756
|
+
* });
|
|
10757
|
+
*
|
|
10758
|
+
* ```
|
|
7712
10759
|
*
|
|
7713
10760
|
* @param params - Parameters for request
|
|
7714
10761
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7873,6 +10920,64 @@ export namespace vmmigration_v1 {
|
|
|
7873
10920
|
|
|
7874
10921
|
/**
|
|
7875
10922
|
* Gets details of a single ReplicationCycle.
|
|
10923
|
+
* @example
|
|
10924
|
+
* ```js
|
|
10925
|
+
* // Before running the sample:
|
|
10926
|
+
* // - Enable the API at:
|
|
10927
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
10928
|
+
* // - Login into gcloud by running:
|
|
10929
|
+
* // ```sh
|
|
10930
|
+
* // $ gcloud auth application-default login
|
|
10931
|
+
* // ```
|
|
10932
|
+
* // - Install the npm module by running:
|
|
10933
|
+
* // ```sh
|
|
10934
|
+
* // $ npm install googleapis
|
|
10935
|
+
* // ```
|
|
10936
|
+
*
|
|
10937
|
+
* const {google} = require('googleapis');
|
|
10938
|
+
* const vmmigration = google.vmmigration('v1');
|
|
10939
|
+
*
|
|
10940
|
+
* async function main() {
|
|
10941
|
+
* const auth = new google.auth.GoogleAuth({
|
|
10942
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
10943
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
10944
|
+
* });
|
|
10945
|
+
*
|
|
10946
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
10947
|
+
* const authClient = await auth.getClient();
|
|
10948
|
+
* google.options({auth: authClient});
|
|
10949
|
+
*
|
|
10950
|
+
* // Do the magic
|
|
10951
|
+
* const res =
|
|
10952
|
+
* await vmmigration.projects.locations.sources.migratingVms.replicationCycles.get(
|
|
10953
|
+
* {
|
|
10954
|
+
* // Required. The name of the ReplicationCycle.
|
|
10955
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm/replicationCycles/my-replicationCycle',
|
|
10956
|
+
* },
|
|
10957
|
+
* );
|
|
10958
|
+
* console.log(res.data);
|
|
10959
|
+
*
|
|
10960
|
+
* // Example response
|
|
10961
|
+
* // {
|
|
10962
|
+
* // "cycleNumber": 0,
|
|
10963
|
+
* // "endTime": "my_endTime",
|
|
10964
|
+
* // "error": {},
|
|
10965
|
+
* // "name": "my_name",
|
|
10966
|
+
* // "progressPercent": 0,
|
|
10967
|
+
* // "startTime": "my_startTime",
|
|
10968
|
+
* // "state": "my_state",
|
|
10969
|
+
* // "steps": [],
|
|
10970
|
+
* // "totalPauseDuration": "my_totalPauseDuration",
|
|
10971
|
+
* // "warnings": []
|
|
10972
|
+
* // }
|
|
10973
|
+
* }
|
|
10974
|
+
*
|
|
10975
|
+
* main().catch(e => {
|
|
10976
|
+
* console.error(e);
|
|
10977
|
+
* throw e;
|
|
10978
|
+
* });
|
|
10979
|
+
*
|
|
10980
|
+
* ```
|
|
7876
10981
|
*
|
|
7877
10982
|
* @param params - Parameters for request
|
|
7878
10983
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -7962,6 +11067,66 @@ export namespace vmmigration_v1 {
|
|
|
7962
11067
|
|
|
7963
11068
|
/**
|
|
7964
11069
|
* Lists ReplicationCycles in a given MigratingVM.
|
|
11070
|
+
* @example
|
|
11071
|
+
* ```js
|
|
11072
|
+
* // Before running the sample:
|
|
11073
|
+
* // - Enable the API at:
|
|
11074
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
11075
|
+
* // - Login into gcloud by running:
|
|
11076
|
+
* // ```sh
|
|
11077
|
+
* // $ gcloud auth application-default login
|
|
11078
|
+
* // ```
|
|
11079
|
+
* // - Install the npm module by running:
|
|
11080
|
+
* // ```sh
|
|
11081
|
+
* // $ npm install googleapis
|
|
11082
|
+
* // ```
|
|
11083
|
+
*
|
|
11084
|
+
* const {google} = require('googleapis');
|
|
11085
|
+
* const vmmigration = google.vmmigration('v1');
|
|
11086
|
+
*
|
|
11087
|
+
* async function main() {
|
|
11088
|
+
* const auth = new google.auth.GoogleAuth({
|
|
11089
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
11090
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
11091
|
+
* });
|
|
11092
|
+
*
|
|
11093
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
11094
|
+
* const authClient = await auth.getClient();
|
|
11095
|
+
* google.options({auth: authClient});
|
|
11096
|
+
*
|
|
11097
|
+
* // Do the magic
|
|
11098
|
+
* const res =
|
|
11099
|
+
* await vmmigration.projects.locations.sources.migratingVms.replicationCycles.list(
|
|
11100
|
+
* {
|
|
11101
|
+
* // Optional. The filter request.
|
|
11102
|
+
* filter: 'placeholder-value',
|
|
11103
|
+
* // Optional. the order by fields for the result.
|
|
11104
|
+
* orderBy: 'placeholder-value',
|
|
11105
|
+
* // Optional. The maximum number of replication cycles to return. The service may return fewer than this value. If unspecified, at most 100 migrating VMs will be returned. The maximum value is 100; values above 100 will be coerced to 100.
|
|
11106
|
+
* pageSize: 'placeholder-value',
|
|
11107
|
+
* // Required. A page token, received from a previous `ListReplicationCycles` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListReplicationCycles` must match the call that provided the page token.
|
|
11108
|
+
* pageToken: 'placeholder-value',
|
|
11109
|
+
* // Required. The parent, which owns this collection of ReplicationCycles.
|
|
11110
|
+
* parent:
|
|
11111
|
+
* 'projects/my-project/locations/my-location/sources/my-source/migratingVms/my-migratingVm',
|
|
11112
|
+
* },
|
|
11113
|
+
* );
|
|
11114
|
+
* console.log(res.data);
|
|
11115
|
+
*
|
|
11116
|
+
* // Example response
|
|
11117
|
+
* // {
|
|
11118
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
11119
|
+
* // "replicationCycles": [],
|
|
11120
|
+
* // "unreachable": []
|
|
11121
|
+
* // }
|
|
11122
|
+
* }
|
|
11123
|
+
*
|
|
11124
|
+
* main().catch(e => {
|
|
11125
|
+
* console.error(e);
|
|
11126
|
+
* throw e;
|
|
11127
|
+
* });
|
|
11128
|
+
*
|
|
11129
|
+
* ```
|
|
7965
11130
|
*
|
|
7966
11131
|
* @param params - Parameters for request
|
|
7967
11132
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8098,6 +11263,78 @@ export namespace vmmigration_v1 {
|
|
|
8098
11263
|
|
|
8099
11264
|
/**
|
|
8100
11265
|
* Creates a new UtilizationReport.
|
|
11266
|
+
* @example
|
|
11267
|
+
* ```js
|
|
11268
|
+
* // Before running the sample:
|
|
11269
|
+
* // - Enable the API at:
|
|
11270
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
11271
|
+
* // - Login into gcloud by running:
|
|
11272
|
+
* // ```sh
|
|
11273
|
+
* // $ gcloud auth application-default login
|
|
11274
|
+
* // ```
|
|
11275
|
+
* // - Install the npm module by running:
|
|
11276
|
+
* // ```sh
|
|
11277
|
+
* // $ npm install googleapis
|
|
11278
|
+
* // ```
|
|
11279
|
+
*
|
|
11280
|
+
* const {google} = require('googleapis');
|
|
11281
|
+
* const vmmigration = google.vmmigration('v1');
|
|
11282
|
+
*
|
|
11283
|
+
* async function main() {
|
|
11284
|
+
* const auth = new google.auth.GoogleAuth({
|
|
11285
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
11286
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
11287
|
+
* });
|
|
11288
|
+
*
|
|
11289
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
11290
|
+
* const authClient = await auth.getClient();
|
|
11291
|
+
* google.options({auth: authClient});
|
|
11292
|
+
*
|
|
11293
|
+
* // Do the magic
|
|
11294
|
+
* const res =
|
|
11295
|
+
* await vmmigration.projects.locations.sources.utilizationReports.create({
|
|
11296
|
+
* // Required. The Utilization Report's parent.
|
|
11297
|
+
* parent: 'projects/my-project/locations/my-location/sources/my-source',
|
|
11298
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
11299
|
+
* requestId: 'placeholder-value',
|
|
11300
|
+
* // Required. The ID to use for the report, which will become the final component of the reports's resource name. This value maximum length is 63 characters, and valid characters are /a-z-/. It must start with an english letter and must not end with a hyphen.
|
|
11301
|
+
* utilizationReportId: 'placeholder-value',
|
|
11302
|
+
*
|
|
11303
|
+
* // Request body metadata
|
|
11304
|
+
* requestBody: {
|
|
11305
|
+
* // request body parameters
|
|
11306
|
+
* // {
|
|
11307
|
+
* // "createTime": "my_createTime",
|
|
11308
|
+
* // "displayName": "my_displayName",
|
|
11309
|
+
* // "error": {},
|
|
11310
|
+
* // "frameEndTime": "my_frameEndTime",
|
|
11311
|
+
* // "name": "my_name",
|
|
11312
|
+
* // "state": "my_state",
|
|
11313
|
+
* // "stateTime": "my_stateTime",
|
|
11314
|
+
* // "timeFrame": "my_timeFrame",
|
|
11315
|
+
* // "vmCount": 0,
|
|
11316
|
+
* // "vms": []
|
|
11317
|
+
* // }
|
|
11318
|
+
* },
|
|
11319
|
+
* });
|
|
11320
|
+
* console.log(res.data);
|
|
11321
|
+
*
|
|
11322
|
+
* // Example response
|
|
11323
|
+
* // {
|
|
11324
|
+
* // "done": false,
|
|
11325
|
+
* // "error": {},
|
|
11326
|
+
* // "metadata": {},
|
|
11327
|
+
* // "name": "my_name",
|
|
11328
|
+
* // "response": {}
|
|
11329
|
+
* // }
|
|
11330
|
+
* }
|
|
11331
|
+
*
|
|
11332
|
+
* main().catch(e => {
|
|
11333
|
+
* console.error(e);
|
|
11334
|
+
* throw e;
|
|
11335
|
+
* });
|
|
11336
|
+
*
|
|
11337
|
+
* ```
|
|
8101
11338
|
*
|
|
8102
11339
|
* @param params - Parameters for request
|
|
8103
11340
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8190,6 +11427,59 @@ export namespace vmmigration_v1 {
|
|
|
8190
11427
|
|
|
8191
11428
|
/**
|
|
8192
11429
|
* Deletes a single Utilization Report.
|
|
11430
|
+
* @example
|
|
11431
|
+
* ```js
|
|
11432
|
+
* // Before running the sample:
|
|
11433
|
+
* // - Enable the API at:
|
|
11434
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
11435
|
+
* // - Login into gcloud by running:
|
|
11436
|
+
* // ```sh
|
|
11437
|
+
* // $ gcloud auth application-default login
|
|
11438
|
+
* // ```
|
|
11439
|
+
* // - Install the npm module by running:
|
|
11440
|
+
* // ```sh
|
|
11441
|
+
* // $ npm install googleapis
|
|
11442
|
+
* // ```
|
|
11443
|
+
*
|
|
11444
|
+
* const {google} = require('googleapis');
|
|
11445
|
+
* const vmmigration = google.vmmigration('v1');
|
|
11446
|
+
*
|
|
11447
|
+
* async function main() {
|
|
11448
|
+
* const auth = new google.auth.GoogleAuth({
|
|
11449
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
11450
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
11451
|
+
* });
|
|
11452
|
+
*
|
|
11453
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
11454
|
+
* const authClient = await auth.getClient();
|
|
11455
|
+
* google.options({auth: authClient});
|
|
11456
|
+
*
|
|
11457
|
+
* // Do the magic
|
|
11458
|
+
* const res =
|
|
11459
|
+
* await vmmigration.projects.locations.sources.utilizationReports.delete({
|
|
11460
|
+
* // Required. The Utilization Report name.
|
|
11461
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/utilizationReports/my-utilizationReport',
|
|
11462
|
+
* // Optional. A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
11463
|
+
* requestId: 'placeholder-value',
|
|
11464
|
+
* });
|
|
11465
|
+
* console.log(res.data);
|
|
11466
|
+
*
|
|
11467
|
+
* // Example response
|
|
11468
|
+
* // {
|
|
11469
|
+
* // "done": false,
|
|
11470
|
+
* // "error": {},
|
|
11471
|
+
* // "metadata": {},
|
|
11472
|
+
* // "name": "my_name",
|
|
11473
|
+
* // "response": {}
|
|
11474
|
+
* // }
|
|
11475
|
+
* }
|
|
11476
|
+
*
|
|
11477
|
+
* main().catch(e => {
|
|
11478
|
+
* console.error(e);
|
|
11479
|
+
* throw e;
|
|
11480
|
+
* });
|
|
11481
|
+
*
|
|
11482
|
+
* ```
|
|
8193
11483
|
*
|
|
8194
11484
|
* @param params - Parameters for request
|
|
8195
11485
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8279,6 +11569,64 @@ export namespace vmmigration_v1 {
|
|
|
8279
11569
|
|
|
8280
11570
|
/**
|
|
8281
11571
|
* Gets a single Utilization Report.
|
|
11572
|
+
* @example
|
|
11573
|
+
* ```js
|
|
11574
|
+
* // Before running the sample:
|
|
11575
|
+
* // - Enable the API at:
|
|
11576
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
11577
|
+
* // - Login into gcloud by running:
|
|
11578
|
+
* // ```sh
|
|
11579
|
+
* // $ gcloud auth application-default login
|
|
11580
|
+
* // ```
|
|
11581
|
+
* // - Install the npm module by running:
|
|
11582
|
+
* // ```sh
|
|
11583
|
+
* // $ npm install googleapis
|
|
11584
|
+
* // ```
|
|
11585
|
+
*
|
|
11586
|
+
* const {google} = require('googleapis');
|
|
11587
|
+
* const vmmigration = google.vmmigration('v1');
|
|
11588
|
+
*
|
|
11589
|
+
* async function main() {
|
|
11590
|
+
* const auth = new google.auth.GoogleAuth({
|
|
11591
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
11592
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
11593
|
+
* });
|
|
11594
|
+
*
|
|
11595
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
11596
|
+
* const authClient = await auth.getClient();
|
|
11597
|
+
* google.options({auth: authClient});
|
|
11598
|
+
*
|
|
11599
|
+
* // Do the magic
|
|
11600
|
+
* const res =
|
|
11601
|
+
* await vmmigration.projects.locations.sources.utilizationReports.get({
|
|
11602
|
+
* // Required. The Utilization Report name.
|
|
11603
|
+
* name: 'projects/my-project/locations/my-location/sources/my-source/utilizationReports/my-utilizationReport',
|
|
11604
|
+
* // Optional. The level of details of the report. Defaults to FULL
|
|
11605
|
+
* view: 'placeholder-value',
|
|
11606
|
+
* });
|
|
11607
|
+
* console.log(res.data);
|
|
11608
|
+
*
|
|
11609
|
+
* // Example response
|
|
11610
|
+
* // {
|
|
11611
|
+
* // "createTime": "my_createTime",
|
|
11612
|
+
* // "displayName": "my_displayName",
|
|
11613
|
+
* // "error": {},
|
|
11614
|
+
* // "frameEndTime": "my_frameEndTime",
|
|
11615
|
+
* // "name": "my_name",
|
|
11616
|
+
* // "state": "my_state",
|
|
11617
|
+
* // "stateTime": "my_stateTime",
|
|
11618
|
+
* // "timeFrame": "my_timeFrame",
|
|
11619
|
+
* // "vmCount": 0,
|
|
11620
|
+
* // "vms": []
|
|
11621
|
+
* // }
|
|
11622
|
+
* }
|
|
11623
|
+
*
|
|
11624
|
+
* main().catch(e => {
|
|
11625
|
+
* console.error(e);
|
|
11626
|
+
* throw e;
|
|
11627
|
+
* });
|
|
11628
|
+
*
|
|
11629
|
+
* ```
|
|
8282
11630
|
*
|
|
8283
11631
|
* @param params - Parameters for request
|
|
8284
11632
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8368,6 +11716,65 @@ export namespace vmmigration_v1 {
|
|
|
8368
11716
|
|
|
8369
11717
|
/**
|
|
8370
11718
|
* Lists Utilization Reports of the given Source.
|
|
11719
|
+
* @example
|
|
11720
|
+
* ```js
|
|
11721
|
+
* // Before running the sample:
|
|
11722
|
+
* // - Enable the API at:
|
|
11723
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
11724
|
+
* // - Login into gcloud by running:
|
|
11725
|
+
* // ```sh
|
|
11726
|
+
* // $ gcloud auth application-default login
|
|
11727
|
+
* // ```
|
|
11728
|
+
* // - Install the npm module by running:
|
|
11729
|
+
* // ```sh
|
|
11730
|
+
* // $ npm install googleapis
|
|
11731
|
+
* // ```
|
|
11732
|
+
*
|
|
11733
|
+
* const {google} = require('googleapis');
|
|
11734
|
+
* const vmmigration = google.vmmigration('v1');
|
|
11735
|
+
*
|
|
11736
|
+
* async function main() {
|
|
11737
|
+
* const auth = new google.auth.GoogleAuth({
|
|
11738
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
11739
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
11740
|
+
* });
|
|
11741
|
+
*
|
|
11742
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
11743
|
+
* const authClient = await auth.getClient();
|
|
11744
|
+
* google.options({auth: authClient});
|
|
11745
|
+
*
|
|
11746
|
+
* // Do the magic
|
|
11747
|
+
* const res =
|
|
11748
|
+
* await vmmigration.projects.locations.sources.utilizationReports.list({
|
|
11749
|
+
* // Optional. The filter request.
|
|
11750
|
+
* filter: 'placeholder-value',
|
|
11751
|
+
* // Optional. the order by fields for the result.
|
|
11752
|
+
* orderBy: 'placeholder-value',
|
|
11753
|
+
* // Optional. The maximum number of reports to return. The service may return fewer than this value. If unspecified, at most 500 reports will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
11754
|
+
* pageSize: 'placeholder-value',
|
|
11755
|
+
* // Required. A page token, received from a previous `ListUtilizationReports` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListUtilizationReports` must match the call that provided the page token.
|
|
11756
|
+
* pageToken: 'placeholder-value',
|
|
11757
|
+
* // Required. The Utilization Reports parent.
|
|
11758
|
+
* parent: 'projects/my-project/locations/my-location/sources/my-source',
|
|
11759
|
+
* // Optional. The level of details of each report. Defaults to BASIC.
|
|
11760
|
+
* view: 'placeholder-value',
|
|
11761
|
+
* });
|
|
11762
|
+
* console.log(res.data);
|
|
11763
|
+
*
|
|
11764
|
+
* // Example response
|
|
11765
|
+
* // {
|
|
11766
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
11767
|
+
* // "unreachable": [],
|
|
11768
|
+
* // "utilizationReports": []
|
|
11769
|
+
* // }
|
|
11770
|
+
* }
|
|
11771
|
+
*
|
|
11772
|
+
* main().catch(e => {
|
|
11773
|
+
* console.error(e);
|
|
11774
|
+
* throw e;
|
|
11775
|
+
* });
|
|
11776
|
+
*
|
|
11777
|
+
* ```
|
|
8371
11778
|
*
|
|
8372
11779
|
* @param params - Parameters for request
|
|
8373
11780
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8543,6 +11950,72 @@ export namespace vmmigration_v1 {
|
|
|
8543
11950
|
|
|
8544
11951
|
/**
|
|
8545
11952
|
* Creates a new TargetProject in a given project. NOTE: TargetProject is a global resource; hence the only supported value for location is `global`.
|
|
11953
|
+
* @example
|
|
11954
|
+
* ```js
|
|
11955
|
+
* // Before running the sample:
|
|
11956
|
+
* // - Enable the API at:
|
|
11957
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
11958
|
+
* // - Login into gcloud by running:
|
|
11959
|
+
* // ```sh
|
|
11960
|
+
* // $ gcloud auth application-default login
|
|
11961
|
+
* // ```
|
|
11962
|
+
* // - Install the npm module by running:
|
|
11963
|
+
* // ```sh
|
|
11964
|
+
* // $ npm install googleapis
|
|
11965
|
+
* // ```
|
|
11966
|
+
*
|
|
11967
|
+
* const {google} = require('googleapis');
|
|
11968
|
+
* const vmmigration = google.vmmigration('v1');
|
|
11969
|
+
*
|
|
11970
|
+
* async function main() {
|
|
11971
|
+
* const auth = new google.auth.GoogleAuth({
|
|
11972
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
11973
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
11974
|
+
* });
|
|
11975
|
+
*
|
|
11976
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
11977
|
+
* const authClient = await auth.getClient();
|
|
11978
|
+
* google.options({auth: authClient});
|
|
11979
|
+
*
|
|
11980
|
+
* // Do the magic
|
|
11981
|
+
* const res = await vmmigration.projects.locations.targetProjects.create({
|
|
11982
|
+
* // Required. The TargetProject's parent.
|
|
11983
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
11984
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
11985
|
+
* requestId: 'placeholder-value',
|
|
11986
|
+
* // Required. The target_project identifier.
|
|
11987
|
+
* targetProjectId: 'placeholder-value',
|
|
11988
|
+
*
|
|
11989
|
+
* // Request body metadata
|
|
11990
|
+
* requestBody: {
|
|
11991
|
+
* // request body parameters
|
|
11992
|
+
* // {
|
|
11993
|
+
* // "createTime": "my_createTime",
|
|
11994
|
+
* // "description": "my_description",
|
|
11995
|
+
* // "name": "my_name",
|
|
11996
|
+
* // "project": "my_project",
|
|
11997
|
+
* // "updateTime": "my_updateTime"
|
|
11998
|
+
* // }
|
|
11999
|
+
* },
|
|
12000
|
+
* });
|
|
12001
|
+
* console.log(res.data);
|
|
12002
|
+
*
|
|
12003
|
+
* // Example response
|
|
12004
|
+
* // {
|
|
12005
|
+
* // "done": false,
|
|
12006
|
+
* // "error": {},
|
|
12007
|
+
* // "metadata": {},
|
|
12008
|
+
* // "name": "my_name",
|
|
12009
|
+
* // "response": {}
|
|
12010
|
+
* // }
|
|
12011
|
+
* }
|
|
12012
|
+
*
|
|
12013
|
+
* main().catch(e => {
|
|
12014
|
+
* console.error(e);
|
|
12015
|
+
* throw e;
|
|
12016
|
+
* });
|
|
12017
|
+
*
|
|
12018
|
+
* ```
|
|
8546
12019
|
*
|
|
8547
12020
|
* @param params - Parameters for request
|
|
8548
12021
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8634,6 +12107,58 @@ export namespace vmmigration_v1 {
|
|
|
8634
12107
|
|
|
8635
12108
|
/**
|
|
8636
12109
|
* Deletes a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is `global`.
|
|
12110
|
+
* @example
|
|
12111
|
+
* ```js
|
|
12112
|
+
* // Before running the sample:
|
|
12113
|
+
* // - Enable the API at:
|
|
12114
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
12115
|
+
* // - Login into gcloud by running:
|
|
12116
|
+
* // ```sh
|
|
12117
|
+
* // $ gcloud auth application-default login
|
|
12118
|
+
* // ```
|
|
12119
|
+
* // - Install the npm module by running:
|
|
12120
|
+
* // ```sh
|
|
12121
|
+
* // $ npm install googleapis
|
|
12122
|
+
* // ```
|
|
12123
|
+
*
|
|
12124
|
+
* const {google} = require('googleapis');
|
|
12125
|
+
* const vmmigration = google.vmmigration('v1');
|
|
12126
|
+
*
|
|
12127
|
+
* async function main() {
|
|
12128
|
+
* const auth = new google.auth.GoogleAuth({
|
|
12129
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
12130
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
12131
|
+
* });
|
|
12132
|
+
*
|
|
12133
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
12134
|
+
* const authClient = await auth.getClient();
|
|
12135
|
+
* google.options({auth: authClient});
|
|
12136
|
+
*
|
|
12137
|
+
* // Do the magic
|
|
12138
|
+
* const res = await vmmigration.projects.locations.targetProjects.delete({
|
|
12139
|
+
* // Required. The TargetProject name.
|
|
12140
|
+
* name: 'projects/my-project/locations/my-location/targetProjects/my-targetProject',
|
|
12141
|
+
* // Optional. A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
12142
|
+
* requestId: 'placeholder-value',
|
|
12143
|
+
* });
|
|
12144
|
+
* console.log(res.data);
|
|
12145
|
+
*
|
|
12146
|
+
* // Example response
|
|
12147
|
+
* // {
|
|
12148
|
+
* // "done": false,
|
|
12149
|
+
* // "error": {},
|
|
12150
|
+
* // "metadata": {},
|
|
12151
|
+
* // "name": "my_name",
|
|
12152
|
+
* // "response": {}
|
|
12153
|
+
* // }
|
|
12154
|
+
* }
|
|
12155
|
+
*
|
|
12156
|
+
* main().catch(e => {
|
|
12157
|
+
* console.error(e);
|
|
12158
|
+
* throw e;
|
|
12159
|
+
* });
|
|
12160
|
+
*
|
|
12161
|
+
* ```
|
|
8637
12162
|
*
|
|
8638
12163
|
* @param params - Parameters for request
|
|
8639
12164
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8722,6 +12247,56 @@ export namespace vmmigration_v1 {
|
|
|
8722
12247
|
|
|
8723
12248
|
/**
|
|
8724
12249
|
* Gets details of a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is `global`.
|
|
12250
|
+
* @example
|
|
12251
|
+
* ```js
|
|
12252
|
+
* // Before running the sample:
|
|
12253
|
+
* // - Enable the API at:
|
|
12254
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
12255
|
+
* // - Login into gcloud by running:
|
|
12256
|
+
* // ```sh
|
|
12257
|
+
* // $ gcloud auth application-default login
|
|
12258
|
+
* // ```
|
|
12259
|
+
* // - Install the npm module by running:
|
|
12260
|
+
* // ```sh
|
|
12261
|
+
* // $ npm install googleapis
|
|
12262
|
+
* // ```
|
|
12263
|
+
*
|
|
12264
|
+
* const {google} = require('googleapis');
|
|
12265
|
+
* const vmmigration = google.vmmigration('v1');
|
|
12266
|
+
*
|
|
12267
|
+
* async function main() {
|
|
12268
|
+
* const auth = new google.auth.GoogleAuth({
|
|
12269
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
12270
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
12271
|
+
* });
|
|
12272
|
+
*
|
|
12273
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
12274
|
+
* const authClient = await auth.getClient();
|
|
12275
|
+
* google.options({auth: authClient});
|
|
12276
|
+
*
|
|
12277
|
+
* // Do the magic
|
|
12278
|
+
* const res = await vmmigration.projects.locations.targetProjects.get({
|
|
12279
|
+
* // Required. The TargetProject name.
|
|
12280
|
+
* name: 'projects/my-project/locations/my-location/targetProjects/my-targetProject',
|
|
12281
|
+
* });
|
|
12282
|
+
* console.log(res.data);
|
|
12283
|
+
*
|
|
12284
|
+
* // Example response
|
|
12285
|
+
* // {
|
|
12286
|
+
* // "createTime": "my_createTime",
|
|
12287
|
+
* // "description": "my_description",
|
|
12288
|
+
* // "name": "my_name",
|
|
12289
|
+
* // "project": "my_project",
|
|
12290
|
+
* // "updateTime": "my_updateTime"
|
|
12291
|
+
* // }
|
|
12292
|
+
* }
|
|
12293
|
+
*
|
|
12294
|
+
* main().catch(e => {
|
|
12295
|
+
* console.error(e);
|
|
12296
|
+
* throw e;
|
|
12297
|
+
* });
|
|
12298
|
+
*
|
|
12299
|
+
* ```
|
|
8725
12300
|
*
|
|
8726
12301
|
* @param params - Parameters for request
|
|
8727
12302
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8810,6 +12385,62 @@ export namespace vmmigration_v1 {
|
|
|
8810
12385
|
|
|
8811
12386
|
/**
|
|
8812
12387
|
* Lists TargetProjects in a given project. NOTE: TargetProject is a global resource; hence the only supported value for location is `global`.
|
|
12388
|
+
* @example
|
|
12389
|
+
* ```js
|
|
12390
|
+
* // Before running the sample:
|
|
12391
|
+
* // - Enable the API at:
|
|
12392
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
12393
|
+
* // - Login into gcloud by running:
|
|
12394
|
+
* // ```sh
|
|
12395
|
+
* // $ gcloud auth application-default login
|
|
12396
|
+
* // ```
|
|
12397
|
+
* // - Install the npm module by running:
|
|
12398
|
+
* // ```sh
|
|
12399
|
+
* // $ npm install googleapis
|
|
12400
|
+
* // ```
|
|
12401
|
+
*
|
|
12402
|
+
* const {google} = require('googleapis');
|
|
12403
|
+
* const vmmigration = google.vmmigration('v1');
|
|
12404
|
+
*
|
|
12405
|
+
* async function main() {
|
|
12406
|
+
* const auth = new google.auth.GoogleAuth({
|
|
12407
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
12408
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
12409
|
+
* });
|
|
12410
|
+
*
|
|
12411
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
12412
|
+
* const authClient = await auth.getClient();
|
|
12413
|
+
* google.options({auth: authClient});
|
|
12414
|
+
*
|
|
12415
|
+
* // Do the magic
|
|
12416
|
+
* const res = await vmmigration.projects.locations.targetProjects.list({
|
|
12417
|
+
* // Optional. The filter request.
|
|
12418
|
+
* filter: 'placeholder-value',
|
|
12419
|
+
* // Optional. the order by fields for the result.
|
|
12420
|
+
* orderBy: 'placeholder-value',
|
|
12421
|
+
* // Optional. The maximum number of targets to return. The service may return fewer than this value. If unspecified, at most 500 targets will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
|
|
12422
|
+
* pageSize: 'placeholder-value',
|
|
12423
|
+
* // Required. A page token, received from a previous `ListTargets` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListTargets` must match the call that provided the page token.
|
|
12424
|
+
* pageToken: 'placeholder-value',
|
|
12425
|
+
* // Required. The parent, which owns this collection of targets.
|
|
12426
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
12427
|
+
* });
|
|
12428
|
+
* console.log(res.data);
|
|
12429
|
+
*
|
|
12430
|
+
* // Example response
|
|
12431
|
+
* // {
|
|
12432
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
12433
|
+
* // "targetProjects": [],
|
|
12434
|
+
* // "unreachable": []
|
|
12435
|
+
* // }
|
|
12436
|
+
* }
|
|
12437
|
+
*
|
|
12438
|
+
* main().catch(e => {
|
|
12439
|
+
* console.error(e);
|
|
12440
|
+
* throw e;
|
|
12441
|
+
* });
|
|
12442
|
+
*
|
|
12443
|
+
* ```
|
|
8813
12444
|
*
|
|
8814
12445
|
* @param params - Parameters for request
|
|
8815
12446
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -8905,6 +12536,72 @@ export namespace vmmigration_v1 {
|
|
|
8905
12536
|
|
|
8906
12537
|
/**
|
|
8907
12538
|
* Updates the parameters of a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is `global`.
|
|
12539
|
+
* @example
|
|
12540
|
+
* ```js
|
|
12541
|
+
* // Before running the sample:
|
|
12542
|
+
* // - Enable the API at:
|
|
12543
|
+
* // https://console.developers.google.com/apis/api/vmmigration.googleapis.com
|
|
12544
|
+
* // - Login into gcloud by running:
|
|
12545
|
+
* // ```sh
|
|
12546
|
+
* // $ gcloud auth application-default login
|
|
12547
|
+
* // ```
|
|
12548
|
+
* // - Install the npm module by running:
|
|
12549
|
+
* // ```sh
|
|
12550
|
+
* // $ npm install googleapis
|
|
12551
|
+
* // ```
|
|
12552
|
+
*
|
|
12553
|
+
* const {google} = require('googleapis');
|
|
12554
|
+
* const vmmigration = google.vmmigration('v1');
|
|
12555
|
+
*
|
|
12556
|
+
* async function main() {
|
|
12557
|
+
* const auth = new google.auth.GoogleAuth({
|
|
12558
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
12559
|
+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
|
|
12560
|
+
* });
|
|
12561
|
+
*
|
|
12562
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
12563
|
+
* const authClient = await auth.getClient();
|
|
12564
|
+
* google.options({auth: authClient});
|
|
12565
|
+
*
|
|
12566
|
+
* // Do the magic
|
|
12567
|
+
* const res = await vmmigration.projects.locations.targetProjects.patch({
|
|
12568
|
+
* // Output only. The name of the target project.
|
|
12569
|
+
* name: 'projects/my-project/locations/my-location/targetProjects/my-targetProject',
|
|
12570
|
+
* // A request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
|
|
12571
|
+
* requestId: 'placeholder-value',
|
|
12572
|
+
* // Field mask is used to specify the fields to be overwritten in the TargetProject resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
|
|
12573
|
+
* updateMask: 'placeholder-value',
|
|
12574
|
+
*
|
|
12575
|
+
* // Request body metadata
|
|
12576
|
+
* requestBody: {
|
|
12577
|
+
* // request body parameters
|
|
12578
|
+
* // {
|
|
12579
|
+
* // "createTime": "my_createTime",
|
|
12580
|
+
* // "description": "my_description",
|
|
12581
|
+
* // "name": "my_name",
|
|
12582
|
+
* // "project": "my_project",
|
|
12583
|
+
* // "updateTime": "my_updateTime"
|
|
12584
|
+
* // }
|
|
12585
|
+
* },
|
|
12586
|
+
* });
|
|
12587
|
+
* console.log(res.data);
|
|
12588
|
+
*
|
|
12589
|
+
* // Example response
|
|
12590
|
+
* // {
|
|
12591
|
+
* // "done": false,
|
|
12592
|
+
* // "error": {},
|
|
12593
|
+
* // "metadata": {},
|
|
12594
|
+
* // "name": "my_name",
|
|
12595
|
+
* // "response": {}
|
|
12596
|
+
* // }
|
|
12597
|
+
* }
|
|
12598
|
+
*
|
|
12599
|
+
* main().catch(e => {
|
|
12600
|
+
* console.error(e);
|
|
12601
|
+
* throw e;
|
|
12602
|
+
* });
|
|
12603
|
+
*
|
|
12604
|
+
* ```
|
|
8908
12605
|
*
|
|
8909
12606
|
* @param params - Parameters for request
|
|
8910
12607
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|