Improve Gitlab sync destination check and show projectId on duplicate destination

This commit is contained in:
Carlos Monastyrski
2025-10-03 01:00:30 -03:00
parent 76976ab85a
commit fb1d5ca257
7 changed files with 112 additions and 28 deletions
@@ -440,7 +440,10 @@ export const registerSyncSecretsEndpoints = <T extends TSecretSync, I extends TS
projectId: z.string().uuid()
}),
response: {
200: z.object({ hasDuplicate: z.boolean() })
200: z.object({
hasDuplicate: z.boolean(),
duplicateProjectId: z.string().uuid().optional()
})
}
},
onRequest: verifyAuth([AuthMode.JWT, AuthMode.IDENTITY_ACCESS_TOKEN]),