|
- {
- "swagger": "2.0",
- "info": {
- "description": "APP客户端-Api接口",
- "title": "蛋蛋星球-APP客户端",
- "termsOfService": "http://swagger.io/terms/",
- "contact": {
- "name": "dengbiao",
- "url": "http://www.swagger.io/support",
- "email": "1239118001@qq.com"
- },
- "license": {
- "name": "Apache 2.0",
- "url": "http://www.apache.org/licenses/LICENSE-2.0.html"
- },
- "version": "1.0"
- },
- "host": "ddxq.izhim.com",
- "basePath": "/api/v1",
- "paths": {
- "/api/v1/comm/getOssUrl": {
- "get": {
- "description": "上传许可链接(获取)",
- "consumes": [
- "application/json"
- ],
- "produces": [
- "application/json"
- ],
- "tags": [
- "对象存储"
- ],
- "summary": "通用请求-对象存储-上传许可链接(获取)",
- "parameters": [
- {
- "type": "string",
- "description": "验证参数Bearer和token空格拼接",
- "name": "Authorization",
- "in": "header",
- "required": true
- }
- ],
- "responses": {
- "200": {
- "description": "许可链接",
- "schema": {
- "type": "string"
- }
- },
- "400": {
- "description": "具体错误",
- "schema": {
- "$ref": "#/definitions/md.Response"
- }
- }
- }
- }
- },
- "/api/v1/test": {
- "post": {
- "description": "Demo样例测试",
- "consumes": [
- "application/json"
- ],
- "produces": [
- "application/json"
- ],
- "tags": [
- "Demo"
- ],
- "summary": "Demo测试",
- "parameters": [
- {
- "description": "任意参数",
- "name": "req",
- "in": "body",
- "required": true,
- "schema": {}
- }
- ],
- "responses": {
- "200": {
- "description": "返回任意参数",
- "schema": {
- "type": "object",
- "additionalProperties": true
- }
- },
- "400": {
- "description": "具体错误",
- "schema": {
- "$ref": "#/definitions/md.Response"
- }
- }
- }
- }
- },
- "/v1/login": {
- "post": {
- "description": "登入",
- "consumes": [
- "application/json"
- ],
- "produces": [
- "application/json"
- ],
- "tags": [
- "登录"
- ],
- "summary": "登陆",
- "parameters": [
- {
- "description": "用户名密码",
- "name": "req",
- "in": "body",
- "required": true,
- "schema": {
- "$ref": "#/definitions/md.LoginReq"
- }
- }
- ],
- "responses": {
- "200": {
- "description": "token",
- "schema": {
- "$ref": "#/definitions/md.LoginResponse"
- }
- },
- "400": {
- "description": "具体错误",
- "schema": {
- "$ref": "#/definitions/md.Response"
- }
- }
- }
- }
- },
- "/v1/register": {
- "post": {
- "description": "注册",
- "consumes": [
- "application/json"
- ],
- "produces": [
- "application/json"
- ],
- "tags": [
- "注册"
- ],
- "summary": "注册",
- "parameters": [
- {
- "description": "注册参数",
- "name": "req",
- "in": "body",
- "required": true,
- "schema": {
- "$ref": "#/definitions/md.RegisterReq"
- }
- }
- ],
- "responses": {
- "200": {
- "description": "登录成功返回",
- "schema": {
- "$ref": "#/definitions/md.LoginResponse"
- }
- },
- "400": {
- "description": "具体错误",
- "schema": {
- "$ref": "#/definitions/md.Response"
- }
- }
- }
- }
- }
- },
- "definitions": {
- "md.LoginReq": {
- "type": "object",
- "required": [
- "password",
- "phone"
- ],
- "properties": {
- "code": {
- "type": "string",
- "example": "验证码"
- },
- "password": {
- "type": "string",
- "example": "登录密码"
- },
- "phone": {
- "type": "string",
- "example": "手机号"
- }
- }
- },
- "md.LoginResponse": {
- "type": "object",
- "properties": {
- "token": {
- "type": "string"
- }
- }
- },
- "md.RegisterReq": {
- "type": "object",
- "required": [
- "mobile"
- ],
- "properties": {
- "avatar": {
- "type": "string",
- "example": "头像"
- },
- "code": {
- "type": "string",
- "example": "验证码"
- },
- "invite_code": {
- "type": "string",
- "example": "邀请码"
- },
- "mobile": {
- "type": "string"
- },
- "nickname": {
- "type": "string",
- "example": "昵称"
- },
- "open_id": {
- "type": "string",
- "example": "微信openId"
- },
- "sex": {
- "description": "性别(0:未知 1:男 2:女)",
- "type": "integer"
- },
- "type": {
- "type": "string",
- "example": "app:APP注册、h5:H5注册"
- },
- "union_id": {
- "type": "string",
- "example": "微信UnionId"
- }
- }
- },
- "md.Response": {
- "type": "object",
- "properties": {
- "code": {
- "type": "string",
- "example": "响应码"
- },
- "data": {
- "description": "内容"
- },
- "msg": {
- "type": "string",
- "example": "具体错误原因"
- }
- }
- }
- }
- }
|