Github Champion avatar
Github Champion

Pricing

Pay per usage

Go to Store
Github Champion

Github Champion

Developed by

Mihails Murasovs

Maintained by Community

Find your organization's top contributors. In every time period, performance is measured by the number of assigned issues closed, number of PR reviews, and number of PRs opened.

0.0 (0)

Pricing

Pay per usage

2

Monthly users

2

Last modified

3 years ago

Metrics aren't fun. What if they could be?

Celebrate your organization's unsung heroes, identify the quiet contributors who make a difference, and see who will dethrone the reigning champion.

Find the top 3 contributors from your organization and each of your repositories for your chosen time period. The winners are decided by number of assigned issues closed, number of PR reviews, and number of PRs opened. In addition, the actor also gathers metrics like additions, deletions, and commits for everyone who contributed to the repo, if you're into more details.

You can integrate this actor with your curent sprints. Use Apify schedules to synchronize these reports with your company's sprints. Combine it with webhooks and have the results sent to you right after they are gathered.

Who is your organization's GitHub Champion?

How to use

To use this actor with private repositories, you will need a GitHub API token with the repo permission granted - create it at https://github.com/settings/tokens/new and paste it into the githubApiToken input.

If you keep getting a Not Found error, it's probably to do with your authentication token. Make sure the entire repo permission is selected.

API token settings

By default, releases are not counted.

You will also need to make sure issues are assigned correctly (it's good practice anyway :)). One of the main metrics for the actor is the number of issues closed by each contributor.

How it works

The actor makes a few requests to GitHub's API to get your repositories' stats. It then crunches the data for each repo and each contributor, discards the empty entries, and returns the goods.

Closed issues count for 1 point, pull request reviews count for 0.75 pints, while created pull requests count for half a point. The score is added, and the person with the highest score wins!

What it doesn't do

This actor doesn't include the number of additions, deletions, and commits in its calculation. Some of us commit everything, others like to bundle it all into one. Some of us do package updates, which amount to thousands of added and deleted lines.

Output

The top 3 contributors from each repository are added to the top-contributors.json file in the top-threes key-value store.

Sample top 3 array:

1[
2  {
3    "Organization All-stars": [
4      {
5        "name": "gandalf",
6        "total": 29.5,
7        "pullReviews": 25,
8        "issuesClosed": 3,
9        "pullsCreated": 3
10      },
11      {
12        "name": "samwise",
13        "total": 24.5,
14        "pullReviews": 16,
15        "issuesClosed": 5,
16        "pullsCreated": 7
17      },
18      {
19        "name": "frodo",
20        "total": 20,
21        "pullReviews": 16,
22        "issuesClosed": 1,
23        "pullsCreated": 6
24      }
25    ]
26  },
27  {
28    "apify-web": [
29      {
30        "name": "gandalf",
31        "total": 27,
32        "pullReviews": 11,
33        "issuesClosed": 12,
34        "pullsCreated": 8
35      },
36      {
37        "name": "frodo",
38        "total": 18.5,
39        "pullReviews": 12,
40        "issuesClosed": 6,
41        "pullsCreated": 1
42      },
43      {
44        "name": "former-champ",
45        "total": 10,
46        "pullReviews": 10,
47        "issuesClosed": 0,
48        "pullsCreated": 0
49      }
50    ]
51  },
52  {
53    "apify-core": [
54      {
55        "name": "winner",
56        "total": 14.5,
57        "pullReviews": 10,
58        "issuesClosed": 0,
59        "pullsCreated": 9
60      },
61      {
62        "name": "hello-user",
63        "total": 13,
64        "pullReviews": 4,
65        "issuesClosed": 7,
66        "pullsCreated": 4
67      },
68      {
69        "name": "future-champ",
70        "total": 6.5,
71        "pullReviews": 6,
72        "issuesClosed": 0,
73        "pullsCreated": 1
74      }
75    ]
76  }
77]

More detailed breakdowns of each repository are available in the detailed-repo-metrics key-value-store.

Sample detailed breakdown:

1[
2  {
3    "id": "former-champ",
4    "additions": 0,
5    "deletions": 0,
6    "commits": 0,
7    "pullsCreated": 0,
8    "pullReviews": 10,
9    "issuesClosed": 0
10  },
11  {
12    "id": "team-leader",
13    "additions": 4,
14    "deletions": 2,
15    "commits": 1,
16    "pullsCreated": 1,
17    "pullReviews": 1,
18    "issuesClosed": 0
19  },
20  {
21    "id": "cto",
22    "additions": 0,
23    "deletions": 0,
24    "commits": 0,
25    "pullsCreated": 0,
26    "pullReviews": 6,
27    "issuesClosed": 0
28  },
29  {
30    "id": "frodo",
31    "additions": 123,
32    "deletions": 54,
33    "commits": 2,
34    "pullsCreated": 1,
35    "pullReviews": 12,
36    "issuesClosed": 6
37  },
38  {
39    "id": "casual-contributor",
40    "additions": 0,
41    "deletions": 0,
42    "commits": 0,
43    "pullsCreated": 0,
44    "pullReviews": 5,
45    "issuesClosed": 1
46  },
47  {
48    "id": "gandalf",
49    "additions": 15652,
50    "deletions": 16589,
51    "commits": 13,
52    "pullsCreated": 8,
53    "pullReviews": 11,
54    "issuesClosed": 12
55  },
56  {
57    "id": "samwise",
58    "additions": 17,
59    "deletions": 4,
60    "commits": 1,
61    "pullsCreated": 1,
62    "pullReviews": 0,
63    "issuesClosed": 0
64  }
65]

Pricing

Pricing model

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage.