John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 1 | <html><body> |
| 2 | <style> |
| 3 | |
| 4 | body, h1, h2, h3, div, span, p, pre, a { |
| 5 | margin: 0; |
| 6 | padding: 0; |
| 7 | border: 0; |
| 8 | font-weight: inherit; |
| 9 | font-style: inherit; |
| 10 | font-size: 100%; |
| 11 | font-family: inherit; |
| 12 | vertical-align: baseline; |
| 13 | } |
| 14 | |
| 15 | body { |
| 16 | font-size: 13px; |
| 17 | padding: 1em; |
| 18 | } |
| 19 | |
| 20 | h1 { |
| 21 | font-size: 26px; |
| 22 | margin-bottom: 1em; |
| 23 | } |
| 24 | |
| 25 | h2 { |
| 26 | font-size: 24px; |
| 27 | margin-bottom: 1em; |
| 28 | } |
| 29 | |
| 30 | h3 { |
| 31 | font-size: 20px; |
| 32 | margin-bottom: 1em; |
| 33 | margin-top: 1em; |
| 34 | } |
| 35 | |
| 36 | pre, code { |
| 37 | line-height: 1.5; |
| 38 | font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; |
| 39 | } |
| 40 | |
| 41 | pre { |
| 42 | margin-top: 0.5em; |
| 43 | } |
| 44 | |
| 45 | h1, h2, h3, p { |
| 46 | font-family: Arial, sans serif; |
| 47 | } |
| 48 | |
| 49 | h1, h2, h3 { |
| 50 | border-bottom: solid #CCC 1px; |
| 51 | } |
| 52 | |
| 53 | .toc_element { |
| 54 | margin-top: 0.5em; |
| 55 | } |
| 56 | |
| 57 | .firstline { |
| 58 | margin-left: 2 em; |
| 59 | } |
| 60 | |
| 61 | .method { |
| 62 | margin-top: 1em; |
| 63 | border: solid 1px #CCC; |
| 64 | padding: 1em; |
| 65 | background: #EEE; |
| 66 | } |
| 67 | |
| 68 | .details { |
| 69 | font-weight: bold; |
| 70 | font-size: 14px; |
| 71 | } |
| 72 | |
| 73 | </style> |
| 74 | |
| 75 | <h1><a href="compute_v1.html">Compute Engine API</a> . <a href="compute_v1.disks.html">disks</a></h1> |
| 76 | <h2>Instance Methods</h2> |
| 77 | <p class="toc_element"> |
| 78 | <code><a href="#aggregatedList">aggregatedList(project, maxResults=None, pageToken=None, filter=None)</a></code></p> |
| 79 | <p class="firstline">Retrieves the list of disks grouped by scope.</p> |
| 80 | <p class="toc_element"> |
| 81 | <code><a href="#aggregatedList_next">aggregatedList_next(previous_request, previous_response)</a></code></p> |
| 82 | <p class="firstline">Retrieves the next page of results.</p> |
| 83 | <p class="toc_element"> |
| 84 | <code><a href="#createSnapshot">createSnapshot(project, zone, disk, body)</a></code></p> |
| 85 | <p class="firstline">A description of how to use this function</p> |
| 86 | <p class="toc_element"> |
| 87 | <code><a href="#delete">delete(project, zone, disk)</a></code></p> |
| 88 | <p class="firstline">Deletes the specified persistent disk resource.</p> |
| 89 | <p class="toc_element"> |
| 90 | <code><a href="#get">get(project, zone, disk)</a></code></p> |
| 91 | <p class="firstline">Returns the specified persistent disk resource.</p> |
| 92 | <p class="toc_element"> |
| 93 | <code><a href="#insert">insert(project, zone, body, sourceImage=None)</a></code></p> |
| 94 | <p class="firstline">Creates a persistent disk resource in the specified project using the data included in the request.</p> |
| 95 | <p class="toc_element"> |
| 96 | <code><a href="#list">list(project, zone, maxResults=None, pageToken=None, filter=None)</a></code></p> |
| 97 | <p class="firstline">Retrieves the list of persistent disk resources contained within the specified zone.</p> |
| 98 | <p class="toc_element"> |
| 99 | <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> |
| 100 | <p class="firstline">Retrieves the next page of results.</p> |
| 101 | <h3>Method Details</h3> |
| 102 | <div class="method"> |
| 103 | <code class="details" id="aggregatedList">aggregatedList(project, maxResults=None, pageToken=None, filter=None)</code> |
| 104 | <pre>Retrieves the list of disks grouped by scope. |
| 105 | |
| 106 | Args: |
| 107 | project: string, Name of the project scoping this request. (required) |
| 108 | maxResults: integer, Optional. Maximum count of results to be returned. Maximum value is 500 and default value is 500. |
| 109 | pageToken: string, Optional. Tag returned by a previous list request truncated by maxResults. Used to continue a previous list request. |
| 110 | filter: string, Optional. Filter expression for filtering listed resources. |
| 111 | |
| 112 | Returns: |
| 113 | An object of the form: |
| 114 | |
| 115 | { |
| 116 | "nextPageToken": "A String", # A token used to continue a truncated list request (output only). |
| 117 | "items": { # A map of scoped disk lists. |
| 118 | "a_key": { # Name of the scope containing this set of disks. |
| 119 | "disks": [ # List of disks contained in this scope. |
| 120 | { # A persistent disk resource. |
| 121 | "status": "A String", # The status of disk creation (output only). |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 122 | "sourceSnapshot": "A String", # The source snapshot used to create this disk. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 123 | "kind": "compute#disk", # Type of the resource. |
| 124 | "description": "A String", # An optional textual description of the resource; provided by the client when the resource is created. |
| 125 | "sizeGb": "A String", # Size of the persistent disk, specified in GB. This parameter is optional when creating a disk from a disk image or a snapshot, otherwise it is required. |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 126 | "type": "A String", # URL of the disk type resource describing which disk type to use to create the disk; provided by the client when the disk is created. |
| 127 | "options": "A String", # Internal use only. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 128 | "sourceImageId": "A String", # The 'id' value of the image used to create this disk. This value may be used to determine whether the disk was created from the current or a previous instance of a given image. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 129 | "sourceSnapshotId": "A String", # The 'id' value of the snapshot used to create this disk. This value may be used to determine whether the disk was created from the current or a previous instance of a given disk snapshot. |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 130 | "sourceImage": "A String", # The source image used to create this disk. |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 131 | "licenses": [ # Public visible licenses. |
| 132 | "A String", |
| 133 | ], |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 134 | "zone": "A String", # URL of the zone where the disk resides (output only). |
| 135 | "creationTimestamp": "A String", # Creation timestamp in RFC3339 text format (output only). |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 136 | "id": "A String", # Unique identifier for the resource; defined by the server (output only). |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 137 | "selfLink": "A String", # Server defined URL for the resource (output only). |
| 138 | "name": "A String", # Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. |
| 139 | }, |
| 140 | ], |
| 141 | "warning": { # Informational warning which replaces the list of disks when the list is empty. |
| 142 | "message": "A String", # Optional human-readable details for this warning. |
| 143 | "code": "A String", # The warning type identifier for this warning. |
| 144 | "data": [ # Metadata for this warning in 'key: value' format. |
| 145 | { |
| 146 | "value": "A String", # A warning data value corresponding to the key. |
| 147 | "key": "A String", # A key for the warning data. |
| 148 | }, |
| 149 | ], |
| 150 | }, |
| 151 | }, |
| 152 | }, |
| 153 | "kind": "compute#diskAggregatedList", # Type of resource. |
| 154 | "id": "A String", # Unique identifier for the resource; defined by the server (output only). |
| 155 | "selfLink": "A String", # Server defined URL for this resource (output only). |
| 156 | }</pre> |
| 157 | </div> |
| 158 | |
| 159 | <div class="method"> |
| 160 | <code class="details" id="aggregatedList_next">aggregatedList_next(previous_request, previous_response)</code> |
| 161 | <pre>Retrieves the next page of results. |
| 162 | |
| 163 | Args: |
| 164 | previous_request: The request for the previous page. (required) |
| 165 | previous_response: The response from the request for the previous page. (required) |
| 166 | |
| 167 | Returns: |
| 168 | A request object that you can call 'execute()' on to request the next |
| 169 | page. Returns None if there are no more items in the collection. |
| 170 | </pre> |
| 171 | </div> |
| 172 | |
| 173 | <div class="method"> |
| 174 | <code class="details" id="createSnapshot">createSnapshot(project, zone, disk, body)</code> |
| 175 | <pre>A description of how to use this function |
| 176 | |
| 177 | Args: |
| 178 | project: string, Name of the project scoping this request. (required) |
| 179 | zone: string, Name of the zone scoping this request. (required) |
| 180 | disk: string, Name of the persistent disk resource to snapshot. (required) |
| 181 | body: object, The request body. (required) |
| 182 | The object takes the form of: |
| 183 | |
| 184 | { # A persistent disk snapshot resource. |
| 185 | "status": "A String", # The status of the persistent disk snapshot (output only). |
| 186 | "kind": "compute#snapshot", # Type of the resource. |
| 187 | "storageBytes": "A String", # A size of the the storage used by the snapshot. As snapshots share storage this number is expected to change with snapshot creation/deletion. |
| 188 | "description": "A String", # An optional textual description of the resource; provided by the client when the resource is created. |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 189 | "sourceDisk": "A String", # The source disk used to create this snapshot. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 190 | "storageBytesStatus": "A String", # An indicator whether storageBytes is in a stable state, or it is being adjusted as a result of shared storage reallocation. |
| 191 | "sourceDiskId": "A String", # The 'id' value of the disk used to create this snapshot. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given disk name. |
| 192 | "diskSizeGb": "A String", # Size of the persistent disk snapshot, specified in GB (output only). |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 193 | "licenses": [ # Public visible licenses. |
| 194 | "A String", |
| 195 | ], |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 196 | "creationTimestamp": "A String", # Creation timestamp in RFC3339 text format (output only). |
| 197 | "id": "A String", # Unique identifier for the resource; defined by the server (output only). |
| 198 | "selfLink": "A String", # Server defined URL for the resource (output only). |
| 199 | "name": "A String", # Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. |
| 200 | } |
| 201 | |
| 202 | |
| 203 | Returns: |
| 204 | An object of the form: |
| 205 | |
| 206 | { # An operation resource, used to manage asynchronous API requests. |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 207 | "targetId": "A String", # [Output Only] Unique target id which identifies a particular incarnation of the target. |
| 208 | "clientOperationId": "A String", |
| 209 | "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format (output only). |
| 210 | "id": "A String", # [Output Only] Unique identifier for the resource; defined by the server. |
| 211 | "zone": "A String", # [Output Only] URL of the zone where the operation resides (output only). |
| 212 | "operationType": "A String", |
| 213 | "httpErrorMessage": "A String", |
| 214 | "progress": 42, |
| 215 | "httpErrorStatusCode": 42, |
| 216 | "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. |
| 217 | "status": "A String", # [Output Only] Status of the operation. Can be one of the following: "PENDING", "RUNNING", or "DONE". |
| 218 | "insertTime": "A String", # [Output Only] The time that this operation was requested. This is in RFC 3339 format. |
| 219 | "warnings": [ |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 220 | { |
| 221 | "message": "A String", # Optional human-readable details for this warning. |
| 222 | "code": "A String", # The warning type identifier for this warning. |
| 223 | "data": [ # Metadata for this warning in 'key: value' format. |
| 224 | { |
| 225 | "value": "A String", # A warning data value corresponding to the key. |
| 226 | "key": "A String", # A key for the warning data. |
| 227 | }, |
| 228 | ], |
| 229 | }, |
| 230 | ], |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 231 | "user": "A String", |
| 232 | "startTime": "A String", # [Output Only] The time that this operation was started by the server. This is in RFC 3339 format. |
| 233 | "kind": "compute#operation", # [Output Only] Type of the resource. Always kind#operation for Operation resources. |
| 234 | "name": "A String", # [Output Only] Name of the resource (output only). |
| 235 | "region": "A String", # [Output Only] URL of the region where the operation resides (output only). |
| 236 | "error": { # [Output Only] If errors occurred during processing of this operation, this field will be populated. |
| 237 | "errors": [ # [Output Only] The array of errors encountered while processing this operation. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 238 | { |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 239 | "message": "A String", # [Output Only] An optional, human-readable error message. |
| 240 | "code": "A String", # [Output Only] The error type identifier for this error. |
| 241 | "location": "A String", # [Output Only] Indicates the field in the request which caused the error. This property is optional. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 242 | }, |
| 243 | ], |
| 244 | }, |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 245 | "endTime": "A String", |
| 246 | "selfLink": "A String", # [Output Only] Server defined URL for the resource. |
| 247 | "targetLink": "A String", # [Output Only] URL of the resource the operation is mutating (output only). |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 248 | }</pre> |
| 249 | </div> |
| 250 | |
| 251 | <div class="method"> |
| 252 | <code class="details" id="delete">delete(project, zone, disk)</code> |
| 253 | <pre>Deletes the specified persistent disk resource. |
| 254 | |
| 255 | Args: |
| 256 | project: string, Name of the project scoping this request. (required) |
| 257 | zone: string, Name of the zone scoping this request. (required) |
| 258 | disk: string, Name of the persistent disk resource to delete. (required) |
| 259 | |
| 260 | Returns: |
| 261 | An object of the form: |
| 262 | |
| 263 | { # An operation resource, used to manage asynchronous API requests. |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 264 | "targetId": "A String", # [Output Only] Unique target id which identifies a particular incarnation of the target. |
| 265 | "clientOperationId": "A String", |
| 266 | "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format (output only). |
| 267 | "id": "A String", # [Output Only] Unique identifier for the resource; defined by the server. |
| 268 | "zone": "A String", # [Output Only] URL of the zone where the operation resides (output only). |
| 269 | "operationType": "A String", |
| 270 | "httpErrorMessage": "A String", |
| 271 | "progress": 42, |
| 272 | "httpErrorStatusCode": 42, |
| 273 | "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. |
| 274 | "status": "A String", # [Output Only] Status of the operation. Can be one of the following: "PENDING", "RUNNING", or "DONE". |
| 275 | "insertTime": "A String", # [Output Only] The time that this operation was requested. This is in RFC 3339 format. |
| 276 | "warnings": [ |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 277 | { |
| 278 | "message": "A String", # Optional human-readable details for this warning. |
| 279 | "code": "A String", # The warning type identifier for this warning. |
| 280 | "data": [ # Metadata for this warning in 'key: value' format. |
| 281 | { |
| 282 | "value": "A String", # A warning data value corresponding to the key. |
| 283 | "key": "A String", # A key for the warning data. |
| 284 | }, |
| 285 | ], |
| 286 | }, |
| 287 | ], |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 288 | "user": "A String", |
| 289 | "startTime": "A String", # [Output Only] The time that this operation was started by the server. This is in RFC 3339 format. |
| 290 | "kind": "compute#operation", # [Output Only] Type of the resource. Always kind#operation for Operation resources. |
| 291 | "name": "A String", # [Output Only] Name of the resource (output only). |
| 292 | "region": "A String", # [Output Only] URL of the region where the operation resides (output only). |
| 293 | "error": { # [Output Only] If errors occurred during processing of this operation, this field will be populated. |
| 294 | "errors": [ # [Output Only] The array of errors encountered while processing this operation. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 295 | { |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 296 | "message": "A String", # [Output Only] An optional, human-readable error message. |
| 297 | "code": "A String", # [Output Only] The error type identifier for this error. |
| 298 | "location": "A String", # [Output Only] Indicates the field in the request which caused the error. This property is optional. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 299 | }, |
| 300 | ], |
| 301 | }, |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 302 | "endTime": "A String", |
| 303 | "selfLink": "A String", # [Output Only] Server defined URL for the resource. |
| 304 | "targetLink": "A String", # [Output Only] URL of the resource the operation is mutating (output only). |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 305 | }</pre> |
| 306 | </div> |
| 307 | |
| 308 | <div class="method"> |
| 309 | <code class="details" id="get">get(project, zone, disk)</code> |
| 310 | <pre>Returns the specified persistent disk resource. |
| 311 | |
| 312 | Args: |
| 313 | project: string, Name of the project scoping this request. (required) |
| 314 | zone: string, Name of the zone scoping this request. (required) |
| 315 | disk: string, Name of the persistent disk resource to return. (required) |
| 316 | |
| 317 | Returns: |
| 318 | An object of the form: |
| 319 | |
| 320 | { # A persistent disk resource. |
| 321 | "status": "A String", # The status of disk creation (output only). |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 322 | "sourceSnapshot": "A String", # The source snapshot used to create this disk. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 323 | "kind": "compute#disk", # Type of the resource. |
| 324 | "description": "A String", # An optional textual description of the resource; provided by the client when the resource is created. |
| 325 | "sizeGb": "A String", # Size of the persistent disk, specified in GB. This parameter is optional when creating a disk from a disk image or a snapshot, otherwise it is required. |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 326 | "type": "A String", # URL of the disk type resource describing which disk type to use to create the disk; provided by the client when the disk is created. |
| 327 | "options": "A String", # Internal use only. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 328 | "sourceImageId": "A String", # The 'id' value of the image used to create this disk. This value may be used to determine whether the disk was created from the current or a previous instance of a given image. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 329 | "sourceSnapshotId": "A String", # The 'id' value of the snapshot used to create this disk. This value may be used to determine whether the disk was created from the current or a previous instance of a given disk snapshot. |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 330 | "sourceImage": "A String", # The source image used to create this disk. |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 331 | "licenses": [ # Public visible licenses. |
| 332 | "A String", |
| 333 | ], |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 334 | "zone": "A String", # URL of the zone where the disk resides (output only). |
| 335 | "creationTimestamp": "A String", # Creation timestamp in RFC3339 text format (output only). |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 336 | "id": "A String", # Unique identifier for the resource; defined by the server (output only). |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 337 | "selfLink": "A String", # Server defined URL for the resource (output only). |
| 338 | "name": "A String", # Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. |
| 339 | }</pre> |
| 340 | </div> |
| 341 | |
| 342 | <div class="method"> |
| 343 | <code class="details" id="insert">insert(project, zone, body, sourceImage=None)</code> |
| 344 | <pre>Creates a persistent disk resource in the specified project using the data included in the request. |
| 345 | |
| 346 | Args: |
| 347 | project: string, Name of the project scoping this request. (required) |
| 348 | zone: string, Name of the zone scoping this request. (required) |
| 349 | body: object, The request body. (required) |
| 350 | The object takes the form of: |
| 351 | |
| 352 | { # A persistent disk resource. |
| 353 | "status": "A String", # The status of disk creation (output only). |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 354 | "sourceSnapshot": "A String", # The source snapshot used to create this disk. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 355 | "kind": "compute#disk", # Type of the resource. |
| 356 | "description": "A String", # An optional textual description of the resource; provided by the client when the resource is created. |
| 357 | "sizeGb": "A String", # Size of the persistent disk, specified in GB. This parameter is optional when creating a disk from a disk image or a snapshot, otherwise it is required. |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 358 | "type": "A String", # URL of the disk type resource describing which disk type to use to create the disk; provided by the client when the disk is created. |
| 359 | "options": "A String", # Internal use only. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 360 | "sourceImageId": "A String", # The 'id' value of the image used to create this disk. This value may be used to determine whether the disk was created from the current or a previous instance of a given image. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 361 | "sourceSnapshotId": "A String", # The 'id' value of the snapshot used to create this disk. This value may be used to determine whether the disk was created from the current or a previous instance of a given disk snapshot. |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 362 | "sourceImage": "A String", # The source image used to create this disk. |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 363 | "licenses": [ # Public visible licenses. |
| 364 | "A String", |
| 365 | ], |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 366 | "zone": "A String", # URL of the zone where the disk resides (output only). |
| 367 | "creationTimestamp": "A String", # Creation timestamp in RFC3339 text format (output only). |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 368 | "id": "A String", # Unique identifier for the resource; defined by the server (output only). |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 369 | "selfLink": "A String", # Server defined URL for the resource (output only). |
| 370 | "name": "A String", # Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. |
| 371 | } |
| 372 | |
| 373 | sourceImage: string, Optional. Source image to restore onto a disk. |
| 374 | |
| 375 | Returns: |
| 376 | An object of the form: |
| 377 | |
| 378 | { # An operation resource, used to manage asynchronous API requests. |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 379 | "targetId": "A String", # [Output Only] Unique target id which identifies a particular incarnation of the target. |
| 380 | "clientOperationId": "A String", |
| 381 | "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format (output only). |
| 382 | "id": "A String", # [Output Only] Unique identifier for the resource; defined by the server. |
| 383 | "zone": "A String", # [Output Only] URL of the zone where the operation resides (output only). |
| 384 | "operationType": "A String", |
| 385 | "httpErrorMessage": "A String", |
| 386 | "progress": 42, |
| 387 | "httpErrorStatusCode": 42, |
| 388 | "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. |
| 389 | "status": "A String", # [Output Only] Status of the operation. Can be one of the following: "PENDING", "RUNNING", or "DONE". |
| 390 | "insertTime": "A String", # [Output Only] The time that this operation was requested. This is in RFC 3339 format. |
| 391 | "warnings": [ |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 392 | { |
| 393 | "message": "A String", # Optional human-readable details for this warning. |
| 394 | "code": "A String", # The warning type identifier for this warning. |
| 395 | "data": [ # Metadata for this warning in 'key: value' format. |
| 396 | { |
| 397 | "value": "A String", # A warning data value corresponding to the key. |
| 398 | "key": "A String", # A key for the warning data. |
| 399 | }, |
| 400 | ], |
| 401 | }, |
| 402 | ], |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 403 | "user": "A String", |
| 404 | "startTime": "A String", # [Output Only] The time that this operation was started by the server. This is in RFC 3339 format. |
| 405 | "kind": "compute#operation", # [Output Only] Type of the resource. Always kind#operation for Operation resources. |
| 406 | "name": "A String", # [Output Only] Name of the resource (output only). |
| 407 | "region": "A String", # [Output Only] URL of the region where the operation resides (output only). |
| 408 | "error": { # [Output Only] If errors occurred during processing of this operation, this field will be populated. |
| 409 | "errors": [ # [Output Only] The array of errors encountered while processing this operation. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 410 | { |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 411 | "message": "A String", # [Output Only] An optional, human-readable error message. |
| 412 | "code": "A String", # [Output Only] The error type identifier for this error. |
| 413 | "location": "A String", # [Output Only] Indicates the field in the request which caused the error. This property is optional. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 414 | }, |
| 415 | ], |
| 416 | }, |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 417 | "endTime": "A String", |
| 418 | "selfLink": "A String", # [Output Only] Server defined URL for the resource. |
| 419 | "targetLink": "A String", # [Output Only] URL of the resource the operation is mutating (output only). |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 420 | }</pre> |
| 421 | </div> |
| 422 | |
| 423 | <div class="method"> |
| 424 | <code class="details" id="list">list(project, zone, maxResults=None, pageToken=None, filter=None)</code> |
| 425 | <pre>Retrieves the list of persistent disk resources contained within the specified zone. |
| 426 | |
| 427 | Args: |
| 428 | project: string, Name of the project scoping this request. (required) |
| 429 | zone: string, Name of the zone scoping this request. (required) |
| 430 | maxResults: integer, Optional. Maximum count of results to be returned. Maximum value is 500 and default value is 500. |
| 431 | pageToken: string, Optional. Tag returned by a previous list request truncated by maxResults. Used to continue a previous list request. |
| 432 | filter: string, Optional. Filter expression for filtering listed resources. |
| 433 | |
| 434 | Returns: |
| 435 | An object of the form: |
| 436 | |
| 437 | { # Contains a list of persistent disk resources. |
| 438 | "nextPageToken": "A String", # A token used to continue a truncated list request (output only). |
Craig Citro | e633be1 | 2015-03-02 13:40:36 -0800 | [diff] [blame^] | 439 | "items": [ # A list of Disk resources. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 440 | { # A persistent disk resource. |
| 441 | "status": "A String", # The status of disk creation (output only). |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 442 | "sourceSnapshot": "A String", # The source snapshot used to create this disk. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 443 | "kind": "compute#disk", # Type of the resource. |
| 444 | "description": "A String", # An optional textual description of the resource; provided by the client when the resource is created. |
| 445 | "sizeGb": "A String", # Size of the persistent disk, specified in GB. This parameter is optional when creating a disk from a disk image or a snapshot, otherwise it is required. |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 446 | "type": "A String", # URL of the disk type resource describing which disk type to use to create the disk; provided by the client when the disk is created. |
| 447 | "options": "A String", # Internal use only. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 448 | "sourceImageId": "A String", # The 'id' value of the image used to create this disk. This value may be used to determine whether the disk was created from the current or a previous instance of a given image. |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 449 | "sourceSnapshotId": "A String", # The 'id' value of the snapshot used to create this disk. This value may be used to determine whether the disk was created from the current or a previous instance of a given disk snapshot. |
Craig Citro | 0e5b9bf | 2014-10-15 10:26:14 -0700 | [diff] [blame] | 450 | "sourceImage": "A String", # The source image used to create this disk. |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 451 | "licenses": [ # Public visible licenses. |
| 452 | "A String", |
| 453 | ], |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 454 | "zone": "A String", # URL of the zone where the disk resides (output only). |
| 455 | "creationTimestamp": "A String", # Creation timestamp in RFC3339 text format (output only). |
Craig Citro | 065b530 | 2014-08-14 00:47:23 -0700 | [diff] [blame] | 456 | "id": "A String", # Unique identifier for the resource; defined by the server (output only). |
John Asmuth | 614db98 | 2014-04-24 15:46:26 -0400 | [diff] [blame] | 457 | "selfLink": "A String", # Server defined URL for the resource (output only). |
| 458 | "name": "A String", # Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. |
| 459 | }, |
| 460 | ], |
| 461 | "kind": "compute#diskList", # Type of resource. |
| 462 | "id": "A String", # Unique identifier for the resource; defined by the server (output only). |
| 463 | "selfLink": "A String", # Server defined URL for this resource (output only). |
| 464 | }</pre> |
| 465 | </div> |
| 466 | |
| 467 | <div class="method"> |
| 468 | <code class="details" id="list_next">list_next(previous_request, previous_response)</code> |
| 469 | <pre>Retrieves the next page of results. |
| 470 | |
| 471 | Args: |
| 472 | previous_request: The request for the previous page. (required) |
| 473 | previous_response: The response from the request for the previous page. (required) |
| 474 | |
| 475 | Returns: |
| 476 | A request object that you can call 'execute()' on to request the next |
| 477 | page. Returns None if there are no more items in the collection. |
| 478 | </pre> |
| 479 | </div> |
| 480 | |
| 481 | </body></html> |