Brevo is a versatile digital marketing platform that enables businesses to streamline customer communication through multiple channels, including email, SMS, and more.
This PowerShell module contains functions to automate Brevo via the Brevo API
| General | Contact Management | Marketing | Account and Settings |
|---|---|---|---|
| Connect-Brevo | Add-BrevoContactListMember | Get-BrevoEmailCampaign | Get-BrevoUser |
| Disconnect-Brevo | Get-BrevoContact | Remove-BrevoEmailCampaign | Get-BrevoUserActivitylog |
| Invoke-BrevoCall | Get-BrevoContactAttribute | Send-BrevoEmailCampaign | Get-BrevoUserPermission |
| Get-BrevoContactFolder | Send-BrevoUserInvitation | ||
| Get-BrevoContactList | |||
| Get-BrevoContactListMember | Confirm-BrevoDomain | ||
| Get-BrevoContactSegment | Get-BrevoDomain | ||
| Import-BrevoContact | New-BrevoDomain | ||
| New-BrevoContact | Remove-BrevoDomain | ||
| Update-BrevoContact | Get-BrevoAccount | ||
| Remove-BrevoContact | Get-BrevoSender | ||
| New-BrevoContactList | |||
| New-BrevoDomain | |||
| Remove-BrevoDomain | |||
| Test-BrevoDomain |
# PowerShellGet 2.x
Install-Module -Name Brevo -Repository PSGallery
# PowerShellGet 3.x
Install-PSResource -Name Brevo
Import-Module Brevo
# List all available cmdlets provided by the module
Get-Command -Module Brevo
# Disconnect from Brevo
Disconnect-BrevoYou have to have an API key first. Using your API key to authenticate
- Login to Brevo.com or register for free
- Navigate to My Profile > SMTP & API > API-Key > Generate ne API Key
- Copy the generated key for later use
# Create Credentials
# $apikey = Get-credential -Message "Please enter your Brevo API key (username doesn't matter)"
# $apikey | Export-Clixml -Path ".\Brevo-APIkey.local.xml"
$apikey = Import-Clixml -Path ".\Brevo-APIkey.local.xml"
Connect-Brevo -APIkey $apikeyGet-BrevoContactAttributesGet-BrevoContactFolder | Format-TableGet-BrevoContactList | Format-TableNew-BrevoContactFolder -Name "MyFolder01"$ContactFolder = Get-BrevoContactFolder | Where-Object { $_.name -eq "MyFolder01" }
New-BrevoContactList -Name "MyList" -FolderId $ContactFolder.idNew-BrevoContactAttribute -attributeCategory normal -type text -attributeName USERTYPENew-BrevoContact -Email "test01@example.org" -attributes @{FNAME="Elly"; LNAME="Roger";COUNTRIES=@("India","China")} -listIds 22,355