I can show you how to handle customer overpayment for future services in QuickBooks Online. The way you record them in the system will depend on how it happens in the actual scenario.
It's only advisable to apply a credit if they want to continue and use the overpayment to the future invoices. Since the customer canceled the prepayment, you can use Check or Expense to record the refund.
Click the + New button.
Select Expense or Check.
Choose the customer you want to refund from the Payee ▼ drop-down.
From the Payment account ▼ drop-down, select thebank account where you deposited the overpayment.
On the first line of the Category column, select Accounts Receivable.
Enter the refund in the Amount field.
Fill out the other fields, then select Save and close.