Resources

Contents

Resource summary

Users get all users
get user
GET /users
GET /user/{userId}
 
Projects get all projects
get project
GET /projects
GET /project/{projectId}
 
Iterations get all iterations GET /project/{projectId}/iterations  
User stories get all user stories
create user story

get all user stories in current iteration
create user story in current iteration

get all user stories in given iteration
create user story in given iteration

get user story
update user story
delete user story
GET /project/{projectId}/userstories
POST /project/{projectId}/userstories

GET /project/{projectId}/iteration/current/userstories
POST /project/{projectId}/iteration/current/userstories

GET /iteration/{iterationId}/userstories
POST /iteration/{iterationId}/userstories

GET /userstory/{userStoryId}
PUT /userstory/{userStoryId}
DELETE /userstory/{userStoryId}






since v2.6
since v2.6
Tasks get all tasks for user story
create task

get task
update task
delete task
GET /userstory/{userStoryId}/tasks
POST /userstory/{userStoryId}/tasks

GET /task/{taskId}
PUT /task/{taskId}
DELETE /task/{taskId}
 
Comments get user story comments
add user story comment

get task comments
add task comment
GET /userstory/{userStoryId}/comments
POST /userstory/{userStoryId}/comments

GET /task/{taskId}/comments
POST /task/{taskId}/comments
since v2.6
since v2.6

since v2.6
since v2.6
Timesheet get iteration timesheet entries
get single task timesheet
update task timesheet
GET /iteration/{iterationId}/timesheet
GET /task/{taskId}/timesheet
POST /task/{taskId}/timesheet
since v2.6
since v2.6
since v2.6

Users

GET /users Returns all users.

  • Request
    GET http://localhost:8080/tinypm/api/users
  • Response
    <users>
      <user>
        <active>true</active>
        <id>1</id>
        <name>Alice</name>
      </user>
      <user>
        <active>false</active>
        <id>2</id>
        <name>Bob</name>
      </user>
    </users>
    

GET /user/{userId} Returns a single user identified by userId.

  • Request
    GET http://localhost:8080/tinypm/api/user/1
  • Response
    <user>
      <id>1</id>
      <name>Alice</name>
      <login>alice</login>
      <email>alice@nowhere.com</email>
      <active>true</active>
      <initials>A</initials>
    </user>
    

Projects

GET /projects Returns all projects.

  • Request
    GET http://localhost:8080/tinypm/api/projects
  • Response
    <projects>
        <project>
          <active>true</active>
          <code>tpm</code>
          <id>1</id>
          <name>tinyPM</name>
        </project>
        <project>
          <active>false</active>
          <code>sup</code>
          <id>14</id>
          <name>Support</name>
        </project>
     </projects>
    

GET /project/{projectId} Returns a single project identified by projectId.

  • Request
    GET http://localhost:8080/tinypm/api/project/1 
  • Response
    Since v2.6 project data contain list of taskStatuses as now they can be customized in each project.
    Changing task status through API now requires providing valid taskStatusId
<project>
  <id>1</id>
  <code>tpm</code>
  <name>tinyPM</name>
  <description>Best agile management tool.</description>
  <!-- short date format: yyyy-MM-dd -->
  <startDate>2006-04-01</startDate>
  <targetFinishDate>2067-04-01</targetFinishDate>
  <owner>
    <id>1</id>
    <name>Alice</name>
    <login>alice</login>
    <email>alice@nowhere.com</email>
    <active>true</active>
  </owner>
  <taskStatuses>
    <status>
      <id>1</id>
      <name>TO DO</name>
    </status>
    <status>
      <id>2</id>
      <name>IN PROGRESS</name>
    </status>
    <status>
      <id>4</id>
      <name>TESTING</name>
    </status>
    <status>
      <id>3</id>
      <name>COMPLETED</name>
    </status>
  </taskStatuses>
  <estimates>
    <value>0.0</value>
    <value>0.5</value>
    <value>1.0</value>
    <value>2.0</value>
    <value>3.0</value>
    <value>5.0</value>
    <value>8.0</value>
    <value>13.0</value>
    <value>20.0</value>
    <value>40.0</value>
    <value>80.0</value>
    <value>100.0</value>
  </estimates>
  <taskEstimates>
    <value>0.0</value>
    <value>1.0</value>
    <value>2.0</value>
    <value>3.0</value>
    <value>4.0</value>
    <value>5.0</value>
    <value>6.0</value>
    <value>7.0</value>
    <value>8.0</value>
  </taskEstimates>
  <iterationLength>14</iterationLength>
  <defaultTask>Implement and test user story &quot;{0}&quot;.</defaultTask>
  <active>true</active>
