TestimoX

API Reference

Command

Set-TestimoXService

Namespace TestimoX.PowerShell
Outputs
TestimoX.Services.ServiceActionResult TestimoX.Services.ServiceConfigDeployment

Apply a TestimoX service configuration (validated first).

Remarks

If connected via Connect-TestimoXService, the cmdlet POSTs the JSON to the Management API, which validates the payload and persists it (hot-reload). If not connected, it validates locally and copies the file to the deployed service folder (admin required), optionally restarting the service.

Examples

Authored help example

Example 1: Update config and restart

PS>


Set-TestimoXService -Name TestimoX -ConfigPath C:\Configs\service.json -Restart
        

Example 2: Add and remove API keys (requires Connect-TestimoXService)

PS>


Connect-TestimoXService -Url 'https://server:7809/' -ApiKey (Get-Content C:\secret.txt -Raw)
Set-TestimoXService -AddApiKeyName 'alice' -AddApiKeyValue (Get-Content C:\alice.key -Raw)
Set-TestimoXService -RemoveApiKeyName 'alice'
        

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.

Syntax

Set-TestimoXService [-AddApiKeyName <string>] [-AddApiKeyValue <string>] [-ConfigPath <string>] [-LicensePath <string>] [-Name <string>] [-RemoveApiKeyName <string>] [-Restart] [<CommonParameters>]
#

Parameters

AddApiKeyName string optionalposition: namedpipeline: false
Add an API key with this friendly name (requires Management API).
AddApiKeyValue string optionalposition: namedpipeline: false
API key secret text to add (requires -AddApiKeyName).
ConfigPath string optionalposition: namedpipeline: false
Path to service.json to validate and apply.
LicensePath string optionalposition: namedpipeline: false
Optional path to a TestimoX.Service license container (.txlic) to deploy next to the service binary.
Name string optionalposition: namedpipeline: false
Windows service name.
RemoveApiKeyName string optionalposition: namedpipeline: false
Remove an API key by friendly name (requires Management API).
Restart SwitchParameter optionalposition: namedpipeline: false
Restart (or run once when connected to API) after applying the config.

Outputs

TestimoX.Services.ServiceActionResult, TestimoX.Services.ServiceConfigDeployment