-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDemoSampleScript.ps1
More file actions
21 lines (14 loc) · 1.11 KB
/
DemoSampleScript.ps1
File metadata and controls
21 lines (14 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#Requires -Modules TelligentCommunityRest,TelligentCommunitySample
## Start Configuration
$CommunityUrl = 'http://sampletest.local/'
$AdminUsername = 'admin'
$ApiKey = 'abc123'
## End Configuration
$creds = New-CommunityCredential $CommunityUrl $AdminUsername $ApiKey
$productGroup = New-CommunitySampleGroup -ParentGroupId 1 -GroupType Joinless -Name "Products" -Wiki 0 -Gallery 0 -Forum 0 -Blog 0 -Credential $creds
$productOneGroup = New-CommunitySampleGroup -ParentGroupId $productGroup.Id -GroupType PublicOpen -Name "Product One" -Wiki 1 -Gallery 1 -Credential $creds
$productTwoGroup = New-CommunitySampleGroup -ParentGroupId $productGroup.Id -GroupType PublicOpen -Name "Product Two" -Wiki 1 -Gallery 1 -Credential $creds
$productThreeGroup = New-CommunitySampleGroup -ParentGroupId $productGroup.Id -GroupType PublicOpen -Name "Product Three" -Wiki 1 -Gallery 1 -Credential $creds
Initialize-CommunitySampleGroup -GroupId $productOneGroup.Id -Credential $creds
Initialize-CommunitySampleGroup -GroupId $productTwoGroup.Id -Credential $creds
Initialize-CommunitySampleGroup -GroupId $productThreeGroup.Id -Credential $creds