Seek early legal advice. Depending on the circumstances, your best bet may be to repudiate the contract as soon as possible, in the hope of limiting any losses made by the other party in relying on it. But take advice, both on resolving this situation, and on ensuring you do not get caught with this kind of vicarious liability in future.