title: How to choose an wsdl operation in node-soap
body: <p>I'm using the node-soap package to consume the following SOAP service: <a href="https://paymentsuat.mppglobal.com/interface/mpp/ipaypaymentpages/ipaypaymentpages.asmx?wsdl" rel="nofollow">https://paymentsuat.mppglobal.com/interface/mpp/ipaypaymentpages/ipaypaymentpages.asmx?wsdl</a></p>
  
  <p>For the iPayPaymentPagesSoap port, there are two operations with the same name, but different parameters.</p>
  
  <p>Using the describe function node-soap only shows the last operation for each port type. Is there a way of selecting which operation is called?</p>
  
  <pre><code>&lt;wsdl:portType name="iPayPaymentPagesSoap"&gt;
      &lt;wsdl:operation name="CreateSession"&gt;
          &lt;wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"&gt;
          Retrieves a Guid from the system populated with details. Used in conjunction with ipayment pages.
          &lt;/wsdl:documentation&gt;
          &lt;wsdl:input name="CreateSessionBySOAP" message="tns:CreateSessionBySOAPSoapIn"/&gt;
          &lt;wsdl:output name="CreateSessionBySOAP" message="tns:CreateSessionBySOAPSoapOut"/&gt;
      &lt;/wsdl:operation&gt;
      &lt;wsdl:operation name="CreateSession"&gt;
          &lt;wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"&gt;
          Retrieves a Guid from the system populated with user details. Used in conjunction with ipayment pages.
          &lt;/wsdl:documentation&gt;
          &lt;wsdl:input name="CreateSessionByGET" message="tns:CreateSessionByGETSoapIn"/&gt;
          &lt;wsdl:output name="CreateSessionByGET" message="tns:CreateSessionByGETSoapOut"/&gt;
      &lt;/wsdl:operation&gt;
  &lt;/wsdl:portType&gt;
  </code></pre>
  
  <p>Renders to:</p>
  
  <pre><code>{
      iPayPaymentPages: {
          iPayPaymentPagesSoap: {
              CreateSession: {
                  input: {
                      affiliateId: "s:int",
                      password: "s:string"
                  },
                  output: {
                      CreateSessionByGETResult: {
                          Guid: "s:string",
                          ErrorNumber: "s:int",
                          ErrorMessage: "s:string",
                          targetNSAlias: "tns",
                          targetNamespace: "https://secure1.mppglobal.com/interface/ipaypaymentpages/ipaypaymentpages.asmx"
                      }
                  }
              }
          }
      }
  }
  </code></pre>
  
  <p>However, i'm aiming to use CreateSession with the CreateSessionBySOAP parameters, but node-soap defaults to CreateSessionByGET.</p>
  
  <p>*I have no control over the WSDL and would much rather not use SOAP with Node.js, but i'm stuck with it in this case!</p>