-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7154619
commit d1efe4c
Showing
1 changed file
with
37 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,12 +3,42 @@ $Hosts = @("859N3ZZ", "759N3ZZ") | |
$GroupJsonString = @' | ||
{ | ||
"Id": 0, | ||
"MyAccountId": 0, | ||
"Description": "", | ||
"Name": "", | ||
"MyAccountId": null, | ||
"Description": "Support Assist Test Group 1", | ||
"Name": "Support Assist Test Group 1", | ||
"DispatchOptIn": true, | ||
"ContactOptIn": true, | ||
"DispatchOptIn": false, | ||
"CustomerDetails": { | ||
"ShippingDetails": { | ||
"AddressLine1": "109 Gelante Way", | ||
"TechnicianRequired": true, | ||
"PrimaryContact": { | ||
"LastName": "Curell", | ||
"Phone": "1111111111", | ||
"AlternatePhone": "", | ||
"FirstName": "Grant", | ||
"Email": "[email protected]" | ||
}, | ||
"AddressLine4": "", | ||
"City": "Dayton", | ||
"Country": "US", | ||
"DispatchNotes": "No", | ||
"State": "Ohio", | ||
"SecondaryContact": { | ||
"LastName": "Curell", | ||
"Phone": "9999999999", | ||
"AlternatePhone": "", | ||
"FirstName": "Angela", | ||
"Email": "[email protected]" | ||
}, | ||
"Cnpj": null, | ||
"AddressLine3": "78210", | ||
"PreferredContactTimeFrame": "10:00 AM-4:00 PM", | ||
"Zip": "45459", | ||
"Ie": null, | ||
"PreferredContactTimeZone": "TZ_ID_65", | ||
"AddressLine2": "San Antonio TX" | ||
}, | ||
"PrimaryContact": { | ||
"LastName": "Curell", | ||
"TimeZone": "TZ_ID_10", | ||
|
@@ -30,7 +60,7 @@ $GroupJsonString = @' | |
"Email": "[email protected]" | ||
} | ||
} | ||
} | ||
} | ||
'@ | ||
|
||
# Convert json string to PowerShell object | ||
|
@@ -40,10 +70,10 @@ $GroupJson = $GroupJsonString | ConvertFrom-Json | |
$GroupJson.Name = $GroupName | ||
|
||
# Print output to screen | ||
Write-Host $($GroupJson | ConvertTo-Json) | ||
Write-Host $($GroupJson | ConvertTo-Json -Depth 10) | ||
|
||
# Create Services group from json string | ||
New-OMESupportAssistGroup -AddGroup $($GroupJson | ConvertTo-Json) -Verbose | ||
New-OMESupportAssistGroup -AddGroup $($GroupJson | ConvertTo-Json -Depth 10) -Verbose | ||
|
||
# Get newly created group | ||
$GroupName | Get-OMEGroup | Format-List | ||
|