I'm trying to update an existing address for a cus...
# suitetalkapi
b
I'm trying to update an existing address for a customer via SOAP. The call is successful but the address isn't updated. I found SuiteAnswer 40782 which confirms this should be possible and matches what I'm sending. Anyone else doing this successfully? Here is the SOAP:
Copy code
<soap:Body>
        <update xmlns="urn:messages_2023_1.platform.webservices.netsuite.com">
            <record internalId="12487456" xsi:type="q1:Customer" xmlns:q1="urn:relationships_2023_1.lists.webservices.netsuite.com">
                <q1:addressbookList replaceAll="false">
                    <q1:addressbook>
                        <q1:defaultShipping>false</q1:defaultShipping>
                        <q1:defaultBilling>false</q1:defaultBilling>
                        <q1:isResidential>false</q1:isResidential>
                        <q1:label>Test Address Update</q1:label>
                        <q1:addressbookAddress>
                            <internalId xmlns="urn:common_2023_1.platform.webservices.netsuite.com">4773967</internalId>
                            <country xmlns="urn:common_2023_1.platform.webservices.netsuite.com">_unitedStates</country>
                            <attention xmlns="urn:common_2023_1.platform.webservices.netsuite.com">Prof X</attention>
                            <addressee xmlns="urn:common_2023_1.platform.webservices.netsuite.com">Xavier's Acad</addressee>
                            <addr1 xmlns="urn:common_2023_1.platform.webservices.netsuite.com">123 Marvel Drive</addr1>
                            <addr2 xmlns="urn:common_2023_1.platform.webservices.netsuite.com"/>
                            <addr3 xmlns="urn:common_2023_1.platform.webservices.netsuite.com"/>
                            <city xmlns="urn:common_2023_1.platform.webservices.netsuite.com">Provo</city>
                            <state xmlns="urn:common_2023_1.platform.webservices.netsuite.com">UT</state>
                            <zip xmlns="urn:common_2023_1.platform.webservices.netsuite.com">84604</zip>
                        </q1:addressbookAddress>
                        <q1:internalId>4773967</q1:internalId>
                    </q1:addressbook>
                </q1:addressbookList>
            </record>
        </update>
    </soap:Body>
b
learn the difference between the internal id of the addressbook line and the internal id of the address subrecord
b
Thanks for responding. I'm aware that both have an id and I have tried different combinations. Sorry if that was confusing in the above. The solution in the SuiteAnswer doesn't match the structure I'm expecting of <addressbooklist><addressbook><address>. I believe it is the address subrecord id that is needed. Is that right? When I get a customer record the only id returned is the addressbook line. The address subrecord doesn't include an id. Does that need to be retrieved in a different call?
I was able to get this working referencing the addressbook line id. While I was sure I had tried that, I must not have removed the id from the address subrecord or something.