docs: 补充打手初始化流程说明

This commit is contained in:
zetaloop
2026-04-04 07:08:28 +08:00
parent 93679d2ff3
commit e7651a56d9
+176 -7
View File
@@ -240,6 +240,181 @@
} }
} }
}, },
"/api/v1/players/me": {
"post": {
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"schemes": [
"https"
],
"summary": "初始化当前用户的打手资料",
"operationId": "playerInitPlayer",
"parameters": [
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"type": "object"
}
}
],
"responses": {
"200": {
"description": "",
"schema": {
"type": "object",
"properties": {
"completionRate": {
"type": "number"
},
"games": {
"type": "array",
"items": {
"type": "string"
}
},
"gender": {
"type": "boolean"
},
"id": {
"type": "integer"
},
"rating": {
"type": "number"
},
"services": {
"type": "array",
"items": {
"type": "object",
"required": [
"id",
"playerId",
"gameId",
"gameName",
"title",
"description",
"price",
"unit",
"availability"
],
"properties": {
"availability": {
"type": "array",
"items": {
"type": "string"
}
},
"description": {
"type": "string"
},
"gameId": {
"type": "integer"
},
"gameName": {
"type": "string"
},
"id": {
"type": "integer"
},
"playerId": {
"type": "integer"
},
"price": {
"type": "number"
},
"rankRange": {
"type": "string"
},
"title": {
"type": "string"
},
"unit": {
"type": "string"
}
}
}
},
"shopId": {
"type": "string"
},
"shopName": {
"type": "string"
},
"status": {
"type": "string"
},
"tags": {
"type": "array",
"items": {
"type": "string"
}
},
"totalOrders": {
"type": "integer"
},
"user": {
"type": "object",
"required": [
"id",
"username",
"nickname",
"avatar",
"role",
"verifiedRoles",
"verificationStatus",
"createdAt"
],
"properties": {
"avatar": {
"type": "string"
},
"bio": {
"type": "string"
},
"createdAt": {
"type": "string"
},
"id": {
"type": "string"
},
"nickname": {
"type": "string"
},
"phone": {
"type": "string"
},
"role": {
"description": "consumer, player, owner, admin",
"type": "string"
},
"username": {
"type": "string"
},
"verificationStatus": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"verifiedRoles": {
"type": "array",
"items": {
"type": "string"
}
}
}
}
}
}
}
}
}
},
"/api/v1/players/me/status": { "/api/v1/players/me/status": {
"put": { "put": {
"consumes": [ "consumes": [
@@ -684,12 +859,6 @@
"summary": "创建服务", "summary": "创建服务",
"operationId": "playerCreateService", "operationId": "playerCreateService",
"parameters": [ "parameters": [
{
"type": "integer",
"name": "id",
"in": "path",
"required": true
},
{ {
"name": "body", "name": "body",
"in": "body", "in": "body",
@@ -975,4 +1144,4 @@
"x-github": "https://github.com/zeromicro/go-zero", "x-github": "https://github.com/zeromicro/go-zero",
"x-go-zero-doc": "https://go-zero.dev/", "x-go-zero-doc": "https://go-zero.dev/",
"x-goctl-version": "1.9.2" "x-goctl-version": "1.9.2"
} }