Sprayed foam sealant into window blind's headrail, immobilizing it. Blinds are also screwed directly into frame. How to remove (has picture)
If I understand correctly, you've sprayed expanding foam into the head of your blinds. It has now fully encased all the working mechanism of the blinds - the rods, gears, strings, etc.

You could take the blinds down, remove as many external parts as you can, then with a series of small picks, knives, scoops, etc. dig at the foam for several hours, attempting to get it out of every nook and cranny.

Once you get to pieces like gears, you can attempt to disassemble the mechanism to carefully scrape all the foam off the gears to ensure they'll mesh properly when called upon to turn and not to jam up against a wayward blob of foam.

When you find a pull string, you can attempt to carefully scrape the foam off the string with a putty knife, your fingers/fingernails, or whatever else you can come up with to get the foam out of the threads.


Since, at this particular point in history, many of us find ourselves under involuntary house arrest, you may well have plenty of time to undertake this endeavor and find you have nothing better to do.
If, however, you value your sanity and have better things to do with your time, I'd suggest:

Pitch the blinds
Buy and install a new set
Consider this a lesson learned

It is fairly simple to remove most window blinds, generally just pull it from 2 or 3 clips. It's usually worth doing so for any window-area maintenance to prevent damage to the blinds as repairing them is generally a pain.

Based on updated info provided in a comment on this post:
The OP indicated that these blinds weren't installed properly in the first place. Instead of using the proper clips to mount them, it seems that the head unit was screwed directly into the window frame. In this case, cutting the blinds apart to get to the foam hiding the screws is probably the only way.
Whether using a Sawzall™-type reciprocating saw, an oscillating flush-cutter, or even a manual hacksaw, the logical way would be to slip the blade between the top of the head unit and the window frame, slide it along until it catches, then start sawing to cut through the obstruction (which may be a screw, or just a snug part of the blinds/frame interface).
The drawback to this method is that the blade is very likely to damage the window frame. At a minimum, you'll end up scraping up the finish. Worst case, you may cut into the sash frame itself, and if it's vinyl, you may cut into one of the open pockets inside and really destroy some of the structural integrity of the sash.
If you happen to know roughly where the screws were, it might be reasonable to dig the foam out around this area, then unscrew the mounting screws. In order to prevent damage to the frame/sashes, this may be the only way to safely remove the head.
You might, if you're careful, be able to cut off the front of the head to give you more access to the foam to make it easier to cut it out to get to the screws. If you happen to know &quot;the moron&quot; (OP's words) who installed this, he may be able to give you a rough idea where he put the screws to minimize the amount of foam you'll have to remove.