dynamics crm 2011 - SOAP requests to CRM2011 via PHP -


i trying create lead in microsoft dynamic 2011. have connected php script crm , positive feedback.

i have used fiddler soap code used create lead in crm2011. however, when use same code through php script 'false' return.

the soap code have discovered below:

   <s:body>         <execute xmlns="http://schemas.microsoft.com/crm/2009/webservices">                 <command>1</command>                 <commandxml>                     <input>                         <id>{00000000-0000-0000-0000-000000000000}</id>                         <name>lead</name>                         <formid>e3b6ddb7-8df0-4410-ac7b-fd32e5053d38</formid>                         <dataxml>                             <lead>                                 <leadqualitycode>2</leadqualitycode>                                 <statuscode>1</statuscode>                                 <ownerid type="8" name="vlad hercules">{6710c3a0-6ee9-e211-b17c-984be16d3daa}</ownerid>                                 <decisionmaker>0</decisionmaker>                                 <salesstage>0</salesstage>                                 <subject>subject</subject>                                 <lastname>vladislav</lastname>                                 <transactioncurrencyid type="9105" name="usd">{5b1c0b98-6ce9-e211-8b44-984be17c9a7b}</transactioncurrencyid>                                 <preferredcontactmethodcode>1</preferredcontactmethodcode>                                 <donotemail>0</donotemail>                                 <donotbulkemail>0</donotbulkemail>                                 <donotphone>0</donotphone>                                 <donotpostalmail>0</donotpostalmail>                                 <donotsendmm>0</donotsendmm>                             </lead>                         </dataxml>                         <associations></associations>                     </input>                 </commandxml>             </execute>         </s:body>     </s:envelope> 

how can issue resolved? can information on how requests look?

the example provided microsoft returns false when tried it:

<create xmlns="http://schemas.microsoft.com/xrm/2011/contracts/services">                     <entity xmlns:b="http://schemas.microsoft.com/xrm/2011/contracts" xmlns:i="http://www.w3.org/2001/xmlschema-instance">                         <b:attributes xmlns:c="http://schemas.datacontract.org/2004/07/system.collections.generic">                             <b:keyvaluepairofstringanytype>                                 <c:key>name</c:key>                                 <c:value i:type="d:string" xmlns:d="http://www.w3.org/2001/xmlschema">newer corporation</c:value>                             </b:keyvaluepairofstringanytype>                         </b:attributes>                         <b:entitystate i:nil="true"/>                         <b:formattedvalues xmlns:c="http://schemas.datacontract.org/2004/07/system.collections.generic"/>                         <b:id>00000000-0000-0000-0000-000000000000</b:id>                         <b:logicalname>account</b:logicalname>                         <b:relatedentities xmlns:c="http://schemas.datacontract.org/2004/07/system.collections.generic"/>                     </entity>                     </create> 

i'm not expert on crm2011 soap calls haven't seen type of query before suggest try using similar following.

<create xmlns="http://schemas.microsoft.com/xrm/2011/contracts/services" xmlns:i="http://www.w3.org/2001/xmlschema-instance">    <entity xmlns:a="http://schemas.microsoft.com/xrm/2011/contracts">       <a:attributes xmlns:b="http://schemas.datacontract.org/2004/07/system.collections.generic">          <a:keyvaluepairofstringanytype>             <b:key>leadqualitycode</b:key>             <b:value i:type="a:optionsetvalue">                <a:value>2</a:value>             </b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>statuscode</b:key>             <b:value i:type="a:optionsetvalue">                <a:value>1</a:value>             </b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>ownerid</b:key>             <b:value i:type="a:entityreference">                <a:id>{6710c3a0-6ee9-e211-b17c-984be16d3daa}</a:id>                <a:logicalname>systemuser</a:logicalname>                <a:name i:nil="true" />             </b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>decisionmaker</b:key>             <b:value xmlns:c="http://www.w3.org/2001/xmlschema" i:type="c:boolean">0</b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>salesstage</b:key>             <b:value i:type="a:optionsetvalue">                <a:value>0</a:value>             </b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>subject</b:key>             <b:value xmlns:c="http://www.w3.org/2001/xmlschema" i:type="c:string">subject</b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>lastname</b:key>             <b:value xmlns:c="http://www.w3.org/2001/xmlschema" i:type="c:string">vladislav</b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>transactioncurrencyid</b:key>             <b:value i:type="a:entityreference">                <a:id>{5b1c0b98-6ce9-e211-8b44-984be17c9a7b}</a:id>                <a:logicalname>transactioncurrency</a:logicalname>                <a:name i:nil="true" />             </b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>preferredcontactmethodcode</b:key>             <b:value i:type="a:optionsetvalue">                <a:value>1</a:value>             </b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>donotemail</b:key>             <b:value xmlns:c="http://www.w3.org/2001/xmlschema" i:type="c:boolean">0</b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>donotbulkemail</b:key>             <b:value xmlns:c="http://www.w3.org/2001/xmlschema" i:type="c:boolean">0</b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>donotphone</b:key>             <b:value xmlns:c="http://www.w3.org/2001/xmlschema" i:type="c:boolean">0</b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>donotpostalmail</b:key>             <b:value xmlns:c="http://www.w3.org/2001/xmlschema" i:type="c:boolean">0</b:value>          </a:keyvaluepairofstringanytype>          <a:keyvaluepairofstringanytype>             <b:key>donotsendmm</b:key>             <b:value xmlns:c="http://www.w3.org/2001/xmlschema" i:type="c:boolean">0</b:value>          </a:keyvaluepairofstringanytype>       </a:attributes>       <a:entitystate i:nil="true" />       <a:formattedvalues xmlns:b="http://schemas.datacontract.org/2004/07/system.collections.generic" />       <a:id>00000000-0000-0000-0000-000000000000</a:id>       <a:logicalname>lead</a:logicalname>       <a:relatedentities xmlns:b="http://schemas.datacontract.org/2004/07/system.collections.generic" />    </entity> </create> 

Comments

Popular posts from this blog

html5 - What is breaking my page when printing? -

html - Unable to style the color of bullets in a list -

c# - must be a non-abstract type with a public parameterless constructor in redis -