An update to this answer for version 2025.03:
First get transaction ids:
SHOW TRANSACTIONS
TERMINATE TRANSACTIONS ["mydb-transaction-1", "mydb-transaction-2", "mydb-transaction-3"]
where mydb-trasaction-* are the transaction ID's from SHOW TRANSACTIONS