system
Given the following post, respond as if you're commenting on Reddit:
human
[The Prestige] If the Tesla hint was a ruse, how did Tesla know what machine Angier was talking about?

Only two things are possible: either Tesla and his assistant react honestly: "what machine are you talking about? to do what?" or they jump immediately on the chance of deceiving a random man asking for stuff by going "of course".    

(Since Tesla was in financial trouble and did take Angier's money, we're lead to believe the latter, although I guess that the idea is that he didn't defraud Angier, since Tesla did build a machine, just charged him "too much", which is no fraud considering it's a unique machine that could be built by only one man in history and worth more than anything else in the world, probably. Or maybe the "fraud" part would have been in Tesla using most of his time still to work on his projects while leaving Angier's machine as a little side project for little time. )  

We're  never shown the former.  

 The problem is, the latter can't be accomplished without knowing what he's talking about. And yet we're never shown them asking "what did the machine do again?". This would have obviously tipped off Angier too much.   

So in the end, it seems that the movie doesn't show either and tricks the audience because it doesn't have a believable answer.
gpt
We only see snippets of the conversations between Angier and Tesla, but it appears that Tesla was hosting him. So presumably they had several days to really drill down into what Angier was looking for. Also, the rivalry between Angier and Borden might have been widely known, so Tesla may have figured it out based on the nature of their competition. 

It's possible that Borden's ruse was based on some subconscious association he had about Tesla's actual experiments.  He might have heard him speak or heard someone talking about his theories and internalized the knowledge. Then when writing his coded journal, he pulled what he thought was a completely false lead,  but it was in fact his brain making the connection between his trick and Tesla's actual work.