+ Start a Discussion

INVALID_TYPE received when doing a create

here is the soap message that I sent:


<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/ XMLSchema-instance">
  <ns1:SessionHeader soapenv:mustUnderstand="0" xmlns:ns1="SoapService">
   <ns2:sessionId xmlns:ns2="urn:enterprise.soap.sforce.com">0kGvdc1oBLNSNwZYAad2z9KdIs_lIgFRIzhnzK6Tp.a2s5ZHXqHEkbo.fAWCNvmYlNiKBwpEXJ3SNDM6LQ6h_vbtzKggVlhL</ns2:sessionId>
  <create xmlns="urn:enterprise.soap.sforce.com">
   <sObjects xsi:type="ns3:Account" xmlns:ns3="urn:sobject.enterprise.soap.sforce.com">


here is the response that I received:


<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <faultstring>common.exception.ApiException: Must send a concrete entity type.</faultstring>
    <sf:fault xsi:type="sf:InvalidSObjectFault" xmlns:sf="urn:fault.enterprise.soap.sforce.com">
     <sf:exceptionMessage>Must send a concrete entity type.</sf:exceptionMessage>



what did I do wrong here?


Hi kpicha,

Looks like it should work.  How did you create the soap message?  Are you using axis or .net or php or something else?


Oh, never mind, just saw your other post.  You are using VC++ I think.  Let me look at that post and see if there are more clues there.


One more question, what is the url that you are sending this message to?

I'm using very low level CInternet objects to create HTTP requests from vc++


I can send you the entire code if you want it, but the info I posted on the original message was exactly what went out


Is this possibly a security issue ..?.. I was wondering if, as a developer, I would have the rights to be able to create instances of the Account object.

What's the URL that you're sending that request to ? that looks like the error you'd get if you send your request to the partner endpoint, not the enterprise endpoint.
I can't tell if its just a cut'n'paste error, but when i copied your message it has a space in the URI for the xsi namespace
xmlns:xsi="http://www.w3.org/2001/ XMLSchema-instance"

running your request like that generated the error you reported, if i remove the space, e.g. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" it worked (or at least got onto the next error about site not being valid for insert update, but that might just be my org configuration)

I have seen that error when I accidentially used an EMEA server URL instead of the NA1 URL returned from the loginResponse

On instance does your SFDC org live?

Message Edited by djordan on 08-30-2004 04:18 PM