Expand my Community achievements bar.

Get ready! An upgraded Experience League Community experience is coming in January.
SOLVED

Events API : customer_save_commit_after returning empty addresses and company_attributes

Avatar

Level 4

I am working with Adobe Commerce Events and subscribing to the event:
observer.customer_save_commit_after

{
  "event": {
    "name": "observer.customer_save_commit_after",
    "fields": [
      {"name": "id"},
      {"name": "email"},
      {"name": "group_id"},
      {"name": "website_id"},
      {"name": "firstname"},
      {"name": "lastname"},
      {"name": "taxvat"},
      {"name": "created_at"},
      {"name": "updated_at"},
      {"name": "addresses[].street"},
      {"name": "addresses[].city"},
      {"name": "addresses[].postcode"},
      {"name": "addresses[].country_id"},
      {"name": "addresses[].region.region_code"},
      {"name": "addresses[].telephone"},
      {"name": "extension_attributes.company_attributes.company_id"}
    ]
  }
}

However, the actual event payload I receive looks like this:

"data": {
  "key": "xxxx",
  "value": {
    "id": 44,
    "email": "shubham@gmail.com",
    "group_id": 1,
    "website_id": 2,
    "firstname": "Tushar",
    "lastname": "S",
    "taxvat": "",
    "created_at": "2025-10-30 07:15:35",
    "updated_at": "2025-12-08 11:51:35",
    "addresses": [],
    "extension_attributes": {
      "company_attributes": {}
    }
  }
}

Even though the customer has addresses and is part of a B2B company, the event always returns:

  • addresses[] → empty

  • extension_attributes.company_attributes → emptyDoes customer_save_commit_after Only provide a partial customer object?

1 Accepted Solution

Avatar

Correct answer by
Level 3

@ShubhamAg2 

 

According to Adobe Commerce standards and the details from events:info, this should function correctly.

bin/magento events:info observer.customer_save_commit_after --depth=4

 

However, you might want to try this fix, which could work for you:

{
  "event": {
    "name": "observer.customer_save_commit_after",
    "fields": [
      ...
      {"name": "company_attributes.company_id"}
      ...      
    ]
  }
}

 

View solution in original post

1 Reply

Avatar

Correct answer by
Level 3

@ShubhamAg2 

 

According to Adobe Commerce standards and the details from events:info, this should function correctly.

bin/magento events:info observer.customer_save_commit_after --depth=4

 

However, you might want to try this fix, which could work for you:

{
  "event": {
    "name": "observer.customer_save_commit_after",
    "fields": [
      ...
      {"name": "company_attributes.company_id"}
      ...      
    ]
  }
}