我想获取所有 InventoryItems 的列表
根据这份文件:https://system.netsuite.com/help/helpcenter/en_US/Output/Help/SuiteCloudCustomizationScriptingWebServices/SuiteTalkWebServices/getAll.html https://system.netsuite.com/help/helpcenter/en_US/Output/Help/SuiteCloudCustomizationScriptingWebServices/SuiteTalkWebServices/getAll.html
我正在形成以下请求:
<env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:platformMsgs="urn:platform_2013_1.webservices.netsuite.com" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
<env:Header>
<passport>
<email>******</email>
<password>******</password>
<account>******</account>
</passport>
</env:Header>
<env:Body>
<platformMsgs:getAll>
<recordType>InventoryItem</recordType>
</platformMsgs:getAll>
</env:Body>
</env:Envelope>
但收到错误的响应:
<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">
<soapenv:Header>
<platformMsgs:documentInfo xmlns:platformMsgs="urn:messages_2013_1.platform.webservices.netsuite.com">
<platformMsgs:nsId>WEBSERVICES_969904_100920131651936419141601801_cbf1690968b43</platformMsgs:nsId>
</platformMsgs:documentInfo>
</soapenv:Header>
<soapenv:Body>
<getAllResponse xmlns="urn:platform_2013_1.webservices.netsuite.com">
<platformCore:getAllResult xmlns:platformCore="urn:core_2013_1.platform.webservices.netsuite.com">
<platformCore:status isSuccess="false">
<platformCore:statusDetail type="ERROR">
<platformCore:code>GETALL_RCRD_TYPE_REQD</platformCore:code>
<platformCore:message>The getAll record type is required.</platformCore:message>
</platformCore:statusDetail>
</platformCore:status>
</platformCore:getAllResult>
</getAllResponse>
</soapenv:Body>
</soapenv:Envelope>
我尝试过请求货币、状态 - 响应总是相同
我尝试过以下变体:
<GetAllRecordType>inventoryItem</GetAllRecordType>
and
<recordType>inventoryItem</recordType>
and
<GetAllRecordType>currency</GetAllRecordType>
and
<recordType>currency</recordType>
具有相同的响应:
<platformCore:message>The getAll record type is required.</platformCore:message>
根据https://webservices.netsuite.com/xsd/platform/v2013_2_0/coreTypes.xsd https://webservices.netsuite.com/xsd/platform/v2013_2_0/coreTypes.xsd- 我已经正确指定了 recordType (顺便说一句,我也尝试过但没有成功)
我正在使用 ruby,但没有完整的 ruby 库。现有的几乎不包含我将要使用的所有东西。
有人可以帮助我做错了什么或者可能有人有工作示例