Log in
Interface

AddressInterface

Magento\Customer\Api\Data\AddressInterface

What it does

This interface defines the data contract for customer addresses in Magento 2.

Developers use it to retrieve and manipulate customer address information including street, city, region, country, contact details, and shipping/billing defaults.

It's commonly used when working with customer address data through APIs, custom modules, or when extending address-related functionality.

Public Methods

  • getId()
  • setId()
  • getCustomerId()
  • setCustomerId()
  • getRegion()
  • setRegion()
  • getRegionId()
  • setRegionId()
  • getCountryId()
  • setCountryId()
  • getStreet()
  • setStreet()
  • getCompany()
  • setCompany()
  • getTelephone()
  • setTelephone()
  • getFax()
  • setFax()
  • getPostcode()
  • setPostcode()
  • getCity()
  • setCity()
  • getFirstname()
  • setFirstname()
  • getLastname()
  • setLastname()
  • getMiddlename()
  • setMiddlename()
  • getPrefix()
  • setPrefix()
  • getSuffix()
  • setSuffix()
  • getVatId()
  • setVatId()
  • isDefaultShipping()
  • setIsDefaultShipping()
  • isDefaultBilling()
  • setIsDefaultBilling()
  • getExtensionAttributes()
  • setExtensionAttributes()