That has worked! The scripts to add, remove and view current REST API allowed users/groups are now working as expected.
However, several of the other scripts to manage API are still broken.
Examples:
Configuring Brute Force:
https://www.adaxes.com/sdk/REST_BruteForceProtection/
GAC Version Location
--- ------- --------
True v4.0.30319 C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Softerra.Adaxes.Adsi\v4.0_3.19.25611.0__43a637781bd9a3c2\Softerra.Adaxes.Adsi.dll
cmdlet Get-Credential at command pipeline position 1
Supply values for the following parameters:
Exception calling "ToJson" with "1" argument(s): "'e' is an invalid start of a property name. Expected a '"'. Path: $ | LineNumber: 0 | BytePositionInLine: 1."
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_Config_BruteForce.ps1:23 char:1
+ $config = $restApi.ToJson("{elements: ['BruteForceProtection']}") | C ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : ServiceJsonException
The property 'enabled' cannot be found on this object. Verify that the property exists and can be set.
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_Config_BruteForce.ps1:24 char:1
+ $config.bruteForceProtection.enabled = $enableBruteForceProtection
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : PropertyNotFound
Exception calling "ToJson" with "1" argument(s): "'e' is an invalid start of a property name. Expected a '"'. Path: $ | LineNumber: 0 | BytePositionInLine: 1."
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_Config_BruteForce.ps1:29 char:1
+ $config = $restApi.ToJson("{elements: ['BruteForceProtection']}") | C ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : ServiceJsonException
The property 'delayResponseEnabled' cannot be found on this object. Verify that the property exists and can be set.
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_Config_BruteForce.ps1:33 char:5
+ $config.bruteForceProtection.delayResponseEnabled = $true
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : PropertyNotFound
The property 'delayResponseAttemptsCount' cannot be found on this object. Verify that the property exists and can be set.
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_Config_BruteForce.ps1:34 char:5
+ $config.bruteForceProtection.delayResponseAttemptsCount = $maxFai ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : PropertyNotFound
WARNING: Settings will be saved but will not take effect.
Brute force protection is disabled.
Exception calling "ToJson" with "1" argument(s): "'e' is an invalid start of a property name. Expected a '"'. Path: $ | LineNumber: 0 | BytePositionInLine: 1."
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_Config_BruteForce.ps1:52 char:1
+ $config = $restApi.ToJson("{elements: ['BruteForceProtection']}") | C ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : ServiceJsonException
The property 'showGenericErrorMessageEnabled' cannot be found on this object. Verify that the property exists and can be set.
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_Config_BruteForce.ps1:53 char:1
+ $config.bruteForceProtection.showGenericErrorMessageEnabled = $generi ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : PropertyNotFound
WARNING: Settings will be saved but will not take effect.
Brute force protection is disabled.
Checking Brute Force Protection
GAC Version Location
--- ------- --------
True v4.0.30319 C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Softerra.Adaxes.Adsi\v4.0_3.19.25611.0__43a637781bd9a3c2\Softerra.Adaxes.Adsi.dll
cmdlet Get-Credential at command pipeline position 1
Supply values for the following parameters:
Exception calling "ToJson" with "1" argument(s): "'e' is an invalid start of a property name. Expected a '"'. Path: $ | LineNumber: 0 | BytePositionInLine: 1."
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_View_BruteForceProtection.ps1:18 char:1
+ $config = $restApi.ToJson("{elements: ['BruteForceProtection']}") | C ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : ServiceJsonException
Brute force protection is disabled.
Restricting allowed operations
https://www.adaxes.com/sdk/REST_AllowedOperations/
GAC Version Location
--- ------- --------
True v4.0.30319 C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Softerra.Adaxes.Adsi\v4.0_3.19.25611.0__43a637781bd9a3c2\Softerra.Adaxes.Adsi.dll
cmdlet Get-Credential at command pipeline position 1
Supply values for the following parameters:
Exception calling "ToJson" with "1" argument(s): "'e' is an invalid start of a property name. Expected a '"'. Path: $ | LineNumber: 0 | BytePositionInLine: 1."
At C:\Users\user\Desktop\Adaxes Stuff\Scripts\API_SetAllowedOperations.ps1:31 char:1
+ $config = $restApi.ToJson("{elements: ['Operations']}") | ConvertFrom ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : ServiceJsonException