{"id":19581087,"url":"https://github.com/tsamaya/aws-lambda-node-authorizer-auth0","last_synced_at":"2026-05-01T23:34:19.060Z","repository":{"id":49953204,"uuid":"362754217","full_name":"tsamaya/aws-lambda-node-authorizer-auth0","owner":"tsamaya","description":"AWS λ Authorizer Example with Auth0","archived":false,"fork":false,"pushed_at":"2023-04-10T22:32:12.000Z","size":2287,"stargazers_count":0,"open_issues_count":6,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-01-09T05:22:35.464Z","etag":null,"topics":["auth0","authorizer","aws","aws-lambda"],"latest_commit_sha":null,"homepage":"https://roasted-thread.surge.sh/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tsamaya.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"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}},"created_at":"2021-04-29T09:00:53.000Z","updated_at":"2022-07-29T07:47:35.000Z","dependencies_parsed_at":"2024-11-11T07:33:10.528Z","dependency_job_id":"c1b112b5-8928-4655-aa25-20922488a072","html_url":"https://github.com/tsamaya/aws-lambda-node-authorizer-auth0","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tsamaya%2Faws-lambda-node-authorizer-auth0","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tsamaya%2Faws-lambda-node-authorizer-auth0/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tsamaya%2Faws-lambda-node-authorizer-auth0/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tsamaya%2Faws-lambda-node-authorizer-auth0/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tsamaya","download_url":"https://codeload.github.com/tsamaya/aws-lambda-node-authorizer-auth0/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240849012,"owners_count":19867617,"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":["auth0","authorizer","aws","aws-lambda"],"created_at":"2024-11-11T07:32:36.427Z","updated_at":"2026-05-01T23:34:19.025Z","avatar_url":"https://github.com/tsamaya.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# aws-lambda-node-authorizer-auth0\n\n[AWS API Gateway](https://aws.amazon.com/api-gateway/) Custom authorizer function with [Auth0](https://auth0.com/) example in [NodeJS](https://nodejs.org/en/)\n\n### 🌍 Live demo\n\nHere is the live demo: [roasted-thread.surge.sh](https://roasted-thread.surge.sh/)\n\n### 🔨Build and Deploy\n\n- Setup an [auth0 application](https://auth0.com/docs/applications).\n\n```bash\ncd /path/to/repo/\n```\n\n#### 💻 Backend\n\n```bash\ncd backend\n\nexport AWS_ACCESS_KEY_ID=\u003cYOUR-AWS-ACCESS-KEY-ID\u003e\nexport AWS_SECRET_ACCESS_KEY=\u003cYOUR-AWS-SECRET-ACCESS-KEY\u003e\n\nnpm install\n```\n\n- Get your `Domain` (under `applications-\u003e${YOUR_APP_NAME}-\u003esettings`) and plugin your `AUTH0_DOMAIN` in a new file called `secrets.json` (based on `secrets.example.json`).\n\n- Get your `Certificate` (under `applications-\u003e${YOUR_APP_NAME}-\u003esettings-\u003eShow Advanced Settings-\u003eCertificates-\u003eDOWNLOAD CERTIFICATE`). Download it as `PEM` format and save it as a new file called `key.pem`\n\n- Deploy the service with `npx serverless deploy` and grab the public and private endpoints.\n\n#### 🖥 Frontend\n\n```bash\ncd frontend\n\nnpm install\n```\n\n- Get your `Client ID` (under `applications-\u003e${YOUR_APP_NAME}-\u003esettings`)\n\n- Create files `.env.production` and `.env.development` with values fron auth0 and the deployed API endpoint\n\n```\nREACT_APP_API_BASE_URL=https://\u003capiendpoint\u003e.execute-api.\u003cregion\u003e.amazonaws.com/dev\nREACT_APP_AUTH0_DOMAIN=\u003cYOUR-AUTH0-DOMAIN\u003e\nREACT_APP_AUTH0_CLIENT_ID=\u003cYOUR-APPLICATION-CLIENT-ID\u003e\n```\n\n- Build and deploy Frontend to host of your choosing and make sure to configure the `Allowed Callback URL`, `Allowed Logout URLs` and `Allowed Web Origins` in your auth0 application in the [auth0 dashboard](https://manage.auth0.com). I used `https://roasted-thread.surge.sh/` for the demo.\n\n```bash\nnpm run build\n\nserve build\n```\n\n### 🗂 Resources\n\nThis example is based on [serverless examples](https://github.com/serverless/examples/tree/master/aws-node-auth0-cognito-custom-authorizers-api)\n\n### 🥂 Contributing\n\nAnyone and everyone is welcome to contribute.\n\n### 🐞 Issues\n\nFind a bug or want to request a new feature? Please let me know by submitting an issue.\n\n### 🗝 Licensing\n\nLicensed under the MIT License\n\nA copy of the license is available in the repository's [LICENSE](LICENSE) file.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftsamaya%2Faws-lambda-node-authorizer-auth0","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftsamaya%2Faws-lambda-node-authorizer-auth0","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftsamaya%2Faws-lambda-node-authorizer-auth0/lists"}