</project>

Iterations

GET /project/{projectId}/iterations Returns all iterations for a given project.

  • Request
     GET http://localhost:8080/tinypm/api/project/1/iterations 
  • Response
    <iterations>
      <iteration>
        <id>1</id>
        <name>Iteration 1</name>
        <goal>Goal</goal>
        <plannedVelocity>20.0</plannedVelocity>
        <position>1</position>
        <!-- short date format: yyyy-MM-dd -->
        <startDate>2006-04-01</startDate>
        <duration>7</duration>
      </iteration>
      <iteration>
        <id>2</id>
        <name>Iteration 2</name>
        <goal>Goal</goal>
        <plannedVelocity>20.0</plannedVelocity>
        <position>2</position>
        <startDate>2006-04-01</startDate>
        <duration>7</duration>
      </iteration>
    </iterations>
    

User stories

GET /project/{projectId}/userstories Returns all user stories for a given project.

  • Request
    GET http://localhost:8080/tinypm/api/project/1/userstories 
  • Query Parameters
    Since v2.4.1 this resource provides filtering capabilities and supports following query paramters
    name possible values / format
    ownerId int
    priority MUST_HAVE, SHOULD_HAVE, COULD_HAVE, WONT_HAVE
    status PENDING, IN_PROGRESS, COMPLETED
    createdAtFrom yyyyMMdd
    createdAtTo yyyyMMdd
  • Response
    Since v2.6 user story listings provide also iteration identifier, position within iteration and user story tags
<userStories>
  <userStory>
    <id>1</id>
    <name>As an editor I want to be able to publish a new topic.</name>
    <iterationId>1</iterationId>
    <position>0</position>
    <tags>
      <tag>editors</tag>
      <tag>publishing</tag>
    </tags>
  </userStory>
  <userStory>
    <id>2</id>
    <name>As an editor I want to be able to browse drafts.</name>
    <iterationId>1</iterationId>
    <position>1</position>
    <tags>
      <tag>drafts</tag>
      <tag>editors</tag>
    </tags>
  </userStory>
</userStories>

POST /project/{projectId}/userstories Creates a new unassigned user story.

  • Request
    Since v2.6 creating user story does not create default tasks at the same time unless explicitly specified with query parameter addDefaultTasks=true
POST http://localhost:8080/tinypm/api/project/1/userstories?addDefaultTasks=false 
<userStory>
  <name>As an editor I want to be able to publish a new topic.</name>
  <description>Each topic has to have a unique title.</description>
  <!-- priority: 1-MUST_HAVE, 2-SHOULD_HAVE, 3-COULD_HAVE, 4-WONT_HAVE -->
  <priority>
    <id>1</id>
    <name>MUST_HAVE</name>
    <priority>1</priority>
  </priority>
  <estimatedEffort>3.0</estimatedEffort>
  <!-- color: WHITE, YELLOW, ORANGE, RED, GREEN, BLUE -->
  <color>BLUE</color>
  <owner>
    <id>2</id>
  </owner>
  <acceptingUser>
    <id>1</id>
  </acceptingUser>
  <!-- acceptanceStatus: PENDING, ACCEPTED, REJECTED -->
  <acceptanceStatus>ACCEPTED</acceptanceStatus>
</userStory>
  • Response
    Since v2.6 response contains also id of the created object.
<userStory>
  <id>1</id>
</userStory>

