Simple Web Services call using PowerShell

At times, you will be requiring to test your web service if it is working.
To do that, simply fire up your PowerShell and run the following scripts

[sourcecode language=”powershell”]
$cre = Get-Credential
#system will prompt for login and password
#This would be a standard NTLM authentication
$proxy = New-WebServiceProxy -URI <YOUR WEB SERVICE URL HERE> -Credential $cre
[/sourcecode]

Enter $proxy to check if the object is added

To Check the Operation parameters, Enter $proxy.AddAction (for example)

Leave a Reply

Your email address will not be published. Required fields are marked *