forgot …; ended up forgetting …The particle を marks what was forgotten. しまって is the connecting form of しまう and can convey regret or that the forgetting happened unintentionally.
JA: 大切な約束を忘れてしまって、本当に申し訳ありません。
EN: I completely forgot about an important appointment, and I’m really sorry.