Customer Addresses
Manage shipping and billing addresses.
Updated
On this page
Overview
Customer addresses are stored as part of the customer profile. The primary address is used as the default shipping address during checkout.
Reading the Address
import dash from "@/lib/dash"
const { customer } = await dash.auth.getProfile()
if (customer.has_address) {
const addr = customer.address
console.log(addr.address_line1) // "123 Main St"
console.log(addr.city) // "Austin"
console.log(addr.state) // "TX"
console.log(addr.zip_code) // "78701"
console.log(addr.country) // "US"
}