diff --git a/authentik/api/schema.py b/authentik/api/schema.py index b75d20fbcf..f60b333b81 100644 --- a/authentik/api/schema.py +++ b/authentik/api/schema.py @@ -15,17 +15,12 @@ class ErrorResponseAutoSchema(SwaggerAutoSchema): "Generic API Error", type=openapi.TYPE_OBJECT, properties={ - "errors": openapi.Schema( - type=openapi.TYPE_OBJECT, - properties={ - "detail": openapi.Schema( - type=openapi.TYPE_STRING, description="Error details" - ), - "code": openapi.Schema( - type=openapi.TYPE_STRING, description="Error code" - ), - }, - ) + "detail": openapi.Schema( + type=openapi.TYPE_STRING, description="Error details" + ), + "code": openapi.Schema( + type=openapi.TYPE_STRING, description="Error code" + ), }, required=["detail"], ) diff --git a/swagger.yaml b/swagger.yaml index 6acf37ae36..33d0dee8f5 100755 --- a/swagger.yaml +++ b/swagger.yaml @@ -14467,15 +14467,12 @@ definitions: - detail type: object properties: - errors: - type: object - properties: - detail: - description: Error details - type: string - code: - description: Error code - type: string + detail: + description: Error details + type: string + code: + description: Error code + type: string ValidationError: title: Validation Error type: object @@ -14497,15 +14494,12 @@ definitions: - detail type: object properties: - errors: - type: object - properties: - detail: - description: Error details - type: string - code: - description: Error code - type: string + detail: + description: Error details + type: string + code: + description: Error code + type: string Coordinate: type: object properties: