**Restructure documentation layout, update entrypoint links, and migrate folders** This commit introduces a consistent and modular documentation structure by grouping related documentation under `libs`, `apis`, and `tutorials`. The Dockerfile now reflects the new paths, and the index page links have been adjusted accordingly. ### Folder Migrations The following documentation directories were moved: - `./mongo-ops/site` → `./libs/mongo-ops/site` - `./blog-api/site` → `./apis/blog/site` - `./tutorials/media-manager/site` (unchanged, retained under tutorials) These changes improve namespace clarity and reflect the logical separation between libraries, APIs, and tutorials. ### Additional Changes - Updated URLs in `_index/index.html` to point to `/libs/mongo-ops/` and `/apis/blog/`. - Removed outdated root-level documentation folders.
1057 lines
25 KiB
JSON
1057 lines
25 KiB
JSON
{
|
|
"openapi": "3.1.0",
|
|
"info": {
|
|
"title": "Aetoskia Blog API",
|
|
"description": "\n This is the **Aetoskia Blog API**, part of the personal service network.\n\n Provides:\n - Article CRUD operations\n - User comment management\n - Tag-based search\n\n Fully async, secured via JWT auth.\n ",
|
|
"termsOfService": "https://aetoskia.com/terms",
|
|
"contact": {
|
|
"name": "Aetoskia Dev Team",
|
|
"url": "https://dev.aetoskia.com/contact",
|
|
"email": "dev@aetoskia.com"
|
|
},
|
|
"license": {
|
|
"name": "MIT License",
|
|
"url": "https://opensource.org/licenses/MIT"
|
|
},
|
|
"version": "0.2.0"
|
|
},
|
|
"servers": [
|
|
{
|
|
"url": "https://api.aetoskia.com/blogs",
|
|
"description": "Production server"
|
|
},
|
|
{
|
|
"url": "http://server-pi:9001",
|
|
"description": "Staging environment for internal testing"
|
|
},
|
|
{
|
|
"url": "http://localhost:8000",
|
|
"description": "Local development server"
|
|
}
|
|
],
|
|
"paths": {
|
|
"/authors": {
|
|
"post": {
|
|
"tags": [
|
|
"blog",
|
|
"authors"
|
|
],
|
|
"summary": "Create Author",
|
|
"operationId": "create_author_authors_post",
|
|
"requestBody": {
|
|
"required": true,
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Author"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Author"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"get": {
|
|
"tags": [
|
|
"blog",
|
|
"authors"
|
|
],
|
|
"summary": "List Authors",
|
|
"operationId": "list_authors_authors_get",
|
|
"parameters": [
|
|
{
|
|
"name": "skip",
|
|
"in": "query",
|
|
"required": false,
|
|
"schema": {
|
|
"type": "integer",
|
|
"default": 0,
|
|
"title": "Skip"
|
|
}
|
|
},
|
|
{
|
|
"name": "limit",
|
|
"in": "query",
|
|
"required": false,
|
|
"schema": {
|
|
"type": "integer",
|
|
"default": 10,
|
|
"title": "Limit"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/Author"
|
|
},
|
|
"title": "Response List Authors Authors Get"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/authors/{author_id}": {
|
|
"get": {
|
|
"tags": [
|
|
"blog",
|
|
"authors"
|
|
],
|
|
"summary": "Get Author",
|
|
"operationId": "get_author_authors__author_id__get",
|
|
"parameters": [
|
|
{
|
|
"name": "author_id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"title": "Author Id"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Author"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"put": {
|
|
"tags": [
|
|
"blog",
|
|
"authors"
|
|
],
|
|
"summary": "Update Author",
|
|
"operationId": "update_author_authors__author_id__put",
|
|
"parameters": [
|
|
{
|
|
"name": "author_id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"title": "Author Id"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"required": true,
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Author"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Author"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"tags": [
|
|
"blog",
|
|
"authors"
|
|
],
|
|
"summary": "Delete Author",
|
|
"operationId": "delete_author_authors__author_id__delete",
|
|
"parameters": [
|
|
{
|
|
"name": "author_id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"title": "Author Id"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/articles": {
|
|
"post": {
|
|
"tags": [
|
|
"blog",
|
|
"articles"
|
|
],
|
|
"summary": "Create Article",
|
|
"operationId": "create_article_articles_post",
|
|
"requestBody": {
|
|
"required": true,
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Article"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Article"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"get": {
|
|
"tags": [
|
|
"blog",
|
|
"articles"
|
|
],
|
|
"summary": "List Articles",
|
|
"operationId": "list_articles_articles_get",
|
|
"parameters": [
|
|
{
|
|
"name": "skip",
|
|
"in": "query",
|
|
"required": false,
|
|
"schema": {
|
|
"type": "integer",
|
|
"default": 0,
|
|
"title": "Skip"
|
|
}
|
|
},
|
|
{
|
|
"name": "limit",
|
|
"in": "query",
|
|
"required": false,
|
|
"schema": {
|
|
"type": "integer",
|
|
"default": 10,
|
|
"title": "Limit"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/components/schemas/ArticleResponse"
|
|
},
|
|
"title": "Response List Articles Articles Get"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/articles/{article_id}": {
|
|
"get": {
|
|
"tags": [
|
|
"blog",
|
|
"articles"
|
|
],
|
|
"summary": "Get Article",
|
|
"operationId": "get_article_articles__article_id__get",
|
|
"parameters": [
|
|
{
|
|
"name": "article_id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"title": "Article Id"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/ArticleResponse"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"put": {
|
|
"tags": [
|
|
"blog",
|
|
"articles"
|
|
],
|
|
"summary": "Update Article",
|
|
"operationId": "update_article_articles__article_id__put",
|
|
"parameters": [
|
|
{
|
|
"name": "article_id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"title": "Article Id"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"required": true,
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Article"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/Article"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"delete": {
|
|
"tags": [
|
|
"blog",
|
|
"articles"
|
|
],
|
|
"summary": "Delete Article",
|
|
"operationId": "delete_article_articles__article_id__delete",
|
|
"parameters": [
|
|
{
|
|
"name": "article_id",
|
|
"in": "path",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string",
|
|
"title": "Article Id"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/auth/register": {
|
|
"post": {
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Create User",
|
|
"operationId": "create_user_auth_register_post",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/UserAuth"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/PublicUser"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/auth/login": {
|
|
"post": {
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Login",
|
|
"operationId": "login_auth_login_post",
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/UserAuth"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {}
|
|
}
|
|
}
|
|
},
|
|
"422": {
|
|
"description": "Validation Error",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HTTPValidationError"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/auth/me": {
|
|
"get": {
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Read Users Me",
|
|
"operationId": "read_users_me_auth_me_get",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/PublicUser"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"OAuth2PasswordBearer": []
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"/auth/logout": {
|
|
"post": {
|
|
"tags": [
|
|
"auth"
|
|
],
|
|
"summary": "Logout",
|
|
"operationId": "logout_auth_logout_post",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/health": {
|
|
"get": {
|
|
"summary": "Health Check",
|
|
"operationId": "health_check_health_get",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Successful Response",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"components": {
|
|
"schemas": {
|
|
"Article": {
|
|
"properties": {
|
|
"_id": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"examples": [
|
|
"507f1f77bcf86cd799439011"
|
|
]
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Id"
|
|
},
|
|
"created_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Created At"
|
|
},
|
|
"updated_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Updated At"
|
|
},
|
|
"img": {
|
|
"type": "string",
|
|
"title": "Img"
|
|
},
|
|
"tag": {
|
|
"type": "string",
|
|
"title": "Tag"
|
|
},
|
|
"title": {
|
|
"type": "string",
|
|
"title": "Title"
|
|
},
|
|
"description": {
|
|
"type": "string",
|
|
"title": "Description"
|
|
},
|
|
"content": {
|
|
"type": "string",
|
|
"title": "Content"
|
|
},
|
|
"authors": {
|
|
"items": {
|
|
"type": "string",
|
|
"examples": [
|
|
"507f1f77bcf86cd799439011"
|
|
]
|
|
},
|
|
"type": "array",
|
|
"title": "Authors"
|
|
}
|
|
},
|
|
"type": "object",
|
|
"required": [
|
|
"img",
|
|
"tag",
|
|
"title",
|
|
"description",
|
|
"content",
|
|
"authors"
|
|
],
|
|
"title": "Article",
|
|
"example": {
|
|
"created_at": "2024-01-01T00:00:00",
|
|
"updated_at": "2024-01-01T00:00:00"
|
|
}
|
|
},
|
|
"ArticleResponse": {
|
|
"properties": {
|
|
"_id": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"examples": [
|
|
"507f1f77bcf86cd799439011"
|
|
]
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Id"
|
|
},
|
|
"created_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Created At"
|
|
},
|
|
"updated_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Updated At"
|
|
},
|
|
"img": {
|
|
"type": "string",
|
|
"title": "Img"
|
|
},
|
|
"tag": {
|
|
"type": "string",
|
|
"title": "Tag"
|
|
},
|
|
"title": {
|
|
"type": "string",
|
|
"title": "Title"
|
|
},
|
|
"description": {
|
|
"type": "string",
|
|
"title": "Description"
|
|
},
|
|
"content": {
|
|
"type": "string",
|
|
"title": "Content"
|
|
},
|
|
"authors": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/Author"
|
|
},
|
|
"type": "array",
|
|
"title": "Authors"
|
|
}
|
|
},
|
|
"type": "object",
|
|
"required": [
|
|
"img",
|
|
"tag",
|
|
"title",
|
|
"description",
|
|
"content",
|
|
"authors"
|
|
],
|
|
"title": "ArticleResponse",
|
|
"example": {
|
|
"created_at": "2024-01-01T00:00:00",
|
|
"updated_at": "2024-01-01T00:00:00"
|
|
}
|
|
},
|
|
"Author": {
|
|
"properties": {
|
|
"_id": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"examples": [
|
|
"507f1f77bcf86cd799439011"
|
|
]
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Id"
|
|
},
|
|
"created_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Created At"
|
|
},
|
|
"updated_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Updated At"
|
|
},
|
|
"username": {
|
|
"type": "string",
|
|
"maxLength": 50,
|
|
"minLength": 3,
|
|
"title": "Username"
|
|
},
|
|
"email": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"format": "email"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Email"
|
|
},
|
|
"is_active": {
|
|
"type": "boolean",
|
|
"title": "Is Active",
|
|
"default": true
|
|
},
|
|
"name": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Name"
|
|
},
|
|
"avatar": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Avatar"
|
|
}
|
|
},
|
|
"type": "object",
|
|
"required": [
|
|
"username"
|
|
],
|
|
"title": "Author",
|
|
"example": {
|
|
"created_at": "2024-01-01T00:00:00",
|
|
"updated_at": "2024-01-01T00:00:00"
|
|
}
|
|
},
|
|
"HTTPValidationError": {
|
|
"properties": {
|
|
"detail": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/ValidationError"
|
|
},
|
|
"type": "array",
|
|
"title": "Detail"
|
|
}
|
|
},
|
|
"type": "object",
|
|
"title": "HTTPValidationError"
|
|
},
|
|
"PublicUser": {
|
|
"properties": {
|
|
"_id": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"examples": [
|
|
"507f1f77bcf86cd799439011"
|
|
]
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Id"
|
|
},
|
|
"created_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Created At"
|
|
},
|
|
"updated_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Updated At"
|
|
},
|
|
"username": {
|
|
"type": "string",
|
|
"maxLength": 50,
|
|
"minLength": 3,
|
|
"title": "Username"
|
|
},
|
|
"email": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"format": "email"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Email"
|
|
},
|
|
"is_active": {
|
|
"type": "boolean",
|
|
"title": "Is Active",
|
|
"default": true
|
|
}
|
|
},
|
|
"type": "object",
|
|
"required": [
|
|
"username"
|
|
],
|
|
"title": "PublicUser",
|
|
"example": {
|
|
"created_at": "2024-01-01T00:00:00",
|
|
"updated_at": "2024-01-01T00:00:00"
|
|
}
|
|
},
|
|
"UserAuth": {
|
|
"properties": {
|
|
"_id": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"examples": [
|
|
"507f1f77bcf86cd799439011"
|
|
]
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Id"
|
|
},
|
|
"created_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Created At"
|
|
},
|
|
"updated_at": {
|
|
"type": "string",
|
|
"format": "date-time",
|
|
"title": "Updated At"
|
|
},
|
|
"username": {
|
|
"type": "string",
|
|
"maxLength": 50,
|
|
"minLength": 3,
|
|
"title": "Username"
|
|
},
|
|
"email": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string",
|
|
"format": "email"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Email"
|
|
},
|
|
"is_active": {
|
|
"type": "boolean",
|
|
"title": "Is Active",
|
|
"default": true
|
|
},
|
|
"password": {
|
|
"type": "string",
|
|
"minLength": 6,
|
|
"title": "Password"
|
|
}
|
|
},
|
|
"type": "object",
|
|
"required": [
|
|
"username",
|
|
"password"
|
|
],
|
|
"title": "UserAuth",
|
|
"example": {
|
|
"created_at": "2024-01-01T00:00:00",
|
|
"updated_at": "2024-01-01T00:00:00"
|
|
}
|
|
},
|
|
"ValidationError": {
|
|
"properties": {
|
|
"loc": {
|
|
"items": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "integer"
|
|
}
|
|
]
|
|
},
|
|
"type": "array",
|
|
"title": "Location"
|
|
},
|
|
"msg": {
|
|
"type": "string",
|
|
"title": "Message"
|
|
},
|
|
"type": {
|
|
"type": "string",
|
|
"title": "Error Type"
|
|
}
|
|
},
|
|
"type": "object",
|
|
"required": [
|
|
"loc",
|
|
"msg",
|
|
"type"
|
|
],
|
|
"title": "ValidationError"
|
|
}
|
|
},
|
|
"securitySchemes": {
|
|
"OAuth2PasswordBearer": {
|
|
"type": "oauth2",
|
|
"flows": {
|
|
"password": {
|
|
"scopes": {},
|
|
"tokenUrl": "/auth/login"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"tags": [
|
|
{
|
|
"name": "Articles",
|
|
"description": "Operations for creating, reading, updating, and deleting blog articles."
|
|
},
|
|
{
|
|
"name": "Users",
|
|
"description": "User management and authentication endpoints."
|
|
}
|
|
]
|
|
} |