Preheat oven to 350 degrees F. Line a baking sheet with parchment paper and set aside.
In a medium bowl, combine flour, baking powder, baking soda, salt, pistachios, and cranberries. Stir to combine.
In an electric stand mixer fitted with a paddle attachment, cream butter and sugar together on medium speed for 1 1/2 minutes. Add vanilla and eggs; mix until combined. Add the dry ingredients and mix on low speed until just combined to make a dough.
Form the dough into one long log, about 12-18 inches long and 5-6 inches thick. The dough should be relatively flat, only about 1/2 inch high. Bake for 20-25 minutes, until the center is firm to the touch. Let the biscotti cool for 15 minutes and then, using a serrated knife; cut into 1 inch wide pieces. Lay each slice on its side. Turn the oven down to 325 degrees and bake for an additional 5-6 minutes on each side. Cool completely.
Melt chocolate in a heatproof bowl set over a pot of simmering water. Dip biscotti in chocolate or drizzle over biscotti, as desired.