A script to aggregate 10000ft.com (10K) statistics based on time entries matching a ticket pattern
npm install --global 10kticketstat
For usage details, run
10kticketstat without arguments:
% 10kticketstat usage: 10kticketstat projectId outputPath apiKey [--api-url] [--start-iso-date] [--end-iso-date] [--ticket-pattern]
To mitigate excessive downloads,
--start-iso-date defaults to one year prior to the moment the script is run.
projectId is the id for any project or phase of a project. When you navigate to Projects > Project > Worklist > Phase in the web interface, the URL should look like this:
In this case,
1401981 is the project and
1401987 is the phase. Note that any hours logged to the phase will not be included in the results for the project as a whole. It’s up to you to aggregate that data if you need data across multiple phases.
Here’s an example with arguments:
% 10kticketstat 1401987 ~/Desktop $TENK_API_KEY Downloaded data chunk #1 from 10K. Downloaded data chunk #2 from 10K. Downloaded data chunk #3 from 10K. Downloaded data chunk #4 from 10K. Downloaded data chunk #5 from 10K. Downloaded data chunk #6 from 10K. Download complete. Done. Analysis saved to: /Users/adamshaylor/Desktop/10kticketstat.csv
I had previously stored the API key as an environment variable
$TENK_API_KEY. You can substitute the actual raw key if you prefer. The output should look something like this: