{ "openapi": "3.0.4", "info": { "title": "AiSupportBackend.API", "version": "1.0" }, "paths": { "/api/Admin/register": { "post": { "tags": [ "Admin" ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Admin" } }, "text/json": { "schema": { "$ref": "#/components/schemas/Admin" } }, "application/*+json": { "schema": { "$ref": "#/components/schemas/Admin" } } } }, "responses": { "200": { "description": "OK" } } } }, "/api/Admin/login": { "post": { "tags": [ "Admin" ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LoginRequest" } }, "text/json": { "schema": { "$ref": "#/components/schemas/LoginRequest" } }, "application/*+json": { "schema": { "$ref": "#/components/schemas/LoginRequest" } } } }, "responses": { "200": { "description": "OK" } } } }, "/api/Chat": { "post": { "tags": [ "Chat" ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ChatRequest" } }, "text/json": { "schema": { "$ref": "#/components/schemas/ChatRequest" } }, "application/*+json": { "schema": { "$ref": "#/components/schemas/ChatRequest" } } } }, "responses": { "200": { "description": "OK" } } } }, "/api/Products": { "get": { "tags": [ "Products" ], "responses": { "200": { "description": "OK" } } }, "post": { "tags": [ "Products" ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Product" } }, "text/json": { "schema": { "$ref": "#/components/schemas/Product" } }, "application/*+json": { "schema": { "$ref": "#/components/schemas/Product" } } } }, "responses": { "200": { "description": "OK" } } } }, "/api/Products/{id}": { "get": { "tags": [ "Products" ], "parameters": [ { "name": "id", "in": "path", "required": true, "schema": { "type": "integer", "format": "int32" } } ], "responses": { "200": { "description": "OK" } } }, "put": { "tags": [ "Products" ], "parameters": [ { "name": "id", "in": "path", "required": true, "schema": { "type": "integer", "format": "int32" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Product" } }, "text/json": { "schema": { "$ref": "#/components/schemas/Product" } }, "application/*+json": { "schema": { "$ref": "#/components/schemas/Product" } } } }, "responses": { "200": { "description": "OK" } } }, "delete": { "tags": [ "Products" ], "parameters": [ { "name": "id", "in": "path", "required": true, "schema": { "type": "integer", "format": "int32" } } ], "responses": { "200": { "description": "OK" } } } } }, "components": { "schemas": { "Admin": { "type": "object", "properties": { "id": { "type": "integer", "format": "int32" }, "username": { "type": "string", "nullable": true }, "passwordHash": { "type": "string", "nullable": true }, "email": { "type": "string", "nullable": true } }, "additionalProperties": false }, "ChatRequest": { "type": "object", "properties": { "productId": { "type": "integer", "format": "int32" }, "message": { "type": "string", "nullable": true } }, "additionalProperties": false }, "LoginRequest": { "type": "object", "properties": { "username": { "type": "string", "nullable": true }, "password": { "type": "string", "nullable": true } }, "additionalProperties": false }, "Product": { "type": "object", "properties": { "id": { "type": "integer", "format": "int32" }, "name": { "type": "string", "nullable": true }, "description": { "type": "string", "nullable": true }, "price": { "type": "number", "format": "double" }, "createdAt": { "type": "string", "format": "date-time" }, "imageUrl": { "type": "string", "nullable": true } }, "additionalProperties": false } } } }