SOAP Web Service – getList Operation

SOAP Action: getList

Scenario: get records of type of customer and location in a single request

Request

<soapenv:Envelope
    xmlns:xsd='http://www.w3.org/2001/XMLSchema'
    xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
    xmlns:soapenv='http://schemas.xmlsoap.org/soap/envelope/'
    xmlns:platformCore='urn:core_2021_2.platform.webservices.netsuite.com'
    xmlns:listRel='urn:relationships_2021_2.lists.webservices.netsuite.com'
    xmlns:listAcct='urn:accounting_2021_2.lists.webservices.netsuite.com'
    xmlns:platformMsgs='urn:messages_2021_2.platform.webservices.netsuite.com'>
    <soapenv:Header>
        <tokenPassport xsi:type='platformCore:TokenPassport'>
            <account xsi:type='xsd:string'>{{accountId}}</account>
            <consumerKey xsi:type='xsd:string'>{{consumerKey}}</consumerKey>
            <token xsi:type='xsd:string'>{{tokenId}}</token>
            <nonce xsi:type='xsd:string'>{{nonce}}</nonce>
            <timestamp xsi:type='xsd:long'>{{timestamp}}</timestamp>
            <signature algorithm='HMAC_SHA256' xsi:type='platformCore:TokenPassportSignature'>{{signature}}</signature>
        </tokenPassport>
    </soapenv:Header>
    <soapenv:Body>
        <getList xsi:type='platformMsgs:GetListRequest'>
            <baseRef xsi:type='platformCore:RecordRef' internalId='3' type='customer'></baseRef>
            <baseRef xsi:type='platformCore:RecordRef' internalId='103' type='location'></baseRef>
        </getList>
    </soapenv:Body>
</soapenv:Envelope>

Response

<?xml version="1.0" encoding="UTF-8"?>
<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_2021_2.platform.webservices.netsuite.com">
            <platformMsgs:nsId>WEBSERVICES_TSTDRV2779698_072720231690619106334753716_755a8c</platformMsgs:nsId>
        </platformMsgs:documentInfo>
    </soapenv:Header>
    <soapenv:Body>
        <getListResponse xmlns="">
            <platformMsgs:readResponseList xmlns:platformMsgs="urn:messages_2021_2.platform.webservices.netsuite.com">
                <platformCore:status isSuccess="true" xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com"/>
                <platformMsgs:readResponse>
                    <platformCore:status isSuccess="true" xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com"/>
                    <platformMsgs:record internalId="3" xsi:type="listRel:Customer" xmlns:listRel="urn:relationships_2021_2.lists.webservices.netsuite.com">
                        <listRel:customForm internalId="-2" xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com">
                            <platformCore:name>Standard Customer Form</platformCore:name>
                        </listRel:customForm>
                        <listRel:entityId>1</listRel:entityId>
                        <listRel:isPerson>false</listRel:isPerson>
                        <listRel:companyName>Anonymous</listRel:companyName>
                        <listRel:entityStatus internalId="13" xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com">
                            <platformCore:name>CUSTOMER-Closed Won</platformCore:name>
                        </listRel:entityStatus>
                        <listRel:defaultAddress>Anonymous
