swagger.json 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676
  1. {
  2. "swagger": "2.0",
  3. "info": {
  4. "contact": {}
  5. },
  6. "paths": {
  7. "/login": {
  8. "post": {
  9. "description": "输入手机号和验证码,并登录",
  10. "consumes": [
  11. "application/json"
  12. ],
  13. "produces": [
  14. "application/json"
  15. ],
  16. "summary": "login 登录",
  17. "parameters": [
  18. {
  19. "description": "登录输入内容请求参数结构体",
  20. "name": "req",
  21. "in": "body",
  22. "required": true,
  23. "schema": {
  24. "$ref": "#/definitions/http_model.CodeLoginRequest"
  25. }
  26. }
  27. ],
  28. "responses": {
  29. "200": {
  30. "description": "登录返回相应结构体",
  31. "schema": {
  32. "allOf": [
  33. {
  34. "$ref": "#/definitions/http_model.CommonResponse"
  35. },
  36. {
  37. "type": "object",
  38. "properties": {
  39. "data": {
  40. "$ref": "#/definitions/http_model.CodeLoginData"
  41. }
  42. }
  43. }
  44. ]
  45. }
  46. }
  47. }
  48. }
  49. },
  50. "/product/create": {
  51. "post": {
  52. "description": "企业创建商品,添加到商品库",
  53. "consumes": [
  54. "application/json"
  55. ],
  56. "produces": [
  57. "application/json"
  58. ],
  59. "summary": "CreateProduct 创建商品",
  60. "parameters": [
  61. {
  62. "type": "string",
  63. "description": "登录TOKEN信息",
  64. "name": "Authorization",
  65. "in": "header",
  66. "required": true
  67. },
  68. {
  69. "description": "创建商品请求结构体",
  70. "name": "req",
  71. "in": "body",
  72. "required": true,
  73. "schema": {
  74. "$ref": "#/definitions/http_model.CreateProductRequest"
  75. }
  76. }
  77. ],
  78. "responses": {
  79. "200": {
  80. "description": "创建商品相应结构体",
  81. "schema": {
  82. "allOf": [
  83. {
  84. "$ref": "#/definitions/http_model.CommonResponse"
  85. },
  86. {
  87. "type": "object",
  88. "properties": {
  89. "data": {
  90. "$ref": "#/definitions/http_model.CreateProductData"
  91. }
  92. }
  93. }
  94. ]
  95. }
  96. }
  97. }
  98. }
  99. },
  100. "/product/find": {
  101. "post": {
  102. "description": "根据产品名称查询产品信息",
  103. "consumes": [
  104. "application/json"
  105. ],
  106. "produces": [
  107. "application/json"
  108. ],
  109. "summary": "findProduct 根据产品名称查询产品信息",
  110. "parameters": [
  111. {
  112. "type": "string",
  113. "description": "登录TOKEN信息",
  114. "name": "Authorization",
  115. "in": "header",
  116. "required": true
  117. },
  118. {
  119. "description": "发送产品id请求参数结构体",
  120. "name": "req",
  121. "in": "body",
  122. "required": true,
  123. "schema": {
  124. "$ref": "#/definitions/http_model.FindProductRequest"
  125. }
  126. }
  127. ],
  128. "responses": {
  129. "200": {
  130. "description": "查询对应产品返回相应结构体",
  131. "schema": {
  132. "allOf": [
  133. {
  134. "$ref": "#/definitions/http_model.CommonResponse"
  135. },
  136. {
  137. "type": "object",
  138. "properties": {
  139. "data": {
  140. "$ref": "#/definitions/http_model.FindProductData"
  141. }
  142. }
  143. }
  144. ]
  145. }
  146. }
  147. }
  148. }
  149. },
  150. "/product/list": {
  151. "post": {
  152. "description": "展示企业的商品列表",
  153. "consumes": [
  154. "application/json"
  155. ],
  156. "produces": [
  157. "application/json"
  158. ],
  159. "summary": "ProjectList 商品列表",
  160. "parameters": [
  161. {
  162. "type": "string",
  163. "description": "登录TOKEN信息",
  164. "name": "Authorization",
  165. "in": "header",
  166. "required": true
  167. },
  168. {
  169. "description": "创建全部商品请求结构体",
  170. "name": "req",
  171. "in": "body",
  172. "required": true,
  173. "schema": {
  174. "$ref": "#/definitions/http_model.FullProjectListRequest"
  175. }
  176. }
  177. ],
  178. "responses": {
  179. "200": {
  180. "description": "创建全部商品列表相应结构体",
  181. "schema": {
  182. "allOf": [
  183. {
  184. "$ref": "#/definitions/http_model.CommonResponse"
  185. },
  186. {
  187. "type": "object",
  188. "properties": {
  189. "data": {
  190. "$ref": "#/definitions/http_model.FullProjectListData"
  191. }
  192. }
  193. }
  194. ]
  195. }
  196. }
  197. }
  198. }
  199. },
  200. "/project/show": {
  201. "post": {
  202. "description": "企业查看执行中项目",
  203. "consumes": [
  204. "application/json"
  205. ],
  206. "produces": [
  207. "application/json"
  208. ],
  209. "summary": "CreateProduct 创建商品",
  210. "parameters": [
  211. {
  212. "type": "string",
  213. "description": "登录TOKEN信息",
  214. "name": "Authorization",
  215. "in": "header",
  216. "required": true
  217. },
  218. {
  219. "description": "查看项目请求结构体",
  220. "name": "req",
  221. "in": "body",
  222. "required": true,
  223. "schema": {
  224. "$ref": "#/definitions/http_model.ShowProjectRequest"
  225. }
  226. }
  227. ],
  228. "responses": {
  229. "200": {
  230. "description": "查看项目相应结构体",
  231. "schema": {
  232. "allOf": [
  233. {
  234. "$ref": "#/definitions/http_model.CommonResponse"
  235. },
  236. {
  237. "type": "object",
  238. "properties": {
  239. "data": {
  240. "$ref": "#/definitions/http_model.ShowProjectData"
  241. }
  242. }
  243. }
  244. ]
  245. }
  246. }
  247. }
  248. }
  249. },
  250. "/sendCode": {
  251. "post": {
  252. "description": "发送验证码,每次发送到邮箱",
  253. "consumes": [
  254. "application/json"
  255. ],
  256. "produces": [
  257. "application/json"
  258. ],
  259. "summary": "sendCode 发送验证码",
  260. "parameters": [
  261. {
  262. "description": "发送验证码请求参数结构体",
  263. "name": "req",
  264. "in": "body",
  265. "required": true,
  266. "schema": {
  267. "$ref": "#/definitions/http_model.SendCodeRequest"
  268. }
  269. }
  270. ],
  271. "responses": {
  272. "200": {
  273. "description": "发送验证码请求相应结构体",
  274. "schema": {
  275. "allOf": [
  276. {
  277. "$ref": "#/definitions/http_model.CommonResponse"
  278. },
  279. {
  280. "type": "object",
  281. "properties": {
  282. "data": {
  283. "$ref": "#/definitions/http_model.SendCodeData"
  284. }
  285. }
  286. }
  287. ]
  288. }
  289. }
  290. }
  291. }
  292. }
  293. },
  294. "definitions": {
  295. "http_model.CodeLoginData": {
  296. "type": "object",
  297. "properties": {
  298. "token": {
  299. "type": "string"
  300. }
  301. }
  302. },
  303. "http_model.CodeLoginRequest": {
  304. "type": "object",
  305. "properties": {
  306. "code": {
  307. "type": "string"
  308. },
  309. "phone": {
  310. "type": "string"
  311. }
  312. }
  313. },
  314. "http_model.CommonResponse": {
  315. "type": "object",
  316. "properties": {
  317. "data": {},
  318. "message": {
  319. "type": "string"
  320. },
  321. "status": {
  322. "type": "integer"
  323. }
  324. }
  325. },
  326. "http_model.CreateProductData": {
  327. "type": "object",
  328. "properties": {
  329. "product_id": {
  330. "description": "商品id",
  331. "type": "integer"
  332. }
  333. }
  334. },
  335. "http_model.CreateProductPhoto": {
  336. "type": "object",
  337. "properties": {
  338. "photo_uid": {
  339. "type": "string"
  340. },
  341. "photo_url": {
  342. "description": "图片或视频url",
  343. "type": "string"
  344. },
  345. "symbol": {
  346. "description": "图片为主图或详情图标志位,1为主图,2为详情图,3为视频",
  347. "type": "integer"
  348. }
  349. }
  350. },
  351. "http_model.CreateProductRequest": {
  352. "type": "object",
  353. "properties": {
  354. "brand_name": {
  355. "type": "string"
  356. },
  357. "product_detail": {
  358. "type": "string"
  359. },
  360. "product_id": {
  361. "type": "integer"
  362. },
  363. "product_name": {
  364. "description": "商品名称",
  365. "type": "string"
  366. },
  367. "product_photos": {
  368. "description": "商品图片列表",
  369. "type": "array",
  370. "items": {
  371. "$ref": "#/definitions/http_model.CreateProductPhoto"
  372. }
  373. },
  374. "product_price": {
  375. "description": "商品价值",
  376. "type": "integer"
  377. },
  378. "product_type": {
  379. "description": "商品类型",
  380. "type": "integer"
  381. },
  382. "product_url": {
  383. "description": "商品链接,可为电商网址、公司官网、大众点评的店铺地址等可以说明商品信息或者品牌信息的线上地址;",
  384. "type": "string"
  385. },
  386. "shop_address": {
  387. "description": "店铺地址,商品类型为线下品牌时需填写",
  388. "type": "string"
  389. }
  390. }
  391. },
  392. "http_model.FindProductData": {
  393. "type": "object",
  394. "properties": {
  395. "brand_name": {
  396. "description": "品牌名称",
  397. "type": "string"
  398. },
  399. "enterprise_id": {
  400. "description": "所属企业id",
  401. "type": "integer"
  402. },
  403. "product_detail": {
  404. "type": "string"
  405. },
  406. "product_id": {
  407. "type": "integer"
  408. },
  409. "product_name": {
  410. "description": "商品名称",
  411. "type": "string"
  412. },
  413. "product_photos": {
  414. "description": "商品图片列表",
  415. "type": "array",
  416. "items": {
  417. "$ref": "#/definitions/http_model.ProductPhoto"
  418. }
  419. },
  420. "product_price": {
  421. "description": "商品价值",
  422. "type": "integer"
  423. },
  424. "product_type": {
  425. "description": "商品类型",
  426. "type": "integer"
  427. },
  428. "product_url": {
  429. "description": "商品链接,可为电商网址、公司官网、大众点评的店铺地址等可以说明商品信息或者品牌信息的线上地址;",
  430. "type": "string"
  431. },
  432. "shop_address": {
  433. "description": "店铺地址,商品类型为线下品牌时需填写",
  434. "type": "string"
  435. }
  436. }
  437. },
  438. "http_model.FindProductRequest": {
  439. "type": "object",
  440. "properties": {
  441. "product_id": {
  442. "type": "integer"
  443. }
  444. }
  445. },
  446. "http_model.FullProjectListData": {
  447. "type": "object",
  448. "properties": {
  449. "full_project_pre_view": {
  450. "type": "array",
  451. "items": {
  452. "$ref": "#/definitions/http_model.FullProjectPreview"
  453. }
  454. },
  455. "total": {
  456. "type": "string"
  457. }
  458. }
  459. },
  460. "http_model.FullProjectListRequest": {
  461. "type": "object",
  462. "properties": {
  463. "page_num": {
  464. "type": "integer"
  465. },
  466. "page_size": {
  467. "type": "integer"
  468. },
  469. "project_content_type": {
  470. "description": "内容形式",
  471. "type": "string"
  472. },
  473. "project_fee_forms": {
  474. "description": "稿费形式",
  475. "type": "string"
  476. },
  477. "project_form": {
  478. "description": "项目形式",
  479. "type": "string"
  480. },
  481. "project_platform": {
  482. "description": "项目平台",
  483. "type": "string"
  484. },
  485. "project_status": {
  486. "description": "项目状态",
  487. "type": "string"
  488. },
  489. "project_updated": {
  490. "description": "最后操作时间",
  491. "type": "string"
  492. }
  493. }
  494. },
  495. "http_model.FullProjectPreview": {
  496. "type": "object",
  497. "properties": {
  498. "project_content_type": {
  499. "description": "内容形式",
  500. "type": "string"
  501. },
  502. "project_fee_forms": {
  503. "description": "稿费形式",
  504. "type": "array",
  505. "items": {
  506. "type": "string"
  507. }
  508. },
  509. "project_form": {
  510. "description": "项目形式",
  511. "type": "string"
  512. },
  513. "project_id": {
  514. "description": "项目ID",
  515. "type": "string"
  516. },
  517. "project_name": {
  518. "description": "项目名",
  519. "type": "string"
  520. },
  521. "project_platform": {
  522. "description": "项目平台",
  523. "type": "string"
  524. },
  525. "project_status": {
  526. "description": "项目状态",
  527. "type": "string"
  528. },
  529. "project_updated": {
  530. "description": "最后操作时间",
  531. "type": "string"
  532. }
  533. }
  534. },
  535. "http_model.ProductPhoto": {
  536. "type": "object",
  537. "properties": {
  538. "photo_uid": {
  539. "type": "string"
  540. },
  541. "photo_url": {
  542. "description": "图片或视频url",
  543. "type": "string"
  544. },
  545. "symbol": {
  546. "description": "图片为主图或详情图标志位,1为主图,2为详情图,3为视频",
  547. "type": "integer"
  548. }
  549. }
  550. },
  551. "http_model.SendCodeData": {
  552. "type": "object"
  553. },
  554. "http_model.SendCodeRequest": {
  555. "type": "object",
  556. "properties": {
  557. "phone": {
  558. "type": "string"
  559. }
  560. }
  561. },
  562. "http_model.ShowProjectData": {
  563. "type": "object",
  564. "properties": {
  565. "Project_id": {
  566. "description": "项目id",
  567. "type": "string"
  568. },
  569. "content_type": {
  570. "description": "内容形式,1代表图文,2代表视频",
  571. "type": "string"
  572. },
  573. "product_id": {
  574. "description": "关联商品id",
  575. "type": "string"
  576. },
  577. "project_detail": {
  578. "description": "项目详情",
  579. "type": "string"
  580. },
  581. "project_form": {
  582. "description": "项目形式,1-4分别代表实体商品寄拍、虚拟产品测评、线下探店打卡、素材微原创",
  583. "type": "string"
  584. },
  585. "project_name": {
  586. "description": "项目名称",
  587. "type": "string"
  588. },
  589. "project_photos": {
  590. "description": "项目图片",
  591. "type": "array",
  592. "items": {
  593. "$ref": "#/definitions/http_model.ShowProjectPhoto"
  594. }
  595. },
  596. "project_platform": {
  597. "description": "项目平台,1-7分别代表小红书、抖音、微博、快手、b站、大众点评、知乎",
  598. "type": "string"
  599. },
  600. "project_status": {
  601. "description": "项目状态,1-7分别代表创建中、待审核、招募中、待支付、失效、执行中、已结案",
  602. "type": "string"
  603. },
  604. "project_type": {
  605. "description": "项目类型,1代表全流程项目,2代表专项项目",
  606. "type": "string"
  607. },
  608. "recruit_ddl": {
  609. "description": "招募截止时间",
  610. "type": "string"
  611. },
  612. "recruit_strategys": {
  613. "description": "定价策略",
  614. "type": "array",
  615. "items": {
  616. "$ref": "#/definitions/http_model.ShowRecruitStrategy"
  617. }
  618. },
  619. "talent_type": {
  620. "description": "达人类型",
  621. "type": "string"
  622. }
  623. }
  624. },
  625. "http_model.ShowProjectPhoto": {
  626. "type": "object",
  627. "properties": {
  628. "photo_uid": {
  629. "type": "string"
  630. },
  631. "photo_url": {
  632. "description": "图片url",
  633. "type": "string"
  634. }
  635. }
  636. },
  637. "http_model.ShowProjectRequest": {
  638. "type": "object",
  639. "properties": {
  640. "Project_id": {
  641. "description": "项目id",
  642. "type": "integer"
  643. }
  644. }
  645. },
  646. "http_model.ShowRecruitStrategy": {
  647. "type": "object",
  648. "properties": {
  649. "fee_form": {
  650. "description": "稿费形式,1-3分别代表自报价、固定稿费、产品置换",
  651. "type": "string"
  652. },
  653. "followers_low": {
  654. "description": "达人粉丝数下限",
  655. "type": "string"
  656. },
  657. "followers_up": {
  658. "description": "达人粉丝数上限",
  659. "type": "string"
  660. },
  661. "offer": {
  662. "description": "报价",
  663. "type": "string"
  664. },
  665. "recruit_number": {
  666. "description": "招募数量",
  667. "type": "string"
  668. },
  669. "strategy_id": {
  670. "description": "策略id",
  671. "type": "string"
  672. }
  673. }
  674. }
  675. }
  676. }