Skip to content

Instantly share code, notes, and snippets.

@puttyq
Created August 2, 2018 22:16
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save puttyq/aefd9fa633a7a1d8a11a8d2237e10d23 to your computer and use it in GitHub Desktop.
Save puttyq/aefd9fa633a7a1d8a11a8d2237e10d23 to your computer and use it in GitHub Desktop.
Connecting to SAP ES via PowerShell
# SAP proxy variables
$uriUserManagement = "http://sapserver/sap/bc/srt/wsdl/flv_10002A111AD1/bndg_url/sap/bc/srt/rfc/sap/zfimconnector/010/zfimconnector_user/zfimconnector_user?sap-client=010"
$uriUserManagementNamespace = "SAP"
$uriUserManagementClass = "SAP_WSDL"
# Create a secure credential to pass to the WS-Proxy
$secpasswd = ConvertTo-SecureString $password -AsPlainText -Force
$credential = New-Object System.Management.Automation.PSCredential ($username, $secpasswd)
# Create web services proxy object
$proxyUser = New-WebServiceProxy -Uri $uriUserManagement -Credential $credential -Class $uriUserManagementClass -Namespace $uriUserManagementNamespace
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment