Unfortunately they will not provide you your score for free.
I recommend that you check with any loan officer to get a copy of your credit report. Let them know that you are interested to purchase a house.
Most lenders will request a minimum of 3 years.
However, depending on how good is your credit, some lender will take the risk to lend you again.
Morelikely if you have a substantial downpayment.
Let me know if you need more info on this matter.
You could be looking at anywhere from 2 year to 7 years depending on the circumstances of your foreclosure. You could also expect that when you can qualify for a mortgage again that your lender will expect at least a 10% down payment or more.