Skip to content

Instantly share code, notes, and snippets.

@hpneo
Created September 17, 2019 20:57
Show Gist options
  • Save hpneo/98b38776f1f7a5f1ccf0827750854019 to your computer and use it in GitHub Desktop.
Save hpneo/98b38776f1f7a5f1ccf0827750854019 to your computer and use it in GitHub Desktop.
PivotalTracker API description

Models

  • PivotalTrackerProject:
    • id
    • name
    • memberships (list of users assigned to that project, could be a list of e-mails)
  • PivotalTrackerStory:
    • pivotal_tracker_project_id
    • id
    • name
    • kind
    • story_type
    • estimate
    • created_at
    • transitions (list of state changes, indicating the final state of each change. See Transitions)
    • current_state
    • accepted_at

Endpoints

{
   "epics":
   {
       "epics":
       [
       ],
       "total_hits": 0
   },
   "query": "label:mnt AND includedone:true",
   "stories":
   {
       "stories":
       [
           {
               "kind": "story",
               "id": 566,
               "created_at": "2019-09-17T12:00:00Z",
               "updated_at": "2019-09-17T12:00:05Z",
               "story_type": "feature",
               "name": "Clean Cell Block 1138",
               "description": "The large, hairy _Thing_ is being transferred away",
               "current_state": "unstarted",
               "requested_by_id": 104,
               "project_id": 99,
               "url": "http://localhost:3000/story/show/566",
               "owner_ids":
               [
               ],
               "labels":
               [
                   {
                       "id": 2010,
                       "project_id": 99,
                       "kind": "label",
                       "name": "mnt",
                       "created_at": "2019-09-17T12:00:00Z",
                       "updated_at": "2019-09-17T12:00:00Z"
                   }
               ]
           },
           {
               "kind": "story",
               "id": 564,
               "created_at": "2019-09-17T12:00:00Z",
               "updated_at": "2019-09-17T12:00:10Z",
               "story_type": "feature",
               "name": "Reactor leak reported in Detention Block AA-23",
               "description": "large leak, very dangerous",
               "current_state": "unstarted",
               "requested_by_id": 103,
               "project_id": 99,
               "url": "http://localhost:3000/story/show/564",
               "owner_ids":
               [
               ],
               "labels":
               [
                   {
                       "id": 2010,
                       "project_id": 99,
                       "kind": "label",
                       "name": "mnt",
                       "created_at": "2019-09-17T12:00:00Z",
                       "updated_at": "2019-09-17T12:00:00Z"
                   }
               ]
           }
       ],
       "total_points": 0,
       "total_points_completed": 0,
       "total_hits": 2,
       "total_hits_with_done": 2
   }
}  

Note: Each story in the results should include transitions (described in the Models section).

Note: We don't use labels or epics from the response, but it would be helpful to have the linked PivotalTracker id from each story, so we can match them between Fino and Pivotal Tracker to avoid duplicated stories.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment