The item, 'Plan: Staff of Herding' is needed to teach the Blacksmith how to craft the Staff of Herding in order to unlock Whimsyshire. You will find this plan after killing the boss Izual at the start of Act IV's Prime Evil quest. Choose begin quest and enter the spire, tearing through the spires until you reach Izual. Defeat him until he drops the Plan. I tried 5 times until he eventually dropped it.
Once obtained, take the Plan: Staff of Herding to the Blacksmith, click on craft, then right-click your new-found plan to teach the Blacksmith the recipe. You will also earn an achievement for teaching the Blacksmith a plan, unless you already found some exalted plans earlier. Once the plan has been learnt, scroll down the Blacksmith's weapon crafting list and look for Staffs. There you will find your Staff of Herding plan ready to be used for crafting the Staff of Herding.
Now all that's needed is that you meet the Cow from Diablo II so that he may grant you passage into Whimsyshire after teasing you a bit with the Cow Level's history... such nostalgia. Give him the staff and enter the pinkish-aura'd canyon that appears afore ye Nephalem!
Image source: http://www.d3rmt.com/guides/diablo-3-secret-level-guide/