{"id":27729895,"url":"https://github.com/saroj-shr/decap-cms-oauth","last_synced_at":"2025-04-28T05:01:53.138Z","repository":{"id":261963589,"uuid":"885845058","full_name":"saroj-shr/decap-cms-oauth","owner":"saroj-shr","description":"A simple Node.js OAuth provider that enables GitHub authentication for Decap CMS (formerly Netlify CMS). This service acts as a secure bridge between your static site's content management system and GitHub's authentication services.","archived":false,"fork":false,"pushed_at":"2024-11-09T15:32:31.000Z","size":0,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-11-09T15:35:16.560Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/saroj-shr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2024-11-09T14:48:21.000Z","updated_at":"2024-11-09T15:32:34.000Z","dependencies_parsed_at":"2024-11-09T15:38:07.172Z","dependency_job_id":"2c9cc42c-fd24-4473-933c-8b2c44ed4f39","html_url":"https://github.com/saroj-shr/decap-cms-oauth","commit_stats":null,"previous_names":["saroj-shr/decap-cms-oauth"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saroj-shr%2Fdecap-cms-oauth","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saroj-shr%2Fdecap-cms-oauth/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saroj-shr%2Fdecap-cms-oauth/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saroj-shr%2Fdecap-cms-oauth/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/saroj-shr","download_url":"https://codeload.github.com/saroj-shr/decap-cms-oauth/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251254260,"owners_count":21559791,"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":[],"created_at":"2025-04-28T05:01:27.470Z","updated_at":"2025-04-28T05:01:53.036Z","avatar_url":"https://github.com/saroj-shr.png","language":"JavaScript","funding_links":[],"categories":["OAuth Client"],"sub_categories":[],"readme":"# Decap CMS OAuth Provider\n\nA Cloudflare Workers-based OAuth provider that enables GitHub authentication for Decap CMS (formerly Netlify CMS). This service acts as a secure bridge between your static site's content management system and GitHub's authentication services.\n\n## Overview\n\nWhen using Decap CMS with GitHub, you need an OAuth authentication service to handle the login process securely. This provider:\n\n1. Facilitates the OAuth handshake between Decap CMS and GitHub\n2. Manages authentication tokens securely\n3. Enables content editors to log in to your CMS using their GitHub accounts\n4. Runs on Cloudflare's edge network for optimal performance\n\nThis solution is particularly useful for static sites using Decap CMS where you want to:\n- Enable multiple content editors to collaborate\n- Maintain secure authentication workflows\n- Deploy a serverless authentication service with minimal maintenance\n- Take advantage of Cloudflare's global edge network\n\n## Prerequisites\n\n- Cloudflare account\n- GitHub account\n- A registered GitHub OAuth application\n- Wrangler CLI installed (`npm install -g wrangler`)\n\n## Setup\n\n### 1. GitHub Configuration\n\n1. Go to GitHub Developer Settings \u003e OAuth Apps \u003e New OAuth App\n2. Fill in the application details:\n   - Application name: `Your Site CMS`\n   - Homepage URL: `https://your-site.com`\n   - Authorization callback URL: `https://your-worker.workers.dev/callback`\n3. Note down the Client ID and generate a Client Secret\n\n### 2. Cloudflare Configuration\n\n1. Clone this repository\n2. Install dependencies:\n   ```bash\n   npm install\n   ```\n3. Configure your environment variables in a `.dev.vars` file:\n   ```\n   GITHUB_CLIENT_ID=your_client_id\n   GITHUB_CLIENT_SECRET=your_client_secret\n   ```\n4. Deploy to Cloudflare Workers:\n   ```bash\n   wrangler deploy\n   ```\n\n### 3. Decap CMS Configuration\n\nUpdate your Decap CMS config (usually in `admin/config.yml`):\n\n```yaml\nbackend:\n  name: github\n  repo: username/repo\n  base_url: https://your-worker.workers.dev\n```\n\n## Development\n\nTo run locally:\n\n```bash\nwrangler dev\n```\n\n## Architecture\n\nThis service uses Cloudflare Workers to:\n- Handle OAuth authentication flow\n- Securely manage tokens\n- Provide fast, globally distributed authentication\n- Minimize cold starts and latency\n\n## License\n\nMIT\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaroj-shr%2Fdecap-cms-oauth","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaroj-shr%2Fdecap-cms-oauth","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaroj-shr%2Fdecap-cms-oauth/lists"}