Skip to content

Commit 80fe4cb

Browse files
committed
Implemented find method on Stories module
1 parent dafafc5 commit 80fe4cb

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

lib/extracker/stories.ex

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,22 @@ defmodule ExTracker.Stories do
22
import ExTracker
33
alias Extracker.Client
44

5+
@doc """
6+
Get a single `story`.
7+
8+
## Example
9+
10+
ExTracker.Stories.find("12345", "67890", client)
11+
12+
More info at: https://www.pivotaltracker.com/help/api/rest/v5#Story
13+
"""
14+
@spec find(pos_integer, pos_integer, Client.t, [{atom, binary}] | []) :: ExTracker.Record.Story.t
15+
def find(project_id, story_id, client, params \\ []) do
16+
get("projects/#{project_id}/stories/#{story_id}", client, params)
17+
|> ExTracker.Parser.parse_story
18+
end
19+
20+
521
@doc """
622
Get all stories from project
723

0 commit comments

Comments
 (0)