POST api/v3/customers/{customerId}/addressBookEntry
Creates or updates an address book entry for a customer.
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
customerId |
The Id of the customer to which the addressbook entry belongs. |
integer |
Required |
Body Parameters
Represents the information for the address book entry
CustomerAddressBookEntryUpdateRequestName | Description | Type | Additional information |
---|---|---|---|
AddressBookEntryId |
Represents the Id of the customer's address book entry to edit. If null, creates a new addressbook entry for the customer. |
integer |
Minimum value: 1 |
LocationId |
The id of a customer location this entry is for. Null means customer level. Populated means location level. |
integer |
Minimum value: 1 |
FirstName |
The First name of the entry |
string |
Max length: 100 |
LastName |
The Last name of the entry |
string |
Max length: 100 |
PhoneNumber |
The phone number of the entry |
string |
Max length: 50 |
EmailAddress |
The email address of the entry |
string |
Max length: 128 |
Address |
The Address of the entry |
AddressBookAdress |
Required |
AddressValidationBypassed |
Was the address validation performed or bypassed. |
boolean |
Required |
CompanyName |
The associated Company name of the entry |
string |
Max length: 100 |
VatCode |
The VAT code for the entry |
string |
Max length: 50 |
LocationCode |
A customer designated location code for the entry |
string |
Max length: 50 |
LocationName |
A customer designated location name for the entry |
string |
Max length: 120 |
RelatedConsigneeId |
The ID of a related consignee addressbook entry. Used during international shipping. |
integer |
Minimum value: 1 |
TradeLocation |
Is the entry identified as a Trade Location. Makes a difference during international shipping. |
boolean |
None. |
Consignee |
Is the entry a Consignee entry for use during international shipping. |
boolean |
None. |
Request Formats
application/json, text/json
{ "AddressBookEntryId": 1, "LocationId": 1, "FirstName": "sample string 1", "LastName": "sample string 2", "PhoneNumber": "sample string 3", "EmailAddress": "sample string 4", "Address": { "City": "sample string 1", "Street1": "sample string 2", "Street2": "sample string 3", "Region": "sample string 4", "Postalcode": "sample string 5", "PostalZip4": "sample string 6", "CountryCode": "sample string 7" }, "AddressValidationBypassed": true, "CompanyName": "sample string 6", "VatCode": "sample string 7", "LocationCode": "sample string 8", "LocationName": "sample string 9", "RelatedConsigneeId": 1, "TradeLocation": true, "Consignee": true }
application/xml, text/xml
<CustomerAddressBookEntryUpdateRequest xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <AddressBookEntryId>1</AddressBookEntryId> <LocationId>1</LocationId> <FirstName>sample string 1</FirstName> <LastName>sample string 2</LastName> <PhoneNumber>sample string 3</PhoneNumber> <EmailAddress>sample string 4</EmailAddress> <Address> <Street1>sample string 2</Street1> <Street2>sample string 3</Street2> <City>sample string 1</City> <Region>sample string 4</Region> <Postalcode>sample string 5</Postalcode> <PostalZip4>sample string 6</PostalZip4> <CountryCode>sample string 7</CountryCode> </Address> <AddressValidationBypassed>true</AddressValidationBypassed> <CompanyName>sample string 6</CompanyName> <VatCode>sample string 7</VatCode> <LocationCode>sample string 8</LocationCode> <LocationName>sample string 9</LocationName> <RelatedConsigneeId>1</RelatedConsigneeId> <TradeLocation>true</TradeLocation> <Consignee>true</Consignee> </CustomerAddressBookEntryUpdateRequest>
application/x-www-form-urlencoded
Sample not available.
Response Information
Resource Description
An object containing basic information on the modified entry.
CustomerAddressBookEntryUpdateResponseName | Description | Type | Additional information |
---|---|---|---|
AddressBookEntryId |
The LocationId of the modified address book entry. |
integer |
None. |
Response Formats
application/json, text/json
{ "AddressBookEntryId": 1 }
application/xml, text/xml
<CustomerAddressBookEntryUpdateResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <AddressBookEntryId>1</AddressBookEntryId> </CustomerAddressBookEntryUpdateResponse>