mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-16 21:37:59 +00:00
feat(native-integrations): microsoft teams
This commit is contained in:
@@ -20,7 +20,10 @@ import { TSshCertificateTemplate } from "../sshCertificateTemplates/types";
|
||||
import { TSshHost } from "../sshHost/types";
|
||||
import { userKeys } from "../users/query-keys";
|
||||
import { TWorkspaceUser } from "../users/types";
|
||||
import { ProjectSlackConfig } from "../workflowIntegrations/types";
|
||||
import {
|
||||
ProjectWorkflowIntegrationConfig,
|
||||
WorkflowIntegrationPlatform
|
||||
} from "../workflowIntegrations/types";
|
||||
import { workspaceKeys } from "./query-keys";
|
||||
import {
|
||||
CreateEnvironmentDTO,
|
||||
@@ -874,12 +877,18 @@ export const useListWorkspaceSshCertificateTemplates = (projectId: string) => {
|
||||
});
|
||||
};
|
||||
|
||||
export const useGetWorkspaceSlackConfig = ({ workspaceId }: { workspaceId: string }) => {
|
||||
export const useGetWorkspaceWorkflowIntegrationConfig = ({
|
||||
workspaceId,
|
||||
integration
|
||||
}: {
|
||||
workspaceId: string;
|
||||
integration: WorkflowIntegrationPlatform;
|
||||
}) => {
|
||||
return useQuery({
|
||||
queryKey: workspaceKeys.getWorkspaceSlackConfig(workspaceId),
|
||||
queryKey: workspaceKeys.getWorkspaceWorkflowIntegrationConfig(workspaceId, integration),
|
||||
queryFn: async () => {
|
||||
const { data } = await apiRequest.get<ProjectSlackConfig>(
|
||||
`/api/v1/workspace/${workspaceId}/slack-config`
|
||||
const { data } = await apiRequest.get<ProjectWorkflowIntegrationConfig>(
|
||||
`/api/v1/workspace/${workspaceId}/workflow-integration-config/${integration}`
|
||||
);
|
||||
|
||||
return data;
|
||||
|
||||
Reference in New Issue
Block a user