< Back
Get-CBGroup
Post
NAME Get-CBGroup
SYNOPSIS
Gets CloudBolt groups.
SYNTAX
Get-CBGroup -Session <Object> [-PageSize <Int32>] [<CommonParameters>]
Get-CBGroup -Session <Object> -ID <Int32> [<CommonParameters>]
DESCRIPTION
The `Get-CBGroup` function gets all groups from a CloudBolt instance. To get a specific group, pass its ID to the
`ID` parameter.
By default, CloudBolt pages the list of groups. This function automatically handles the paging for you and returns
all group. You can control how big each page is with the `PageSize` parameter. `Get-CBGroup` will make as many
HTTP requests as there are pages (i.e. it will return all groups).
PARAMETERS
-Session <Object>
The session/connecton to the CloudBolt instance to use. Use `New-CBSession` to create a session object.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-ID <Int32>
The ID of the group to get.
Required? true
Position? named
Default value 0
Accept pipeline input? true (ByValue, ByPropertyName)
Accept wildcard characters? false
-PageSize <Int32>
The page size. CloudBolt pages all lists of objects. The `Get-CBEnvironment` function will make an HTTP
request for every page of results so that all environments get returned. The default page size is 10.
Required? false
Position? named
Default value $defaultPageSize
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Get-CBGroup -Session $session
Demonstrates how to get all groups from CloudBolt.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Get-CBGroup -Session $session -PageSize ([int16]::MaxValue)
Demonstrates how to increase the number of results per request to the CloudBolt API. The larger the number, the
greater the strain on CloudBolt but the fewer HTTP requests will be made.
-------------------------- EXAMPLE 3 --------------------------
PS C:\\>Get-CBGroup -Session $session -ID 1
Demonstrates how to get a specific group from CloudBolt.
RELATED LINKS
SYNOPSIS
Gets CloudBolt groups.
SYNTAX
Get-CBGroup -Session <Object> [-PageSize <Int32>] [<CommonParameters>]
Get-CBGroup -Session <Object> -ID <Int32> [<CommonParameters>]
DESCRIPTION
The `Get-CBGroup` function gets all groups from a CloudBolt instance. To get a specific group, pass its ID to the
`ID` parameter.
By default, CloudBolt pages the list of groups. This function automatically handles the paging for you and returns
all group. You can control how big each page is with the `PageSize` parameter. `Get-CBGroup` will make as many
HTTP requests as there are pages (i.e. it will return all groups).
PARAMETERS
-Session <Object>
The session/connecton to the CloudBolt instance to use. Use `New-CBSession` to create a session object.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-ID <Int32>
The ID of the group to get.
Required? true
Position? named
Default value 0
Accept pipeline input? true (ByValue, ByPropertyName)
Accept wildcard characters? false
-PageSize <Int32>
The page size. CloudBolt pages all lists of objects. The `Get-CBEnvironment` function will make an HTTP
request for every page of results so that all environments get returned. The default page size is 10.
Required? false
Position? named
Default value $defaultPageSize
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Get-CBGroup -Session $session
Demonstrates how to get all groups from CloudBolt.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Get-CBGroup -Session $session -PageSize ([int16]::MaxValue)
Demonstrates how to increase the number of results per request to the CloudBolt API. The larger the number, the
greater the strain on CloudBolt but the fewer HTTP requests will be made.
-------------------------- EXAMPLE 3 --------------------------
PS C:\\>Get-CBGroup -Session $session -ID 1
Demonstrates how to get a specific group from CloudBolt.
RELATED LINKS