From df6468170793c35feada52f2e2f10399eccd769b Mon Sep 17 00:00:00 2001 From: Giovanni Berti Date: Thu, 16 May 2024 10:16:17 +0200 Subject: [PATCH] [CHK-2821] refactor(wallet-api): expose client info to wallet API (#1985) --- .../api/payment-wallet/v1/_openapi.json.tpl | 35 ++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/src/domains/wallet-app/api/payment-wallet/v1/_openapi.json.tpl b/src/domains/wallet-app/api/payment-wallet/v1/_openapi.json.tpl index 789c87480a..8a1c3215fc 100644 --- a/src/domains/wallet-app/api/payment-wallet/v1/_openapi.json.tpl +++ b/src/domains/wallet-app/api/payment-wallet/v1/_openapi.json.tpl @@ -616,14 +616,34 @@ }, "status": { "$ref": "#/components/schemas/WalletApplicationStatus" + } + }, + "required": [ + "name", + "status" + ] + }, + "WalletClientStatus": { + "type": "string", + "description": "Enumeration of wallet client statuses", + "enum": [ + "ENABLED", + "DISABLED" + ] + }, + "WalletClient": { + "type": "object", + "properties": { + "status": { + "$ref": "#/components/schemas/WalletClientStatus" }, "lastUsage": { "type": "string", + "description": "Time of last usage of this wallet by the client", "format": "date-time" } }, "required": [ - "name", "status" ] }, @@ -658,6 +678,18 @@ "$ref": "#/components/schemas/WalletApplicationInfo" } }, + "clients": { + "description": "Client-specific state (e.g. last usage) and configuration (enabled/disabled)", + "type": "object", + "properties": { + "IO": { + "$ref": "#/components/schemas/WalletClient" + } + }, + "additionalProperties": { + "$ref": "#/components/schemas/WalletClient" + } + }, "details": { "$ref": "#/components/schemas/WalletInfoDetails" }, @@ -675,6 +707,7 @@ "creationDate", "updateDate", "applications", + "clients", "paymentMethodAsset" ] },