You have a written contract. Does that contract provide them this right? What does it say about required repairs after the work? What does it say about warranties? What does it say about dispute resolution? Why didn't you provide for indemnification over issues with the GC selection of the product? If they selected this product your contract should have shifted responsibility to them.
Without seeing the contract there is no way anyone can advise you about your possible rights and duties. You need to speak with a local construction lawyer. Good luck.
This answer is for informational purposes only and is not legal advice regarding your question and does not establish an attorney-client relationship.
You always have the right to demand money back. The real question is whether the subcontractor has any obligation to comply with the demand and actually issue a refund to the GC. There are not nearly enough facts in your question to be able to adequately answer it. The starting point is going to be analyzing the contract between the subcontractor and the GC to see what the terms say. There may be a dispute resolution provision in there, a default notice provision, a requirement to submit a dispute to the architect in the first instance, or any other number of clauses that could change how to analyze this issue. If the subcontractor followed the building specifications provided by the general contractor, then he should generally be ok. However, a contractor cannot knowingly build something that is improper or deficient and then say that he/she/it was told to do it that way. The subcontractor should have formally notified the GC and the owner that the method required by the GC was incorrect and that the subcontractor could not proceed with installing insufficient or improper materials.