Back to APIs list

Github API examples & templates

Use these vals as a playground to view and fork Github API examples and templates on Val Town. Run any example below or find templates that can be used as a pre-built solution.
githubNotification
stevekrouse
githubNotification
An interactive, runnable TypeScript val by stevekrouse
Cron
githubactivitysummarizer
michaelwschultz
githubactivitysummarizer
Remix of: ejfox/githubactivitysummarizer
HTTP
githubContributionTracker
storm_trupa
githubContributionTracker
@jsxImportSource https://esm.sh/react@18.2.0
Cron
Github_SearchTopRepos
rlesser
Github_SearchTopRepos
* Returns top repos in the past X days * @param {string | Date} start - start date * @param {number} days - number of days to search * @returns {Promise<import("@octokit/rest").Octokit.SearchReposResponse>} top repos in span
Script
posthogGitHubStarCapture
mmaksimovic
posthogGitHubStarCapture
Remix of: ianvph/posthogGitHubStarCapture
HTTP
countGithubLOCUI
g
countGithubLOCUI
GitHub Line Counter πŸš€ GitHub Line Counter , live on val.town ; Ever wondered how many lines of code are in a GitHub repo without the hassle of cloning it? Say hello to GitHub Line Counter β€” your friendly, web-based LOC inspector! 🌟 What It Does This simple tool fetches the GitHub repository as a ZIP file, decompresses it on the fly (thanks to fflate πŸ’¨), and counts the lines of code β€” on val.town with an incredible bandwith and speed. Built with Vanilla JS on the frontend and powered by val.town on the backend, it’s lightweight, fast, and ready to use! How to Use Just paste the repo URL, hit "Count Lines," and watch the magic happen! ✨
HTTP
githubGists
benigeri
githubGists
An interactive, runnable TypeScript val by benigeri
Script
serveGithubRepo
pomdtr
serveGithubRepo
Serve Github Repo Example Click here to preview a commit from 8 years ago. import { serveGithubRepo } from "https://esm.town/v/pomdtr/serveGithubRepo"; export default serveGithubRepo({ owner: "mkdocs", repo: "mkdocs", ref: "51ec734" }); Fork this val to get your own copy, and customize the params. The first load can be a bit slow, but subsequents requests will be cached (both in your browser and on val.town) Use it from the cli deno run --allow-net https://esm.town/v/pomdtr/serveGithubRepoCli mkdocs/mkdocs --ref 51ec734
Script
GitHubAPI
iamseeley
GitHubAPI
An interactive, runnable TypeScript val by iamseeley
Script
domainFork
curtcox
domainFork
A one stop shop for several (all?) of the domains that use the GitHub user/repo URL format.
HTTP
githubStars
sourishkrout
githubStars
An interactive, runnable TypeScript val by sourishkrout
Script
githubFollowing
stevekrouse
githubFollowing
An interactive, runnable TypeScript val by stevekrouse
Script
gitReleaseNotes
stevekrouse
gitReleaseNotes
Remix of: kylem/gitReleaseNotes
HTTP
fetchNewPublicGitHubRepos
stevekrouse
fetchNewPublicGitHubRepos
An interactive, runnable TypeScript val by stevekrouse
Script
git_jiggy
stevekrouse
git_jiggy
Needs GITHUB_CONTRIBUTIONS key set in your Val Town Environment Variables . Get this token here: https://github.com/settings/personal-access-tokens/new Give it basically the minimum permissions. It should only pull public data anyways.
HTTP
pjsSearchUI
g
pjsSearchUI
Remix of: g/searchUI
HTTP