Log in
Interface

AbstractCarrierInterface

Magento\Shipping\Model\Carrier\AbstractCarrierInterface

What it does

This interface defines the contract that all shipping carrier implementations in Magento 2 must follow.

Developers use this interface when creating custom shipping methods or integrating third-party carriers (like UPS, FedEx, DHL) to ensure they implement all required functionality such as rate calculation, shipment creation, tracking, and validation.

Any class implementing this interface can be used as a shipping carrier in Magento's checkout process.

Public Methods

  • getConfigData()
  • collectRates()
  • requestToShipment()
  • returnOfShipment()
  • getContainerTypes()
  • getCustomizableContainerTypes()
  • getDeliveryConfirmationTypes()
  • checkAvailableShipCountries()
  • proccessAdditionalValidation()
  • isActive()
  • isFixed()
  • isTrackingAvailable()
  • isShippingLabelsAvailable()
  • getSortOrder()
  • getFinalPriceWithHandlingFee()
  • getTotalNumOfBoxes()
  • isStateProvinceRequired()
  • isCityRequired()
  • isZipCodeRequired()
  • debugData()
  • getCarrierCode()
  • getContentTypes()