Say exactly what went wrong
Name the mistake in plain words and the effect on the customer. Avoid phrases like any inconvenience, which sound like a script.
Take responsibility without excuses
Say it was your mistake. Give a reason only if it helps the customer trust the fix, and never use it to shift blame.
Fix the problem first
Whenever possible, solve the issue before or in the same message. An apology without a fix reads as an empty gesture.
Offer something proportionate
A refund, credit or extension should match the harm. Decide the range in advance so agents do not invent offers case by case.
Say what changes
If you know what you will do differently, say it in one sentence. If you do not know yet, say when you will report back.
Follow up later
Check in after a week or when the fix has run. A short follow-up shows the apology was meant.