locked
I'm trying to create/update a record in CRM ONLINE using SOAPUI tool , unable to do so. RRS feed

  • Question

  • <soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:ser="http://schemas.microsoft.com/xrm/2011/Contracts/Services" xmlns:con="http://schemas.microsoft.com/xrm/2011/Contracts" xmlns:sys="http://schemas.datacontract.org/2004/07/System.Collections.Generic">
       <soap:Header/>
       <soap:Body>
          <ser:Create>
             <!--Optional:-->
             <ser:entity>
                <!--Optional:-->
                <con:Attributes>
                   <!--Zero or more repetitions:-->
                   <con:KeyValuePairOfstringanyType>
                      <sys:key>fullname</sys:key>
                      <sys:value>test</sys:value>
                   </con:KeyValuePairOfstringanyType>
                </con:Attributes>
                <!--Optional:-->
                <con:EntityState>?</con:EntityState>
                <!--Optional:-->
                <con:FormattedValues>
                   <!--Zero or more repetitions:-->
                   <con:KeyValuePairOfstringstring>
                      <sys:key>?</sys:key>
                      <sys:value>?</sys:value>
                   </con:KeyValuePairOfstringstring>
                </con:FormattedValues>
                <!--Optional:-->
                <con:Id>?</con:Id>
                <!--Optional:-->
                <con:LogicalName></con:LogicalName>
                <!--Optional:-->
                <con:RelatedEntities>
                   <!--Zero or more repetitions:-->
                   <con:KeyValuePairOfRelationshipEntityCollectionX_PsK4FkN>
                      <sys:key>
                         <!--Optional:-->
                         <con:PrimaryEntityRole>?</con:PrimaryEntityRole>
                         <!--Optional:-->
                         <con:SchemaName></con:SchemaName>
                      </sys:key>
                      <sys:value>
                         <!--Optional:-->
                         <con:Entities>
                            <!--Zero or more repetitions:-->
                            <con:Entity/>
                         </con:Entities>
                         <!--Optional:-->
                         <con:EntityName>contact</con:EntityName>
                         <!--Optional:-->
                         <con:MinActiveRowVersion>?</con:MinActiveRowVersion>
                         <!--Optional:-->
                         <con:MoreRecords>?</con:MoreRecords>
                         <!--Optional:-->
                         <con:PagingCookie>?</con:PagingCookie>
                         <!--Optional:-->
                         <con:TotalRecordCount>?</con:TotalRecordCount>
                         <!--Optional:-->
                         <con:TotalRecordCountLimitExceeded>?</con:TotalRecordCountLimitExceeded>
                      </sys:value>
                   </con:KeyValuePairOfRelationshipEntityCollectionX_PsK4FkN>
                </con:RelatedEntities>
             </ser:entity>
          </ser:Create>
       </soap:Body>
    </soap:Envelope>

    Above Code I'm trying to execute but getting authentication issue

    • Sun Apr 10 17:38:34 IST 2016:ERROR:org.apache.http.conn.HttpHostConnectException: Connection to https://hexa123.api.crm8.dynamics.com refused
    • org.apache.http.conn.HttpHostConnectException: Connection to https://hexa123.api.crm8.dynamics.com refused
    • at com.eviware.soapui.impl.wsdl.support.http.SoapUIMultiThreadedHttpConnectionManager$SoapUIClientConnectionOperator.openConnection(SoapUIMultiThreadedHttpConnectionManager.java:279)
    • at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:149)
    • at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:121)
    • at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:561)
    • at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:415)
    • at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:820)
    • at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:754)
    • at com.eviware.soapui.impl.wsdl.support.http.HttpClientSupport$Helper.execute(HttpClientSupport.java:233)
    • at com.eviware.soapui.impl.wsdl.support.http.HttpClientSupport.execute(HttpClientSupport.java:323)
    • at com.eviware.soapui.impl.wsdl.submit.transports.http.HttpClientRequestTransport.submitRequest(HttpClientRequestTransport.java:290)
    • at com.eviware.soapui.impl.wsdl.submit.transports.http.HttpClientRequestTransport.sendRequest(HttpClientRequestTransport.java:220)
    • at com.eviware.soapui.impl.wsdl.WsdlSubmit.run(WsdlSubmit.java:119)
    • at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    • at java.util.concurrent.FutureTask.run(Unknown Source)
    • at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    • at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    • at java.lang.Thread.run(Unknown Source)
    • Caused by: java.net.ConnectException: Connection timed out: connect
    • at java.net.DualStackPlainSocketImpl.connect0(Native Method)
    • at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
    • at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
    • at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
    • at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
    • at java.net.PlainSocketImpl.connect(Unknown Source)
    • at java.net.SocksSocketImpl.connect(Unknown Source)
    • at java.net.Socket.connect(Unknown Source)
    • at sun.security.ssl.SSLSocketImpl.connect(Unknown Source)
    • at com.eviware.soapui.impl.wsdl.support.http.SoapUISSLSocketFactory.connectSocket(SoapUISSLSocketFactory.java:195)
    • at com.eviware.soapui.impl.wsdl.support.http.SoapUIMultiThreadedHttpConnectionManager$SoapUIClientConnectionOperator.openConnection(SoapUIMultiThreadedHttpConnectionManager.java:262)
    • ... 16 more 


    Sunday, April 10, 2016 1:22 PM

All replies

  • Hi 

    How are you authenticating the connection to CRM ?

    Did you try to use CRM organization service url to authenticate instead ? i am assuming here that you are using CRM url for authenticating CRM connection

    Thursday, April 14, 2016 8:42 AM