-
Notifications
You must be signed in to change notification settings - Fork 752
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into crowd-linux
- Loading branch information
Showing
50 changed files
with
2,118 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
backend/src/api/integration/helpers/groupsioConnectOrUpdate.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import Permissions from '../../../security/permissions' | ||
import IntegrationService from '../../../services/integrationService' | ||
import PermissionChecker from '../../../services/user/permissionChecker' | ||
|
||
export default async (req, res) => { | ||
new PermissionChecker(req).validateHas(Permissions.values.tenantEdit) | ||
const payload = await new IntegrationService(req).groupsioConnectOrUpdate(req.body) | ||
await req.responseHandler.success(req, res, payload) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import Permissions from '../../../security/permissions' | ||
import IntegrationService from '../../../services/integrationService' | ||
import PermissionChecker from '../../../services/user/permissionChecker' | ||
|
||
export default async (req, res) => { | ||
new PermissionChecker(req).validateHas(Permissions.values.tenantEdit) | ||
const payload = await new IntegrationService(req).groupsioGetToken(req.body) | ||
await req.responseHandler.success(req, res, payload) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import Permissions from '../../../security/permissions' | ||
import IntegrationService from '../../../services/integrationService' | ||
import PermissionChecker from '../../../services/user/permissionChecker' | ||
|
||
export default async (req, res) => { | ||
new PermissionChecker(req).validateHas(Permissions.values.tenantEdit) | ||
const payload = await new IntegrationService(req).groupsioVerifyGroup(req.body) | ||
await req.responseHandler.success(req, res, payload) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
backend/src/serverless/integrations/usecases/groupsio/types.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
export interface GroupsioIntegrationData { | ||
email: string | ||
token: string | ||
groupNames: GroupName[] | ||
} | ||
|
||
export interface GroupsioGetToken { | ||
email: string | ||
password: string | ||
twoFactorCode?: string | ||
} | ||
|
||
export interface GroupsioVerifyGroup { | ||
groupName: GroupName | ||
cookie: string | ||
} | ||
|
||
export type GroupName = string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.