I use Powershell to automate Sharepoint tasks quite offen. There are however some caveats about this, mainly that you have to be on the same machine as the machine you want to use as a target for the script. To solve this you can use the webservices available in Sharepoint, and I have been using this for quite some time. The only problem is that the most common method “out there” requires wdsl.exe which is a part of the .net sdk.
Today I stumbled upon a article by Lee Holmes who have constructed a method for generating the wdsl without wdsl.exe in pure powershell. This have been published for a while but usefull anyways =) I’ve also included it my spps-toolkit.ps1. Here’s the link: http://www.leeholmes.com/blog/CallingAWebserviceFromPowerShell.aspx