United States</listRel:defaultAddress>
                        <listRel:isInactive>false</listRel:isInactive>
                        <listRel:dateCreated>2018-01-31T13:55:46.000-08:00</listRel:dateCreated>
                        <listRel:emailPreference>_default</listRel:emailPreference>
                        <listRel:subsidiary internalId="1" xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com">
                            <platformCore:name>Parent Company</platformCore:name>
                        </listRel:subsidiary>
                        <listRel:taxExempt>true</listRel:taxExempt>
                        <listRel:creditHoldOverride>_auto</listRel:creditHoldOverride>
                        <listRel:overrideCurrencyFormat>false</listRel:overrideCurrencyFormat>
                        <listRel:displaySymbol>$</listRel:displaySymbol>
                        <listRel:symbolPlacement>_beforeNumber</listRel:symbolPlacement>
                        <listRel:balance>0.0</listRel:balance>
                        <listRel:overdueBalance>0.0</listRel:overdueBalance>
                        <listRel:unbilledOrders>0.0</listRel:unbilledOrders>
                        <listRel:depositBalance>0.0</listRel:depositBalance>
                        <listRel:shipComplete>false</listRel:shipComplete>
                        <listRel:taxable>false</listRel:taxable>
                        <listRel:aging>0.0</listRel:aging>
                        <listRel:aging1>0.0</listRel:aging1>
                        <listRel:aging2>0.0</listRel:aging2>
                        <listRel:aging3>0.0</listRel:aging3>
                        <listRel:aging4>0.0</listRel:aging4>
                        <listRel:giveAccess>false</listRel:giveAccess>
                        <listRel:accessRole internalId="14" xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com">
                            <platformCore:name>Customer Center</platformCore:name>
                        </listRel:accessRole>
                        <listRel:sendEmail>false</listRel:sendEmail>
                        <listRel:receivablesAccount internalId="-10" xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com">
                            <platformCore:name>Use System Preference</platformCore:name>
                        </listRel:receivablesAccount>
                        <listRel:webLead>No</listRel:webLead>
                        <listRel:lastModifiedDate>2018-01-31T13:55:47.000-08:00</listRel:lastModifiedDate>
                        <listRel:stage>_customer</listRel:stage>
                        <listRel:emailTransactions>false</listRel:emailTransactions>
                        <listRel:printTransactions>false</listRel:printTransactions>
                        <listRel:faxTransactions>false</listRel:faxTransactions>
                        <listRel:isBudgetApproved>false</listRel:isBudgetApproved>
                        <listRel:addressbookList>
                            <listRel:addressbook>
                                <listRel:defaultShipping>true</listRel:defaultShipping>
                                <listRel:defaultBilling>true</listRel:defaultBilling>
                                <listRel:isResidential>false</listRel:isResidential>
                                <listRel:addressbookAddress xmlns:platformCommon="urn:common_2021_2.platform.webservices.netsuite.com">
                                    <platformCommon:country>_unitedStates</platformCommon:country>
                                    <platformCommon:addressee>Anonymous</platformCommon:addressee>
                                    <platformCommon:addrText>Anonymous
United States</platformCommon:addrText>
                                    <platformCommon:override>false</platformCommon:override>
                                </listRel:addressbookAddress>
                                <listRel:internalId>1</listRel:internalId>
                            </listRel:addressbook>
                        </listRel:addressbookList>
                    </platformMsgs:record>
                </platformMsgs:readResponse>
                <platformMsgs:readResponse>
                    <platformCore:status isSuccess="true" xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com"/>
                    <platformMsgs:record internalId="103" xsi:type="listAcct:Location" xmlns:listAcct="urn:accounting_2021_2.lists.webservices.netsuite.com">
                        <listAcct:name>Test Location 2</listAcct:name>
                        <listAcct:subsidiaryList xmlns:platformCore="urn:core_2021_2.platform.webservices.netsuite.com">
                            <platformCore:recordRef internalId="1">
                                <platformCore:name>Parent Company</platformCore:name>
                            </platformCore:recordRef>
                        </listAcct:subsidiaryList>
                        <listAcct:isInactive>false</listAcct:isInactive>
                        <listAcct:timeZone>_americaLosAngeles</listAcct:timeZone>
                        <listAcct:makeInventoryAvailable>true</listAcct:makeInventoryAvailable>
                    </platformMsgs:record>
                </platformMsgs:readResponse>
            </platformMsgs:readResponseList>
        </getListResponse>
    </soapenv:Body>
</soapenv:Envelope>

Leave a comment

Your email address will not be published. Required fields are marked *