Preheat oven to 350. Line a baking tray with parchment paper–set aside. Combine the first 8 ingredients in a bowl and combine. In a separate bowl, combine the flax egg, coconut oil, and melted chocolate. Pour the wet ingredients into the dry ingredients and mix together. Then, fold in the pistachio pieces. Using a tablespoon, scoop the dough onto the prepared baking tray (if you want, you may shape/flatten the cookies with your hands). Bake for 10 minutes. Remove cookies from the oven and let them cool completely before serving.