mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-07 21:27:31 +00:00
Merge pull request #4513 from Infisical/update-dyn-secret-return
feat(dynamic-secret): made POST and PATCH endpoints return inputs
This commit is contained in:
@@ -84,7 +84,9 @@ export const registerDynamicSecretRouter = async (server: FastifyZodProvider) =>
|
|||||||
}),
|
}),
|
||||||
response: {
|
response: {
|
||||||
200: z.object({
|
200: z.object({
|
||||||
dynamicSecret: SanitizedDynamicSecretSchema
|
dynamicSecret: SanitizedDynamicSecretSchema.extend({
|
||||||
|
inputs: z.unknown()
|
||||||
|
})
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -151,7 +153,9 @@ export const registerDynamicSecretRouter = async (server: FastifyZodProvider) =>
|
|||||||
}),
|
}),
|
||||||
response: {
|
response: {
|
||||||
200: z.object({
|
200: z.object({
|
||||||
dynamicSecret: SanitizedDynamicSecretSchema
|
dynamicSecret: SanitizedDynamicSecretSchema.extend({
|
||||||
|
inputs: z.unknown()
|
||||||
|
})
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -180,7 +180,7 @@ export const dynamicSecretServiceFactory = ({
|
|||||||
return cfg;
|
return cfg;
|
||||||
});
|
});
|
||||||
|
|
||||||
return dynamicSecretCfg;
|
return { ...dynamicSecretCfg, inputs };
|
||||||
};
|
};
|
||||||
|
|
||||||
const updateByName: TDynamicSecretServiceFactory["updateByName"] = async ({
|
const updateByName: TDynamicSecretServiceFactory["updateByName"] = async ({
|
||||||
@@ -337,7 +337,7 @@ export const dynamicSecretServiceFactory = ({
|
|||||||
return cfg;
|
return cfg;
|
||||||
});
|
});
|
||||||
|
|
||||||
return updatedDynamicCfg;
|
return { ...updatedDynamicCfg, inputs: updatedInput };
|
||||||
};
|
};
|
||||||
|
|
||||||
const deleteByName: TDynamicSecretServiceFactory["deleteByName"] = async ({
|
const deleteByName: TDynamicSecretServiceFactory["deleteByName"] = async ({
|
||||||
|
|||||||
Reference in New Issue
Block a user