Method list

Retrieves the list of placement groups in the specified folder.

HTTP request

GET https://compute.api.cloud.yandex.net/compute/v1/placementGroups

Query parameters

Parameter Description
folderId ID of the folder to list placement groups in. To get the folder ID make a list request.
pageSize The maximum number of results per page to return. If the number of available results is larger than pageSize, the service returns a nextPageToken that can be used to get the next page of results in subsequent list requests.
pageToken Page token. To get the next page of results, set pageToken to the nextPageToken returned by a previous list request.
filter A filter expression that filters resources listed in the response. Currently you can use filtering only on the PlacementGroup.name field.

Response

HTTP Code: 200 - OK

{
  "placementGroups": [
    {
      "id": "string",
      "folderId": "string",
      "createdAt": "string",
      "name": "string",
      "description": "string",
      "labels": "object",
      "spreadPlacementStrategy": {}
    }
  ],
  "nextPageToken": "string"
}
Field Description
placementGroups[] object

Lists placement groups in the specified folder.

placementGroups[].
id
string

ID of the placement group. Generated at creation time.

placementGroups[].
folderId
string

ID of the folder that the placement group belongs to.

placementGroups[].
createdAt
string (date-time)

Creation timestamp.

String in RFC3339 text format.

placementGroups[].
name
string

Name of the placement group. The name is unique within the folder.

placementGroups[].
description
string

Description of the placement group. 0-256 characters long.

placementGroups[].
labels
object

Placement group labels as key:value pairs.

placementGroups[].
spreadPlacementStrategy
object
Anti-affinity placement strategy (spread). Instances are distributed over distinct failure domains.

This is an empty structure that must be passed to explicitly specify the required placement strategy.

nextPageToken string

Token for getting the next page of the list. If the number of results is greater than the specified pageSize, use next_page_token as the value for the pageToken parameter in the next list request.

Each subsequent page will have its own next_page_token to continue paging through the results.