add godotenv, regenerate swagger docs

This commit is contained in:
zardzul
2026-03-13 22:23:42 +01:00
parent 82e1b51d38
commit 873cd6a57d
12 changed files with 71 additions and 48 deletions
+29 -29
View File
@@ -1,4 +1,4 @@
basePath: /
basePath: /api/v1/
definitions:
handlers.CreateUserRequest:
properties:
@@ -37,7 +37,7 @@ info:
title: Music Index API
version: "1.0"
paths:
/artist/getAll:
/artists:
get:
produces:
- application/json
@@ -56,7 +56,33 @@ paths:
summary: List all artists
tags:
- artist
/user/create:
/users/{id}:
get:
parameters:
- description: User ID (UUID)
in: path
name: id
required: true
type: string
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/handlers.UsernameResponse'
"400":
description: Bad Request
schema:
$ref: '#/definitions/handlers.ErrorResponse'
"500":
description: Internal Server Error
schema:
$ref: '#/definitions/handlers.ErrorResponse'
summary: Get username by user ID
tags:
- user
/users/create:
post:
consumes:
- application/json
@@ -85,30 +111,4 @@ paths:
summary: Create a user
tags:
- user
/user/getUserNameByID/{id}:
get:
parameters:
- description: User ID (UUID)
in: path
name: id
required: true
type: string
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/handlers.UsernameResponse'
"400":
description: Bad Request
schema:
$ref: '#/definitions/handlers.ErrorResponse'
"500":
description: Internal Server Error
schema:
$ref: '#/definitions/handlers.ErrorResponse'
summary: Get username by user ID
tags:
- user
swagger: "2.0"