Improve error propagation and change appId to objectId to match azure

This commit is contained in:
carlosmonastyrski
2025-04-30 20:06:13 -03:00
parent a01a9f3f77
commit d161be1170
10 changed files with 62 additions and 34 deletions
@@ -25,7 +25,7 @@ export const AzureClientSecretRotationParametersFields = () => {
return (
<Controller
name="parameters.appId"
name="parameters.objectId"
control={control}
render={({ field: { value, onChange }, fieldState: { error } }) => (
<FormControl
@@ -19,7 +19,7 @@ export const AzureClientSecretRotationReviewFields = () => {
<>
<SecretRotationReviewSection label="Parameters">
<GenericFieldLabel label="App Name">{parameters.appName}</GenericFieldLabel>
<GenericFieldLabel label="App ID">{parameters.appId}</GenericFieldLabel>
<GenericFieldLabel label="App ID">{parameters.objectId}</GenericFieldLabel>
</SecretRotationReviewSection>
<SecretRotationReviewSection label="Secrets Mapping">
<GenericFieldLabel label="Client ID">{clientId}</GenericFieldLabel>
@@ -7,7 +7,7 @@ export const AzureClientSecretRotationSchema = z
.object({
type: z.literal(SecretRotation.AzureClientSecret),
parameters: z.object({
appId: z.string().trim().min(1, "App ID required"),
objectId: z.string().trim().min(1, "Object ID required"),
appName: z.string().trim().min(1, "App Name required"),
clientId: z.string().trim().min(1, "Client ID required")
}),