The easiest way to think about this is to first take the sentence without the は
No problems here--it just means "we have two sons". But somehow this sounds dry and out of context, as if someone were answering a question that had not been asked, proffering information that seems too direct and unmodulated.
We can use は in a way very similar to how it's used as the so-called "subject" particle, but since we are applying it to the 私たち in this sentence the grammatical role of which here is indicated by a に, it becomes には. Like its use elsewhere, the は softens and contextualizes around the 私たち. To exaggerate a bit, the nuance becomes "Oh, you want to know who many kids WE have, well, in our case, it's two boys."
Once you get this down, you should be able to figure out similar patterns such as へは or とは, and even the somewhat archaic をば which derives from をは.