Update Household
Use this request to edit information for a particular household.
REST
Request
https://api.neoncrm.com/neonws/services/api/account/updateHouseHold?userSessionId=[session id]&houseHold.householdId=13&houseHold.name=test1&houseHold.houseHoldContacts.houseHoldContact.accountId=3480&houseHold.houseHoldContacts.houseHoldContact.relationType.id=20&houseHold.houseHoldContacts.houseHoldContact.isPrimaryHouseHoldContact=true
Setting the Primary Contact
The Household Primary Contact must be defined in the request. This is the case even if there are no changes to be made to the Primary Contact itself.
Setting the Household Primary Contact requires three parameters:
&houseHold.houseHoldContacts.houseHoldContact.accountId=[Account ID]
&houseHold.houseHoldContacts.houseHoldContact.relationType.id=[Relation Type ID]
&houseHold.houseHoldContacts.houseHoldContact.isPrimaryHouseHoldContact=true
Response
{ "updateHouseHoldResponse": {
"operationResult": "SUCCESS",
"responseMessage": "Household updated.",
"responseDateTime": "2012-12-27T02:25:31.969-06:00",
"houseHoldId": 13 }
}
SOAP
Request
<soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:neon="http://www.z2systems.com/schemas/neonws/">
<soapenv:header>
<soapenv:body>
<neon:updatehouseholdrequest>
<usersessionid>T1357624094982</usersessionid>
<household>
<householdid>28</householdid>
<name>test house hold 234</name>
<salutation>sister</salutation>
<householdcontacts>
<householdcontact>
<accountid>5787</accountid>
<relationtype>
<id>1</id>
</relationtype>
<isprimaryhouseholdcontact>true</isprimaryhouseholdcontact>
</householdcontact>
<householdcontact>
<accountid>5788</accountid>
<relationtype>
<id>1</id>
</relationtype>
<isprimaryhouseholdcontact>false</isprimaryhouseholdcontact>
</householdcontact>
</householdcontacts>
</household>
</neon:updatehouseholdrequest>
</soapenv:body>
</soapenv:header>
</soapenv:envelope>
Response
<soap:envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:body>
<ns2:updatehouseholdresponse xmlns:ns2="http://www.z2systems.com/schemas/neonws/">
<operationresult>SUCCESS</operationresult>
<responsemessage>Household updated.</responsemessage>
<responsedatetime>2013-01-08T01:52:27.637-06:00</responsedatetime>
<householdid>28</householdid>
</ns2:updatehouseholdresponse>
</soap:body>
</soap:envelope>
Request Parameters
Name | Required | Description |
---|---|---|
houseHold.householdId | Yes | The ID of the household to be updated. |
houseHold.houseHoldContacts.houseHoldContact.accountId | Yes | This is the account ID for a household contact. |
houseHold.houseHoldContacts.houseHoldContact.isPrimaryHouseHoldContact | Yes | Indicates this account is the primary contact. Possible values: true, false. |
houseHold.houseHoldContacts.houseHoldContact.relationType.id | Yes | The relation type ID can be retrieved from the List Relation Types method. |
houseHold.houseHoldContacts.houseHoldContact.relationType.name | The relation type ID can be retrieved from the List Relation Types method. This is only required when an ID is not provided. | |
houseHold.houseHoldContacts.houseHoldContact.confirmDelete | Possible values: true, false. This removes a contact from the household. This cannot be used for the primary contact. | |
houseHold.name | Yes | Household Name |
houseHold.salutation | Household Salutation |
Response Parameters
Name | Required | Description |
---|---|---|
houseHoldId | Yes | Household ID |
Error Codes
Code | Text | Description |
---|---|---|
10151 | Household name is required. | |
10152 | Household contact is required. | |
10153 | One and only One of the Household contact can be primary contact. | |
10154 | Household relation type is required. | |
10155 | Household relation type is invalid. | |
10156 | Household contact accountId is required. | |
10157 | Household contact accountId is invalid. | |
10158 | Given Household account is already a primary contact in another household. | |
10159 | Household id is required. | |
10160 | Household id is invalid. |