From 6d3041d35928d3833332376074db4cdff91478cf Mon Sep 17 00:00:00 2001 From: Joel Lee Date: Thu, 1 Aug 2024 07:32:36 +0200 Subject: [PATCH] fix: update openapi spec for MFA (Phone) (#1689) ## What kind of change does this PR introduce? Complement to #1668 Add OpenAPI specification for MFA (Phone). In particular, updates the parameters and `/enroll` `/challenge` and `/verify` --- openapi.yaml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/openapi.yaml b/openapi.yaml index 253b0f3a0d..f4d1e2e1d5 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -693,11 +693,15 @@ paths: type: string enum: - totp + - phone friendly_name: type: string issuer: type: string format: uri + phone: + type: string + format: phone responses: 200: description: > @@ -713,6 +717,7 @@ paths: type: string enum: - totp + - phone totp: type: object properties: @@ -722,6 +727,9 @@ paths: type: string uri: type: string + phone: + type: string + format: phone 400: $ref: "#/components/responses/BadRequestResponse" @@ -741,6 +749,18 @@ paths: schema: type: string format: uuid + requestBody: + content: + application/json: + schema: + type: object + properties: + channel: + type: string + enum: + - sms + - whatsapp + responses: 200: description: > @@ -1959,6 +1979,11 @@ components: description: |- Usually one of: - totp + - phone + phone: + type: string + format: phone + IdentitySchema: type: object