web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Unanswered

How to update a customer data using soap request ?

(0) ShareShare
ReportReport
Posted on by 40

Hi Expert ,

   I have used add data(Customer/Product/ReleaseProduct/SalesOrder) in Dynamics AX 2012 using inbound port with  htp  soap request . Now i want to update that entity data but i can't find any reference document for update data where i need what are primary entity keylist for that entity. I am trying to update customer as below format but getting error  : 

Request ACtion : schemas.microsoft.com/.../update

Request Body : 

<s:Envelope xmlns:s="">schemas.xmlsoap.org/.../">
<s:Header>
<h:CallContext xmlns:h="">schemas.microsoft.com/.../datacontracts" xmlns="">schemas.microsoft.com/.../datacontracts" xmlns:xsi="">www.w3.org/.../XMLSchema-instance" xmlns:xsd="">www.w3.org/.../XMLSchema">
<Company>dat</Company>
</h:CallContext>
</s:Header>
<s:Body xmlns:xsi="">www.w3.org/.../XMLSchema-instance" xmlns:xsd="">www.w3.org/.../XMLSchema">
<CustomerServiceUpdateRequest xmlns="">schemas.microsoft.com/.../services">
<EntityKeyList xmlns="">schemas.microsoft.com/.../EntityKeyList">
<EntityKey xmlns="">schemas.microsoft.com/.../EntityKey">
<KeyData>
<KeyField>
<Field>AccountNum</Field>
<Value>W31</Value>
</KeyField>
</KeyData>
</EntityKey>
</EntityKeyList>
<Customer xmlns="">schemas.microsoft.com/.../Customer">
<CustTable class="entity">
<DirParty xsi:type="AxdEntity_DirParty_DirPerson" class="entity">
<PartyNumber>000001889</PartyNumber>
<PersonName class="entity">
<FirstName>Test</FirstName>
<LastName>w31</LastName>
</PersonName>
</DirParty>
</CustTable>
</Customer>
</CustomerServiceUpdateRequest>
</s:Body>
</s:Envelope>

Response Error : 

IInvalid document schema. The following error was returned:  The element 'CustTable' in namespace 'schemas.microsoft.com/.../Customer' has invalid child element 'DirParty' in namespace 'schemas.microsoft.com/.../Customer'. List of possible elements expected: '_DocumentHash, AccountNum, AccountStatement, Affiliated_RU, AgencyLocationCode, BankAccount, BankCentralBankPurposeCode, BankCentralBankPurposeText, BankCustPaymIdTable, BirthCountyCode_IT, BirthDate_IT, BirthPlace_IT, Blocked, CashDisc, CashDiscBaseDays, CCMNum_BR, ClearingPeriod, CNAE_BR, CNPJCPFNum_BR, CommercialRegister, CommercialRegisterInsetNumber, CommercialRegisterSection, CommissionGroup, CompanyChainId, CompanyIdSiret, CompanyNAFCode, CompanyType_MX, ConsDay_JP, ContactPersonId, CreditCardAddressVerification, CreditCardAddressVerificationLevel, CreditCardAddressVerificationVoid, CreditCardCVC, CreditMax, CreditRating, Curp_MX, Currency, CustClassificationId, CustExcludeCollectionFee, CustExcludeInterestCharges, CustFinalUser_BR, CustGroup' in namespace 'schemas.microsoft.com/.../Customer'.

Thanks 

surajit kundu

I have the same question (0)
  • Martin Dráb Profile Picture
    239,392 Most Valuable Professional on at

    The message is telling you two things:

    1. You forgot to include _DocumentHash. You'll get it by calling read operation.
    2. DirParty isn't a valid property of CustTable.

    You can see find some documentation in Updating Data With AIF. But the right flow is easier to see in a code snippet:

    var client = new CustomerServiceClient();
    
    // Read data from AX, including the hash
    var customers = client.read(callContext, entityKeyList);
    var custTable = customers.CustTable[0];
    
    // Modify table fields
    custTable.MyField = "123";
    
    // Send the update to AX
    client.update(callContext, entityKeyList, customers);

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 689

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 606 Super User 2026 Season 1

#3
CP04-islander Profile Picture

CP04-islander 356

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans