Addresses can be accessed through the API via the addresses base URL:

$ curl
  • Supported list methods: GET, POST
  • Supported detail methods: GET PUT DELETE

Addresses are also frequently accessed as sub-resources of either orders or customers. Please see the documentation for those resources for specific rules that may apply depending on whether the address is a bill-to or ship-to.

Points to note

  • An address that is the billTo of a customer cannot be deleted, nor can you change which customer it belongs to. When a customer is created its bill-to address is created at the same time and the two are connected to each other for life.

  • An address cannot be both a bill-to and ship-to at once (i.e. at least one of btCustomer and stCustomer must be null). In Handshake, the customer's bill-to is always available as a choice for the ship-to address on an order, so there is no need to add it to the customer's shipTos collection in order actually use it as a ship-to.

  • Addresses that are not connected to any customer (as either the bill-to or an additional ship-to) and are not connected to any sales order (as either the bill-to or ship-to) will be automatically deleted by the giant vacuum cleaner that stalks our datacenter.

Fields (string) (string)
address.street (string)
address.street2 (string) (string)
address.state (string)
address.postcode (string) (string) (string)
address.fax (string)
address.multiLineStr (readonly string)

Returns a 2-4 line string representing the location part of this address as seen in various places throughout Handshake, e.g.:

198 Fifth Ave 
Apt 3F 
New York NY 10012 US

If you're rendering an address in an HTML template, you should probably render it using the linebreaksbr filter. See the template filter documentation for more information.

<p>{{ address.multiLineStr | linebreaksbr }}</p>
address.btCustomer (readonly reference to Customer)

The customer that this is the bill-to address of, or null if this address is not the bill-to address for any customer.

address.stCustomer (reference to Customer)

The customer that this is an additional ship-to address of, or null if this address is not an additional ship-to address for any customer.


  "street":"8051 Brown Road",
Next: Credit Cards

Recent Discussions

28 Dec, 2012 03:29 AM
26 Dec, 2012 08:57 PM
17 Dec, 2012 11:37 PM