GET /project/{projectId}/iteration/current/userstories Returns all stories in the current iterartion.

  • Request
    GET http://localhost:8080/tinypm/api/project/1/iteration/current/userstories 
  • Response
    Since v2.6 user story listings provide also iteration identifier, position within iteration and user story tags
<userStories>
  <userStory>
    <id>1</id>
    <name>As an editor I want to be able to publish a new topic.</name>
    <iterationId>1</iterationId>
    <position>0</position>
    <tags>
      <tag>editors</tag>
      <tag>publishing</tag>
    </tags>
  </userStory>
  <userStory>
    <id>2</id>
    <name>As an editor I want to be able to browse drafts.</name>
    <iterationId>1</iterationId>
    <position>1</position>
    <tags>
      <tag>drafts</tag>
      <tag>editors</tag>
    </tags>
  </userStory>
</userStories>

POST /project/{projectId}/iteration/current/userstories Creates a new user story in the current iteration.

  • Request
    Since v2.6 creating user story does not create default tasks at the same time unless explicitly specified with query parameter addDefaultTasks=true
POST http://localhost:8080/tinypm/api/project/1/iteration/current/userstories?addDefaultTasks=false 
<userStory>
  <name>As an editor I want to be able to publish a new topic.</name>
  <description>Each topic has to have a unique title.</description>
  <!-- priority: 1-MUST_HAVE, 2-SHOULD_HAVE, 3-COULD_HAVE, 4-WONT_HAVE -->
  <priority>
    <id>1</id>
    <name>MUST_HAVE</name>
    <priority>1</priority>
  </priority>
  <estimatedEffort>3.0</estimatedEffort>
  <!-- color: WHITE, YELLOW, ORANGE, RED, GREEN, BLUE -->
  <color>BLUE</color>
  <owner>
    <id>2</id>
  </owner>
  <acceptingUser>
    <id>1</id>
  </acceptingUser>
  <!-- acceptanceStatus: PENDING, ACCEPTED, REJECTED -->
  <acceptanceStatus>ACCEPTED</acceptanceStatus>
</userStory>
  • Response
    Since v2.6 response contains also id of the created object.
    <userStory>
      <id>1</id>
    </userStory>
    

GET /iteration/{iterationId}/userstories Returns all stories in the given iterartion.

  • Request
    GET http://localhost:8080/tinypm/api/iteration/1/userstories 
  • Response
    Since v2.6 user story listings provide also iteration identifier, position within iteration and user story tags
<userStories>
  <userStory>
    <id>1</id>
    <name>As an editor I want to be able to publish a new topic.</name>
    <iterationId>1</iterationId>
    <position>0</position>
    <tags>
      <tag>editors</tag>
      <tag>publishing</tag>
    </tags>
  </userStory>
  <userStory>
    <id>2</id>
    <name>As an editor I want to be able to browse drafts.</name>
    <iterationId>1</iterationId>
    <position>1</position>
    <tags>
      <tag>drafts</tag>
      <tag>editors</tag>
    </tags>
  </userStory>
</userStories>

POST /iteration/{iterationId}/userstories Creates a new user story within given iteration.

  • Request
    Since v2.6 creating user story does not create default tasks at the same time unless explicitly specified with query parameter addDefaultTasks=true
POST http://localhost:8080/tinypm/api/iteration/1/userstories?addDefaultTasks=false 
<userStory>
  <name>As an editor I want to be able to publish a new topic.</name>
  <description>Each topic has to have a unique title.</description>
  <!-- priority: 1-MUST_HAVE, 2-SHOULD_HAVE, 3-COULD_HAVE, 4-WONT_HAVE -->
  <priority>
    <id>1</id>
    <name>MUST_HAVE</name>
    <priority>1</priority>
  </priority>
  <estimatedEffort>3.0</estimatedEffort>
  <!-- color: WHITE, YELLOW, ORANGE, RED, GREEN, BLUE -->
  <color>BLUE</color>
  <owner>
    <id>2</id>
  </owner>
  <acceptingUser>
    <id>1</id>
  </acceptingUser>
  <!-- acceptanceStatus: PENDING, ACCEPTED, REJECTED -->
  <acceptanceStatus>ACCEPTED</acceptanceStatus>
</userStory>
  • Response
    Since v2.6 response contains also id of the created object.
    <userStory>
      <id>1</id>
    </userStory>
    

GET /userstory/{userStoryId} Returns a single user story.

  • Request
    GET http://localhost:8080/tinypm/api/userstory/3 
  • Response
    <userStory>
      <id>3</id>
      <name>As an editor I want to be able to publish a new topic.</name>
      <description>Each topic has to have a unique title.</description>
      <!-- priority: 1-MUST_HAVE, 2-SHOULD_HAVE, 3-COULD_HAVE, 4-WONT_HAVE -->
      <priority>
        <id>1</id>
        <name>MUST_HAVE</name>
        <priority>1</priority>
      </priority>
      <estimatedEffort>3.0</estimatedEffort>
      <iteration>
        <id>2</id>
        <name>Iteration 2</name>
        <goal>Goal</goal>
        <plannedVelocity>20.0</plannedVelocity>
        <position>2</position>
        <!-- short date format: yyyy-MM-dd -->
        <startDate>2006-04-01</startDate>
        <duration>7</duration>
      </iteration>
      <!-- color: WHITE, YELLOW, ORANGE, RED, GREEN, BLUE -->
      <color>BLUE</color>
      <acceptingUser>
        <id>1</id>
        <name>Alice</name>
        <login>alice</login>
        <email>alice@nowhere.com</email>
        <active>true</active>
      </acceptingUser>
      <owner>
        <id>2</id>
        <name>Bob</name>
        <login>bob</login>
        <email>bob@nowhere.com</email>
        <active>true</active>
      </owner>
      <!-- acceptanceStatus: PENDING, ACCEPTED, REJECTED -->
      <acceptanceStatus>ACCEPTED</acceptanceStatus>
      <comments>
        <comment>
          <author>Demo User</author>
          <date>2011-08-24 13:17:23.000</date>
          <body>
            This story should probably include all kinds of users?
          </body>
        </comment>
      </comments>
    </userStory>
    

PUT /userstory/{userStoryId} Updates an existing user story.

You have to provide a complete replacement for the resource. If you omit any xml node, the property will get null value.

  • Request
    PUT http://localhost:8080/tinypm/api/userstory/12 
    <userStory>
      <name>As an editor I want to be able to publish a new topic.</name>
      <description>Each topic has to have a unique title.</description>
      <!-- priority: 1-MUST_HAVE, 2-SHOULD_HAVE, 3-COULD_HAVE, 4-WONT_HAVE -->
      <priority>
        <id>1</id>
        <name>MUST_HAVE</name>
        <priority>1</priority>
      </priority>
      <estimatedEffort>3.0</estimatedEffort>
      <!-- color: WHITE, YELLOW, ORANGE, RED, GREEN, BLUE -->
      <color>BLUE</color>
      <owner>
        <id>2</id>
      </owner>
      <acceptingUser>
        <id>1</id>
      </acceptingUser>
      <!-- acceptanceStatus: PENDING, ACCEPTED, REJECTED -->
      <acceptanceStatus>ACCEPTED</acceptanceStatus>
    </userStory>
    

DELETE /userstory/{userStoryId} Deletes the user story.

  • Request
    DELETE http://localhost:8080/tinypm/api/userstory/12 

Tasks

GET /userstory/{userStoryId}/tasks Returns all tasks for a given user story.

  • Request
    GET http://localhost:8080/tinypm/api/userstory/12/tasks 
  • Response
    <tasks>
      <task>
        <id>1</id>
        <name>Write decent documentation.</name>
        <!-- status: one of provided by the project resource on taskStatuses list -->
        <status>
          <id>2</id>
          <name>IN PROGRESS</name>
        </status>
      </task>
      <task>
        <id>2</id>
        <name>Write sample client code.</name>
        <!-- status: one of provided by the project resource on taskStatuses list -->
        <status>
          <id>3</id>
          <name>COMPLETED</name>
        </status>
      </task>
    </tasks>
    

POST /userstory/{userStoryId}/tasks Creates a new task in a given user story.

  • Request
    POST http://localhost:8080/tinypm/api/userstory/12/tasks 
    <task>
      <name>Write decent documentation</name>
      <description>Request-response samples.</description>
      <!-- status: one of provided by the project resource on taskStatuses list -->
      <status>
        <id>3</id>
        <name>COMPLETED</name>
      </status>
      <!-- long date format: yyyy-MM-dd' 'HH:mm:ss.SSS -->
      <startedAt>2009-07-31 12:49:39.833</startedAt>
      <completedAt>2009-07-31 12:49:39.833</completedAt>
      <assignedUsers>
        <user>
          <id>1</id>
        </user>
        <user>
          <id>2</id>
        </user>
      </assignedUsers>
    </task>
    
  • Response
    Since v2.6 response contains also id of the created object.
    <task>
      <id>1</id>
    </task>
    

GET /task/{taskId} Returns a single task.

  • Request
    GET http://localhost:8080/tinypm/api/task/12 
  • Response
    <task>
      <id>12</id>
      <name>Write decent documentation</name>
      <description>Request-response samples.</description>
      <!-- status: one of provided by the project resource on taskStatuses list -->
      <status>
        <id>3</id>
        <name>COMPLETED</name>
      </status>
      <!-- long date format: yyyy-MM-dd' 'HH:mm:ss.SSS -->
      <startedAt>2009-07-28 20:11:08.581</startedAt>
      <completedAt>2009-07-28 20:11:08.581</completedAt>
      <assignedUsers>
        <user>
          <id>1</id>
          <name>Alice</name>
          <login>alice</login
          <email>alice@nowhere.com</email>
          <active>true</active>
        </user>
        <user>
          <id>2</id>
          <name>Bob</name>
          <login>bob</login>
          <email>bob@nowhere.com</email>
          <active>true</active>
        </user>
      </assignedUsers>
      <comments>
        <comment>
          <author>Demo User</author>
          <date>2011-08-24 13:18:15.000</date>
          <body>
            We need more details...
          </body>
        </comment>
      </comments>
    </task>
    

PUT /task/{taskId} Updates an existing task.

You have to provide a complete replacement for the resource. If you omit any xml node, the property will get null value.

  • Request
    PUT http://localhost:8080/tinypm/api/task/7 
    <task>
      <name>Write decent documentation</name>
      <description>Request-response samples.</description>
      <!-- status: one of provided by the project resource on taskStatuses list -->
      <status>
        <id>3</id>
        <name>COMPLETED</name>
      </status>
      <!-- long date format: yyyy-MM-dd' 'HH:mm:ss.SSS -->
      <startedAt>2009-07-31 12:49:39.833</startedAt>
      <completedAt>2009-07-31 12:49:39.833</completedAt>
      <assignedUsers>
        <user>
          <id>1</id>
        </user>
        <user>
          <id>2</id>
        </user>
      </assignedUsers>
    </task>
    

DELETE /task/{taskId} Deletes the task.

  • Request
    DELETE http://localhost:8080/tinypm/api/task/7 

Comments

GET /userstory/{userStoryId}/comments Returns all comments for a given user story.

  • Request
    GET http://localhost:8080/tinypm/api/userstory/12/comments 
  • Response
    <comments>
      <comment>
        <author>Alice</author>
        <date>2011-08-24 13:17:23.000</date>
        <body>
          This story should probably include all kinds of users?
        </body>
      </comment>
      <comment>
        <author>Jack</author>
        <date>2011-08-24 13:25:44.000</date>
        <body>
          You're right Alice.
        </body>
      </comment>
    </comments>
    

POST /userstory/{userStoryId}/comments Adds a new comment to a given user story. All comments added this way have author called "API"

  • Request
    POST http://localhost:8080/tinypm/api/userstory/12/comments 
    <comment>
      <body>
        Alice pushed new changes. Message: fixed displaying posts under IE7  
      </body>
    </comment>
    

GET /task/{taskId}/comments Returns all comments for a given task.

  • Request
    GET http://localhost:8080/tinypm/api/task/12/comments 
  • Response
    <comments>
      <comment>
        <author>Alice</author>
        <date>2011-08-24 13:17:23.000</date>
        <body>
          We need more details...
        </body>
      </comment>
      <comment>
        <author>Jack</author>
        <date>2011-08-24 13:25:44.000</date>
        <body>
          Will add them ASAP.
        </body>
      </comment>
    </comments>
    

POST /task/{taskId}/comments Adds a new comment to a given task. All comments added this way have author called "API"

  • Request
    POST http://localhost:8080/tinypm/api/task/12/comments 
    <comment>
      <body>
        Alice pushed new changes. Message: fixed displaying posts under IE7  
      </body>
    </comment>
    

Timesheet

GET /iteration/{iterationId}/timesheet Returns all time spent entries provided in timesheet for tasks in given iteration.

  • Request
    GET http://localhost:8080/tinypm/api/iteration/3/timesheet
  • Response
    <timesheet>
      <activity>
        <date>2011-06-17</date>
        <task>
          <id>4</id>
          <name>Some task</name>
          <!-- status: one of provided by the project resource on taskStatuses list -->
          <status>
            <id>3</id>
            <name>COMPLETED</name>
          </status>
        </task>
        <timeSpent>8.0</timeSpent>
        <user>
          <active>true</active>
          <id>3</id>
          <name>Alice</name>
        </user>
        <userStory>
          <id>1</id>
          <iterationId>1</iterationId>
          <name>Creating users</name>
          <position>0</position>
        </userStory>
      </activity>
      <activity>
        <date>2011-06-18</date>
        <task>
          <id>4</id>
          <name>Some task</name>
          <!-- status: one of provided by the project resource on taskStatuses list -->
          <status>
            <id>3</id>
            <name>COMPLETED</name>
          </status>
        </task>
        <timeSpent>6.0</timeSpent>
        <user>
          <active>true</active>
          <id>3</id>
          <name>Alice</name>
        </user>
        <userStory>
          <id>1</id>
          <iterationId>1</iterationId>
          <name>Creating users</name>
          <position>0</position>
        </userStory>
      </activity>
    </timesheet>
    

GET /task/{taskId}/timesheet Returns all time spent entries provided in timesheet for a given tasks.

  • Request
    GET http://localhost:8080/tinypm/api/task/12/timesheet
  • Response
    <timesheet>
      <activity>
        <date>2011-06-17</date>
        <task>
          <id>4</id>
          <name>Some task</name>
          <!-- status: one of provided by the project resource on taskStatuses list -->
          <status>
            <id>3</id>
            <name>COMPLETED</name>
          </status>
        </task>
        <timeSpent>8.0</timeSpent>
        <user>
          <active>true</active>
          <id>3</id>
          <name>Alice</name>
        </user>
        <userStory>
          <id>1</id>
          <iterationId>1</iterationId>
          <name>Creating users</name>
          <position>0</position>
        </userStory>
      </activity>
      <activity>
        <date>2011-06-18</date>
        <task>
          <id>4</id>
          <name>Some task</name>
          <!-- status: one of provided by the project resource on taskStatuses list -->
          <status>
            <id>3</id>
            <name>COMPLETED</name>
          </status>
        </task>
        <timeSpent>6.0</timeSpent>
        <user>
          <active>true</active>
          <id>3</id>
          <name>Alice</name>
        </user>
        <userStory>
          <id>1</id>
          <iterationId>1</iterationId>
          <name>Creating users</name>
          <position>0</position>
        </userStory>
      </activity>
    </timesheet>
    

POST /task/{taskId}/timesheet Creates or updates time spent on a given task at a provided date. Activity is logged for a given user. If provided time spent is equal 0.0 then the timesheet entry is removed (if exists at a given date for a given user).

  • Request
    POST http://localhost:8080/tinypm/api/task/12/timesheet
    <activity>
      <date>2011-06-18</date>
      <timeSpent>6.0</timeSpent>
      <user>
        <id>3</id>
      </user>
    </activity>
    
? If this documentation doesn't solve your problem or has left you with any questions, please don't hesitate to contact us at support@tinypm.com
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.