Trying to write a PS-script that update requesters E-Mail with the SDP-API.
The script works and I'm able to update other parameters, for example "Mobile", but not the E-Mail parameter even though i get a response stating that the result was succesfull.
$apikey = "
techkey"
$url = "
sdphost"
$inputData = @"
<?xml version='1.0' encoding='UTF-8'?>
<API version='1.0' >
<citype>
<name>Requester</name>
<criterias>
<criteria>
<parameter>
<name compOperator='IS'>CI Name</name>
<value>
requestersname</value>
</parameter>
</criteria>
</criterias>
<newvalue>
<record>
<parameter>
<name>E-Mail</name>
</parameter>
</record>
</newvalue>
</citype>
</API>
"@
$postParams = @{OPERATION_NAME='update';TECHNICIAN_KEY=$apikey;INPUT_DATA=$inputData}
$response = Invoke-WebRequest -uri $url -Body $postParams -Method Post
$resultat = $response.Content
[System.Windows.MessageBox]::Show($resultat)