Can anyone please provide a sample soap request th...
# integrations
r
Can anyone please provide a sample soap request that shows how to send only name (without internal id) for a record ref field? I am facing below error when sending item and location for inventory adjustment. Error:
Copy code
<platformCore:code>USER_ERROR</platformCore:code><platformCore:message>Please enter value(s) for: Item, Location</platformCore:message>
Request snippet:
Copy code
<ns01:item xsi:type="ns02:inventoryItem">
          <ns02:name xmlns:ns02="urn:core.platform.webservices.netsuite.com">5686</ns02:name>
        </ns01:item>
        <ns01:location xsi:type="ns02:location">
          <ns02:name xmlns:ns02="urn:core.platform.webservices.netsuite.com">USA : BLT-1</ns02:name>
        </ns01:location>
s
I may be wrong, but I don't think you can reference an item without internal id. If I'm not wrong, you'll have to get the internal id first somehow.
b
r
@battk Tried with RecordRef too.. Same error. Any samples on how to send RecordRef?
Copy code
<ns01:item type="inventoryItem" xsi:type="ns02:RecordRef">
          <ns02:name xmlns:ns02="urn:core.platform.webservices.netsuite.com">5686</ns02:name>
        </ns01:item>
        <ns01:department internalId="1"/>
        <ns01:class internalId="21"/>
        <ns01:location type="location" xsi:type="ns02:RecordRef">
          <ns02:name xmlns:ns02="urn:core.platform.webservices.netsuite.com">USA : BLT-1</ns02:name>
        </ns01:location>
b
read it
its a link to the help docs that describe how record refs work
r
Thank you @battk @Shawn Talbert Documentation clearly says name will be ignored during write operations
Copy code
name

xsd:string

N

This is a read-only field that is populated by NetSuite when it's a part of a get or search response. If this field is populated during a write operation, it will be ignored.