Created GetStories function.