Get ContactList - tsubotitsch/Brevo GitHub Wiki

Get-ContactList

SYNOPSIS

Retrieves contact lists or a specific contact list from Brevo.

SYNTAX

None (Default)

Get-ContactList [-listName <String>] [-None] [-limit <Int32>] [-offset <Int32>] [-sort <String>]
 [-ProgressAction <ActionPreference>] [<CommonParameters>]

ByListId

Get-ContactList [-listId <Int32>] [-limit <Int32>] [-offset <Int32>] [-sort <String>]
 [-ProgressAction <ActionPreference>] [<CommonParameters>]

ByFolderId

Get-ContactList [-folderId <Int32>] [-listName <String>] [-limit <Int32>] [-offset <Int32>] [-sort <String>]
 [-ProgressAction <ActionPreference>] [<CommonParameters>]

DESCRIPTION

The Get-ContactList function retrieves contact lists or a specific contact list based on the provided parameters. It supports filtering by list ID, folder ID, or retrieving all lists with optional pagination and sorting.

EXAMPLES

EXAMPLE 1

# Retrieve all contact lists with default pagination
Get-ContactList

EXAMPLE 2

# Retrieve a specific contact list by its ID
Get-ContactList -listId 123

EXAMPLE 3

# Retrieve contact lists from a specific folder
Get-ContactList -folderId 456

EXAMPLE 4

# Retrieve contact lists with pagination
Get-ContactList -limit 20 -offset 10

PARAMETERS

-folderId

The ID of the folder to retrieve contact lists from. Used with the "ByFolderId" parameter set.

Type: Int32
Parameter Sets: ByFolderId
Aliases:

Required: False
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-limit

The maximum number of documents to retrieve per page. Accepts values from 0 to 50. Defaults to 10.

Type: Int32
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-listId

The ID of the specific contact list to retrieve. Used with the "ByListId" parameter set.

Type: Int32
Parameter Sets: ByListId
Aliases: Id

Required: False
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-listName

The name of the contact list to retrieve.

Type: String
Parameter Sets: None, ByFolderId
Aliases: Name

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-None

No specific filter applied

Type: SwitchParameter
Parameter Sets: None
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-offset

The index of the first document of the page. Defaults to 0.

Type: Int32
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-ProgressAction

{{ Fill ProgressAction Description }}

Type: ActionPreference
Parameter Sets: (All)
Aliases: proga

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-sort

The sorting criteria for the retrieved contact lists.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

OUTPUTS

Returns a list of contact lists or a specific contact list based on the provided parameters.

NOTES

RELATED LINKS

⚠️ **GitHub.com Fallback** ⚠️