{"id":18555982,"url":"https://github.com/josedefreitas/codewars-activity-chart","last_synced_at":"2025-11-01T10:30:30.024Z","repository":{"id":178877671,"uuid":"616668924","full_name":"JoseDeFreitas/codewars-activity-chart","owner":"JoseDeFreitas","description":"Simple API to get a chart (in the form of a calendar) with the count of the katas completed in Codewars by a user in a specified year.","archived":false,"fork":false,"pushed_at":"2025-01-26T18:19:29.000Z","size":38,"stargazers_count":11,"open_issues_count":0,"forks_count":0,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-01-26T19:27:39.718Z","etag":null,"topics":["codewars","contributions-chart","glitch-com"],"latest_commit_sha":null,"homepage":"https://glitch.com/edit/#!/codewars-activity-chart","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"cc0-1.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/JoseDeFreitas.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"josedefreitas","ko_fi":"josedefreitas"}},"created_at":"2023-03-20T20:58:46.000Z","updated_at":"2025-01-26T18:19:33.000Z","dependencies_parsed_at":null,"dependency_job_id":"95579ba7-9e09-4fbb-bee3-6fd42fb108b4","html_url":"https://github.com/JoseDeFreitas/codewars-activity-chart","commit_stats":null,"previous_names":["josedefreitas/codewars-activity-chart"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JoseDeFreitas%2Fcodewars-activity-chart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JoseDeFreitas%2Fcodewars-activity-chart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JoseDeFreitas%2Fcodewars-activity-chart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JoseDeFreitas%2Fcodewars-activity-chart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JoseDeFreitas","download_url":"https://codeload.github.com/JoseDeFreitas/codewars-activity-chart/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239280711,"owners_count":19612724,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["codewars","contributions-chart","glitch-com"],"created_at":"2024-11-06T21:28:37.920Z","updated_at":"2025-11-01T10:30:29.966Z","avatar_url":"https://github.com/JoseDeFreitas.png","language":"Python","funding_links":["https://github.com/sponsors/josedefreitas","https://ko-fi.com/josedefreitas"],"categories":[],"sub_categories":[],"readme":"# Codewars Activity Chart\n\n\u003e Also check [CodewarsLogger](https://github.com/JoseDeFreitas/CodewarsLogger)!\n\n\u003e (Adapted from [JoseDeFreitas/wikipedia-edits-chart](https://github.com/JoseDeFreitas/wikipedia-edits-chart)).\n\nThis is a little program that prints a chart, in the form of a calendar (based\non the year you choose),[^1] that shows the days a specified user completed katas\nin Codewars and the quantity of the katas they completed in that day. The API also\ncounts the total amount of katas completed in the year and the streak of completion.[^2]\nHead to the [Example](#example) section to see how it looks. **The contribution\nchart from GitHub was my inspiration.**\n\nCharts like this exist in some websites. Although they look cool, I don't think\nthey provide anything useful, and, in some cases, I believe they're noxious as\nforce you to keep them ordered (even if you don't want to) or preserve a streak\nthat is, pretty much, useless. This may not seem like an issue, but I do believe\nit's wrong to submit solutions to code challenges just to keep the chart \"pretty\".\n\nThis program serves only as a cool statistical graph. I recommend you practise your\ncoding skills when you want and as you want, not to keep the chart full.\n\n## Example\n\n\u003ca href=\"https://codewars-activity-chart.glitch.me/jhoffner?year=2013\"\u003e\u003cimg alt=\"Codewars Activity Chart example\" src=\"https://user-images.githubusercontent.com/37962411/226577099-7de8863c-9044-4b4b-941f-b2e175d09435.png\" height=\"404\"/\u003e\u003c/a\u003e\n\n## Usage\n\nTo get the chart, simply go to **https://codewars-activity-chart.glitch.me** and\nadd the required parameters. Below you can find the list of the available path\nand query parameters, as well as some examples. If the user couldn't be found or\nthere is no katas completed for the choosen year, the API will let you know with\na red message.\n\nTo see the amount of katas completed in a day, you must hover over that day.\n\n### Parameters\n\n| Parameter          | Required | Default value    | Example                                                               |\n| ------------------ | -------- | ---------------- | --------------------------------------------------------------------- |\n| username           | yes      |                  | https://codewars-activity-chart.glitch.me/jhoffner                    |\n| year               | no       | Current year     | https://codewars-activity-chart.glitch.me/jhoffner?year=2016          |\n\n### Embedding\n\nYou can embed the chart in your website (or any website that allows for embedding\nother websites) using the [`\u003ciframe\u003e`](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe)\ntag from HTML:\n\n```html\n\u003ciframe src=\"CHART_URL\" width=\"625\" height=\"421\"\u003e\u003c/iframe\u003e\n```\n\n625 of width and 421 of height looks good enough to show only the chart, but you\ncan tweak these values as you want.\n\n## Remarks\n\n- The JSON data that you get from the [Codewars API](https://dev.codewars.com/)\ncontains a maximum of 200 katas completed per page. It needs to make new calls\nto retrieve all of the katas that a user completed, and that's what the program\ndoes. If you have completed a massive amount of katas, it may take some time, but\nI believe it's not of a big deal. **Please, don't overwhelm the API**.\n- When no one has made a request to the website in 5 minutes, Glitch (the host\nI'm using) turns off the website. In this case, you'll need to wait some seconds for\nthe chart to appear. There is also a [limited amount of hours per month](https://help.glitch.com/kb/article/17-technical-restrictions/)\nfor the free plan (which is the one I'm using).\n- The timezone used by the program is **UTC**. This is because it's faster this way\nfor the user to get the chart (as he would need to also type in the timezone they\nwant). However, I may introduce the feature to select a specific timezone in the\nfuture.\n- You **have to** embed it in another page for it to show. I tried generating the\nimage directly in PNG or SVG (without the use of any third-party library), but it was\ntoo messy.\n\n[^1]: The shape of the months are different from one another because, instead of\nprinting the days as GitHub does, it prints them like a normal calendar. You can\nsee the day of the week by counting the row the day is in. It starts at Monday and\nfinishes at Sunday.\n[^2]: If you choose the current year, it will print the current streak. If you\nchoose any other year that has already passed, it will print the longest streak\nmade.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjosedefreitas%2Fcodewars-activity-chart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjosedefreitas%2Fcodewars-activity-chart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjosedefreitas%2Fcodewars-activity-chart/lists"}