Interview Prep/Git & GitHub/Branch protection, rulesets, CODEOWNERS and review at scale

What is the difference between a GitHub App, an OAuth app and a PAT for automation?

IntermediateProductionBranch protection, rulesets, CODEOWNERS and review at scale
Answer

A GitHub App has fine-grained permissions, acts as its own identity, installs per repo and produces short-lived tokens (1 hour) and higher rate limits. OAuth apps act as the user with broad scopes. PATs are tied to a person and are the riskiest to leave in CI. We choose Apps for bots, GITHUB_TOKEN for workflows, and fine-grained PATs only when nothing else fits.

All Git & GitHub questions Roadmap: Git & GitHub

More on Branch protection, rulesets, CODEOWNERS and review at scale