[PR #3204] [MERGED] feat: dynamically select which auth providers for your instance of Hoppscotch (BE implementation) #4283

Closed
opened 2026-03-17 01:50:01 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hoppscotch/hoppscotch/pull/3204
Author: @balub
Created: 7/21/2023
Status: Merged
Merged: 8/3/2023
Merged by: @balub

Base: release/2023.8.0Head: feat/conditional-auth-select


📝 Commits (10+)

  • 6928eb7 feat(lang): update tw translation (#3170)
  • 25177bd fix: update vite-plugin-dts version which fixes build issue on docker/alpine (#3179)
  • 82b6e08 fix: fixed issue in team-environment test cases (#3189)
  • 9402bb9 fix: add healthcheck for db and remove unwanted volumes (#3150)
  • 51efb35 fix: keybinding modifier issue (#3163)
  • 3984255 fix: reduce the memory consumption during build to prevent OOM (#3148)
  • 6496bea chore: bump version to 2023.4.8
  • e869d49 chore: run tests on and against release branches
  • 29171d1 fix: generate-ui failing to build
  • 48356cb feat: social auth providers can now be conditionally provisioned

📊 Changes

28 files changed (+413 additions, -228 deletions)

View changed files

.dockerignore (+1 -0)
📝 .env.example (+1 -0)
📝 .github/workflows/tests.yml (+2 -2)
📝 docker-compose.yml (+13 -3)
📝 packages/hoppscotch-backend/package.json (+1 -1)
📝 packages/hoppscotch-backend/src/auth/auth.controller.ts (+11 -2)
📝 packages/hoppscotch-backend/src/auth/auth.module.ts (+4 -3)
📝 packages/hoppscotch-backend/src/auth/guards/github-sso.guard.ts (+14 -2)
📝 packages/hoppscotch-backend/src/auth/guards/google-sso.guard.ts (+14 -2)
📝 packages/hoppscotch-backend/src/auth/guards/microsoft-sso-.guard.ts (+20 -2)
📝 packages/hoppscotch-backend/src/auth/helper.ts (+32 -2)
📝 packages/hoppscotch-backend/src/errors.ts (+24 -0)
📝 packages/hoppscotch-backend/src/main.ts (+3 -0)
📝 packages/hoppscotch-backend/src/team-environments/team-environments.service.spec.ts (+2 -2)
📝 packages/hoppscotch-backend/src/utils.ts (+30 -1)
📝 packages/hoppscotch-common/locales/tw.json (+58 -58)
📝 packages/hoppscotch-common/package.json (+1 -1)
packages/hoppscotch-common/public/badge.svg (+1 -0)
📝 packages/hoppscotch-common/src/components.d.ts (+0 -21)
📝 packages/hoppscotch-common/src/helpers/keybindings.ts (+18 -11)

...and 8 more files

📄 Description

Closes HP-70 & HBE-224

Closes #3088 and #3211.

Description

In this PR, we allow users to select now the auth providers they would like to use in their instance of Hoppscotch. Previously the user had no option but to configure all the providers however from now we have the following changes:

  • A new environment variable ALLOWED_AUTH_PROVIDERS, this env variable contains a comma-separated list of all the providers the user would like to use in the format specified below.

ALLOWED_AUTH_PROVIDERS = GOOGLE,GITHUB,MICROSOFT,EMAIL

  • A user can enable/disable providers by adding/removing them from the ALLOWED_AUTH_PROVIDERS env variable.

Checks

  • My pull request adheres to the code style of this project
  • My code requires changes to the documentation
  • I have updated the documentation as required
  • All the tests have passed

Additional Information

EMAIL refers to the magic link.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/hoppscotch/hoppscotch/pull/3204 **Author:** [@balub](https://github.com/balub) **Created:** 7/21/2023 **Status:** ✅ Merged **Merged:** 8/3/2023 **Merged by:** [@balub](https://github.com/balub) **Base:** `release/2023.8.0` ← **Head:** `feat/conditional-auth-select` --- ### 📝 Commits (10+) - [`6928eb7`](https://github.com/hoppscotch/hoppscotch/commit/6928eb799251469f2210cb5631a1c9f98d729be8) feat(lang): update tw translation (#3170) - [`25177bd`](https://github.com/hoppscotch/hoppscotch/commit/25177bd6357497527609099a5e425a59bdc7a3fe) fix: update vite-plugin-dts version which fixes build issue on docker/alpine (#3179) - [`82b6e08`](https://github.com/hoppscotch/hoppscotch/commit/82b6e08d6820bed28b8a5d3b65fc85bebd8743cb) fix: fixed issue in team-environment test cases (#3189) - [`9402bb9`](https://github.com/hoppscotch/hoppscotch/commit/9402bb9285cfbbb1d8887f3f2c9765ebddc7d154) fix: add healthcheck for db and remove unwanted volumes (#3150) - [`51efb35`](https://github.com/hoppscotch/hoppscotch/commit/51efb35aa6eef01ad20a973a55333c92ceb795fb) fix: keybinding modifier issue (#3163) - [`3984255`](https://github.com/hoppscotch/hoppscotch/commit/39842559b5c636aa04efe5f24a947fa68482f1a2) fix: reduce the memory consumption during build to prevent OOM (#3148) - [`6496bea`](https://github.com/hoppscotch/hoppscotch/commit/6496bea846ee80baff72d0262e46c0c2c1528b8f) chore: bump version to 2023.4.8 - [`e869d49`](https://github.com/hoppscotch/hoppscotch/commit/e869d49e16bf1df0da127c15397573dea20eeb3b) chore: run tests on and against release branches - [`29171d1`](https://github.com/hoppscotch/hoppscotch/commit/29171d1b6fbfef71ae30e268dab43670be3c8658) fix: generate-ui failing to build - [`48356cb`](https://github.com/hoppscotch/hoppscotch/commit/48356cb589f92363926e40835eb905b350a9ffbd) feat: social auth providers can now be conditionally provisioned ### 📊 Changes **28 files changed** (+413 additions, -228 deletions) <details> <summary>View changed files</summary> ➕ `.dockerignore` (+1 -0) 📝 `.env.example` (+1 -0) 📝 `.github/workflows/tests.yml` (+2 -2) 📝 `docker-compose.yml` (+13 -3) 📝 `packages/hoppscotch-backend/package.json` (+1 -1) 📝 `packages/hoppscotch-backend/src/auth/auth.controller.ts` (+11 -2) 📝 `packages/hoppscotch-backend/src/auth/auth.module.ts` (+4 -3) 📝 `packages/hoppscotch-backend/src/auth/guards/github-sso.guard.ts` (+14 -2) 📝 `packages/hoppscotch-backend/src/auth/guards/google-sso.guard.ts` (+14 -2) 📝 `packages/hoppscotch-backend/src/auth/guards/microsoft-sso-.guard.ts` (+20 -2) 📝 `packages/hoppscotch-backend/src/auth/helper.ts` (+32 -2) 📝 `packages/hoppscotch-backend/src/errors.ts` (+24 -0) 📝 `packages/hoppscotch-backend/src/main.ts` (+3 -0) 📝 `packages/hoppscotch-backend/src/team-environments/team-environments.service.spec.ts` (+2 -2) 📝 `packages/hoppscotch-backend/src/utils.ts` (+30 -1) 📝 `packages/hoppscotch-common/locales/tw.json` (+58 -58) 📝 `packages/hoppscotch-common/package.json` (+1 -1) ➕ `packages/hoppscotch-common/public/badge.svg` (+1 -0) 📝 `packages/hoppscotch-common/src/components.d.ts` (+0 -21) 📝 `packages/hoppscotch-common/src/helpers/keybindings.ts` (+18 -11) _...and 8 more files_ </details> ### 📄 Description <!-- Thanks for creating this pull request 🤗 Please make sure that the pull request is limited to one type (docs, feature, etc.) and keep it as small as possible. You can open multiple prs instead of opening a huge one. --> <!-- If this pull request closes an issue, please mention the issue number below --> Closes HP-70 & HBE-224 Closes #3088 and #3211. ### Description <!-- Add a brief description of the pull request --> In this PR, we allow users to select now the auth providers they would like to use in their instance of Hoppscotch. Previously the user had no option but to configure all the providers however from now we have the following changes: - A new environment variable `ALLOWED_AUTH_PROVIDERS`, this env variable contains a comma-separated list of all the providers the user would like to use in the format specified below. ```ALLOWED_AUTH_PROVIDERS = GOOGLE,GITHUB,MICROSOFT,EMAIL``` - A user can enable/disable providers by adding/removing them from the `ALLOWED_AUTH_PROVIDERS` env variable. <!-- You can also choose to add a list of changes and if they have been completed or not by using the markdown to-do list syntax - [ ] Not Completed - [x] Completed --> ### Checks <!-- Make sure your pull request passes the CI checks and do check the following fields as needed - --> - [x] My pull request adheres to the code style of this project - [x] My code requires changes to the documentation - [ ] I have updated the documentation as required - [x] All the tests have passed ### Additional Information <!-- Any additional information like breaking changes, dependencies added, screenshots, comparisons between new and old behaviour, etc. --> `EMAIL` refers to the magic link. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-17 01:50:01 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#4283
No description provided.