feat(infisical-pg): completed audit log moved ee routes to normal routing pattern

This commit is contained in:
Akhil Mohan
2024-01-27 12:38:23 +05:30
parent 6e6a1c87f2
commit 16f0ac6d43
78 changed files with 3178 additions and 445 deletions
@@ -14,7 +14,7 @@ export const useCreateSecretRotation = () => {
return useMutation<{}, {}, TCreateSecretRotationDTO>({
mutationFn: async (dto) => {
const { data } = await apiRequest.post("/api/ee/v1/secret-rotations", dto);
const { data } = await apiRequest.post("/api/v1/secret-rotations", dto);
return data;
},
onSuccess: (_, { workspaceId }) => {
@@ -28,7 +28,7 @@ export const useDeleteSecretRotation = () => {
return useMutation<{}, {}, TDeleteSecretRotationDTO>({
mutationFn: async (dto) => {
const { data } = await apiRequest.delete(`/api/ee/v1/secret-rotations/${dto.id}`);
const { data } = await apiRequest.delete(`/api/v1/secret-rotations/${dto.id}`);
return data;
},
onSuccess: (_, { workspaceId }) => {
@@ -42,7 +42,7 @@ export const useRestartSecretRotation = () => {
return useMutation<{}, {}, TRestartSecretRotationDTO>({
mutationFn: async (dto) => {
const { data } = await apiRequest.post("/api/ee/v1/secret-rotations/restart", { id: dto.id });
const { data } = await apiRequest.post("/api/v1/secret-rotations/restart", { id: dto.id });
return data;
},
onSuccess: (_, { workspaceId }) => {
@@ -25,7 +25,7 @@ export const secretRotationKeys = {
const fetchSecretRotationProviders = async ({ workspaceId }: TGetSecretRotationProviders) => {
const { data } = await apiRequest.get<TSecretRotationProviderList>(
`/api/ee/v1/secret-rotation-providers/${workspaceId}`
`/api/v1/secret-rotation-providers/${workspaceId}`
);
return data;
};
@@ -55,7 +55,7 @@ const fetchSecretRotations = async ({
workspaceId
}: Omit<TGetSecretRotationList, "decryptFileKey">) => {
const { data } = await apiRequest.get<{ secretRotations: TSecretRotation[] }>(
"/api/ee/v1/secret-rotations",
"/api/v1/secret-rotations",
{ params: { workspaceId } }
);
return data.secretRotations;