From a0df0dff00e732b0a7453eb99a9b15c5a9b9f2d1 Mon Sep 17 00:00:00 2001 From: nihonium Date: Sat, 11 Oct 2025 04:51:50 +0300 Subject: [PATCH] feat: add User scahema to api --- api/openapi.yaml | 42 +++++++++++++++++++++++++++++++++++++++++- 1 file changed, 41 insertions(+), 1 deletion(-) diff --git a/api/openapi.yaml b/api/openapi.yaml index 5a35e20..ca6099f 100644 --- a/api/openapi.yaml +++ b/api/openapi.yaml @@ -540,7 +540,47 @@ components: additionalProperties: true User: type: object - additionalProperties: true + properties: + user_id: + type: integer + format: int32 + description: Unique user ID (primary key) + example: 1 + avatar_id: + type: integer + format: int32 + description: ID of the user avatar (references images table) + nullable: true + example: null + mail: + type: string + format: email + description: User email + example: "john.doe@example.com" + nickname: + type: string + description: Username (alphanumeric + _ or -) + maxLength: 16 + example: "john_doe_42" + disp_name: + type: string + description: Display name + maxLength: 32 + example: "John Doe" + user_desc: + type: string + description: User description + maxLength: 512 + example: "Just a regular user." + creation_date: + type: string + format: date-time + description: Timestamp when the user was created + example: "2025-10-10T23:45:47.908073Z" + required: + - user_id + - nickname + - creation_date UserTitle: type: object additionalProperties: true