swagger.json 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579
  1. {
  2. "swagger": "2.0",
  3. "info": {
  4. "description": "新的查询服务,替代原通用查询服务。",
  5. "title": "MTP2.0 查询服务 API",
  6. "termsOfService": "http://muchinfo.cn",
  7. "contact": {},
  8. "license": {},
  9. "version": "1.0"
  10. },
  11. "basePath": "/api",
  12. "paths": {
  13. "/CPTrade/QueryCPTradePositionCancel": {
  14. "get": {
  15. "security": [
  16. {
  17. "ApiKeyAuth": []
  18. }
  19. ],
  20. "produces": [
  21. "application/json"
  22. ],
  23. "tags": [
  24. "产能预售"
  25. ],
  26. "summary": "查询远期订单注销申请信息",
  27. "parameters": [
  28. {
  29. "type": "integer",
  30. "description": "账户ID",
  31. "name": "userid",
  32. "in": "query",
  33. "required": true
  34. },
  35. {
  36. "type": "integer",
  37. "description": "注销ID",
  38. "name": "cancelid",
  39. "in": "query"
  40. },
  41. {
  42. "type": "integer",
  43. "description": "资金账户ID",
  44. "name": "accountid",
  45. "in": "query"
  46. }
  47. ],
  48. "responses": {
  49. "200": {
  50. "description": "OK",
  51. "schema": {
  52. "$ref": "#/definitions/cptrade.Cptradepositioncancel"
  53. }
  54. },
  55. "500": {
  56. "description": "Internal Server Error",
  57. "schema": {
  58. "$ref": "#/definitions/app.Response"
  59. }
  60. }
  61. }
  62. }
  63. },
  64. "/CPTrade/QueryCPTradeUserGoodsData": {
  65. "get": {
  66. "security": [
  67. {
  68. "ApiKeyAuth": []
  69. }
  70. ],
  71. "produces": [
  72. "application/json"
  73. ],
  74. "tags": [
  75. "产能预售"
  76. ],
  77. "summary": "查询远期订单信息",
  78. "parameters": [
  79. {
  80. "type": "integer",
  81. "description": "资金账户ID",
  82. "name": "accountid",
  83. "in": "query",
  84. "required": true
  85. }
  86. ],
  87. "responses": {
  88. "200": {
  89. "description": "OK",
  90. "schema": {
  91. "$ref": "#/definitions/cptrade.Cptradeusergoodsdata"
  92. }
  93. },
  94. "500": {
  95. "description": "Internal Server Error",
  96. "schema": {
  97. "$ref": "#/definitions/app.Response"
  98. }
  99. }
  100. }
  101. }
  102. },
  103. "/CPTrade/QueryPreasleApply": {
  104. "get": {
  105. "security": [
  106. {
  107. "ApiKeyAuth": []
  108. }
  109. ],
  110. "produces": [
  111. "application/json"
  112. ],
  113. "tags": [
  114. "产能预售"
  115. ],
  116. "summary": "查询产能预售申请信息",
  117. "parameters": [
  118. {
  119. "type": "integer",
  120. "description": "账户ID",
  121. "name": "userid",
  122. "in": "query",
  123. "required": true
  124. },
  125. {
  126. "type": "integer",
  127. "description": "申请ID",
  128. "name": "applyid",
  129. "in": "query"
  130. },
  131. {
  132. "type": "integer",
  133. "description": "资金账户ID",
  134. "name": "accountid",
  135. "in": "query"
  136. }
  137. ],
  138. "responses": {
  139. "200": {
  140. "description": "OK",
  141. "schema": {
  142. "$ref": "#/definitions/cptrade.Cptradepresaleapply"
  143. }
  144. },
  145. "500": {
  146. "description": "Internal Server Error",
  147. "schema": {
  148. "$ref": "#/definitions/app.Response"
  149. }
  150. }
  151. }
  152. }
  153. },
  154. "/CPTrade/QueryPresaleGoodsEx": {
  155. "get": {
  156. "security": [
  157. {
  158. "ApiKeyAuth": []
  159. }
  160. ],
  161. "produces": [
  162. "application/json"
  163. ],
  164. "tags": [
  165. "产能预售"
  166. ],
  167. "summary": "查询产能预售商品扩展信息",
  168. "parameters": [
  169. {
  170. "type": "integer",
  171. "description": "预售商品ID",
  172. "name": "goodsid",
  173. "in": "query"
  174. },
  175. {
  176. "type": "integer",
  177. "description": "预售市场ID",
  178. "name": "marketid",
  179. "in": "query"
  180. },
  181. {
  182. "type": "integer",
  183. "description": "预售模式 - 1:一口价 2:大宗式竞拍",
  184. "name": "presalemode",
  185. "in": "query"
  186. }
  187. ],
  188. "responses": {
  189. "200": {
  190. "description": "OK",
  191. "schema": {
  192. "$ref": "#/definitions/cptrade.Cptradepresalegoodsex"
  193. }
  194. },
  195. "500": {
  196. "description": "Internal Server Error",
  197. "schema": {
  198. "$ref": "#/definitions/app.Response"
  199. }
  200. }
  201. }
  202. }
  203. },
  204. "/WRTrade/GetAllDeliveryGoods": {
  205. "get": {
  206. "security": [
  207. {
  208. "ApiKeyAuth": []
  209. }
  210. ],
  211. "produces": [
  212. "application/json"
  213. ],
  214. "tags": [
  215. "仓单贸易"
  216. ],
  217. "summary": "获取带仓单分类的种类信息",
  218. "responses": {
  219. "200": {
  220. "description": "OK",
  221. "schema": {
  222. "$ref": "#/definitions/app.Response"
  223. }
  224. },
  225. "500": {
  226. "description": "Internal Server Error",
  227. "schema": {
  228. "$ref": "#/definitions/app.Response"
  229. }
  230. }
  231. }
  232. }
  233. }
  234. },
  235. "definitions": {
  236. "app.Response": {
  237. "type": "object",
  238. "properties": {
  239. "code": {
  240. "type": "integer"
  241. },
  242. "data": {
  243. "type": "object"
  244. },
  245. "msg": {
  246. "type": "string"
  247. }
  248. }
  249. },
  250. "cptrade.Cptradepositioncancel": {
  251. "type": "object",
  252. "required": [
  253. "cancelid"
  254. ],
  255. "properties": {
  256. "accountid": {
  257. "description": "申请人账户ID",
  258. "type": "integer"
  259. },
  260. "applystatus": {
  261. "description": "申请状态 - 1:已提交 2:初审通过 3:初审拒绝 4:初审失败 5复审通过 6:复审拒绝 7:复审失败 8:已撤销",
  262. "type": "integer"
  263. },
  264. "applytime": {
  265. "description": "申请时间",
  266. "type": "string"
  267. },
  268. "cancelid": {
  269. "description": "注销ID(SEQ_CPTRADE_POSITIONCANCEL)",
  270. "type": "integer"
  271. },
  272. "cancelqty": {
  273. "description": "注销数量",
  274. "type": "integer"
  275. },
  276. "createtime": {
  277. "description": "创建时间",
  278. "type": "string"
  279. },
  280. "creatorid": {
  281. "description": "创建人",
  282. "type": "integer"
  283. },
  284. "goodscode": {
  285. "description": "订单商品代码",
  286. "type": "string"
  287. },
  288. "goodsid": {
  289. "description": "商品ID",
  290. "type": "integer"
  291. },
  292. "goodsname": {
  293. "description": "订单商品名称",
  294. "type": "string"
  295. },
  296. "goodunit": {
  297. "description": "报价单位",
  298. "type": "string"
  299. },
  300. "handlestatus": {
  301. "description": "处理状态",
  302. "type": "integer"
  303. },
  304. "marketid": {
  305. "description": "市场ID",
  306. "type": "integer"
  307. },
  308. "marketname": {
  309. "description": "市场名称",
  310. "type": "string"
  311. },
  312. "tradedate": {
  313. "description": "交易日(yyyyMMdd)",
  314. "type": "string"
  315. },
  316. "userid": {
  317. "description": "申请人ID",
  318. "type": "integer"
  319. }
  320. }
  321. },
  322. "cptrade.Cptradepresaleapply": {
  323. "type": "object",
  324. "required": [
  325. "applyid"
  326. ],
  327. "properties": {
  328. "accountid": {
  329. "description": "申请人账户ID",
  330. "type": "integer"
  331. },
  332. "applyid": {
  333. "description": "申请ID(181+Unix秒时间戳(10位)+xxxxxx)",
  334. "type": "integer"
  335. },
  336. "applystatus": {
  337. "description": "申请状态 - 1:已提交 2:初审通过 3:初审拒绝 4:初审失败 5复审通过 6:复审拒绝 7:复审失败 8:已撤销",
  338. "type": "integer"
  339. },
  340. "applytime": {
  341. "description": "申请时间",
  342. "type": "string"
  343. },
  344. "attachmenturl": {
  345. "description": "附件地址",
  346. "type": "string"
  347. },
  348. "endtime": {
  349. "description": "预售结束时间",
  350. "type": "string"
  351. },
  352. "goodscode": {
  353. "description": "商品代码",
  354. "type": "string"
  355. },
  356. "goodsname": {
  357. "description": "商品名称",
  358. "type": "string"
  359. },
  360. "goodunit": {
  361. "description": "报价单位",
  362. "type": "string"
  363. },
  364. "handlestatus": {
  365. "description": "处理状态",
  366. "type": "integer"
  367. },
  368. "marketid": {
  369. "description": "预售市场ID",
  370. "type": "integer"
  371. },
  372. "marketname": {
  373. "description": "预售市场名称",
  374. "type": "string"
  375. },
  376. "presaleqty": {
  377. "description": "预售数量",
  378. "type": "integer"
  379. },
  380. "relatedgoodscode": {
  381. "description": "关联交易合约代码",
  382. "type": "string"
  383. },
  384. "relatedgoodsid": {
  385. "description": "关联交易合约ID",
  386. "type": "integer"
  387. },
  388. "relatedgoodsname": {
  389. "description": "关联交易合约名称",
  390. "type": "string"
  391. },
  392. "starttime": {
  393. "description": "预售开始时间",
  394. "type": "string"
  395. },
  396. "tradedate": {
  397. "description": "交易日(yyyyMMdd)",
  398. "type": "string"
  399. },
  400. "trademode": {
  401. "description": "交易模式 - 16:挂牌点选 21:大宗竞拍",
  402. "type": "integer"
  403. },
  404. "userid": {
  405. "description": "申请人ID",
  406. "type": "integer"
  407. }
  408. }
  409. },
  410. "cptrade.Cptradepresalegoodsex": {
  411. "type": "object",
  412. "required": [
  413. "goodsid"
  414. ],
  415. "properties": {
  416. "attachmenturl": {
  417. "description": "附件地址",
  418. "type": "string"
  419. },
  420. "createtime": {
  421. "description": "创建时间",
  422. "type": "string"
  423. },
  424. "endtime": {
  425. "description": "预售结束时间",
  426. "type": "string"
  427. },
  428. "floorprice": {
  429. "description": "底价[大宗式竞拍]",
  430. "type": "number"
  431. },
  432. "goodsid": {
  433. "description": "商品ID(预售)",
  434. "type": "integer"
  435. },
  436. "marketid": {
  437. "description": "预售市场ID - 根据预售模式选择市场",
  438. "type": "integer"
  439. },
  440. "presaledamount": {
  441. "description": "已预售总金额(预售结束时更新)",
  442. "type": "number"
  443. },
  444. "presaledqty": {
  445. "description": "已预售量(预售结束时更新)",
  446. "type": "integer"
  447. },
  448. "presalemode": {
  449. "description": "预售模式 - 1:一口价 2:大宗式竞拍",
  450. "type": "integer"
  451. },
  452. "presaleqty": {
  453. "description": "预售数量",
  454. "type": "integer"
  455. },
  456. "refprice": {
  457. "description": "参考价格[一口价]",
  458. "type": "number"
  459. },
  460. "relatedgoodsid": {
  461. "description": "关联交易合约ID",
  462. "type": "integer"
  463. },
  464. "relatedmarketid": {
  465. "description": "关联交易合约市场ID",
  466. "type": "integer"
  467. },
  468. "sellstatus": {
  469. "description": "卖方处理状态 - 1:卖方头寸未处理 2:卖方头寸已处理",
  470. "type": "integer"
  471. },
  472. "startprice": {
  473. "description": "起拍价[大宗式竞拍]",
  474. "type": "number"
  475. },
  476. "starttime": {
  477. "description": "预售开始时间",
  478. "type": "string"
  479. },
  480. "tradedate": {
  481. "description": "交易日(yyyyMMdd)",
  482. "type": "string"
  483. }
  484. }
  485. },
  486. "cptrade.Cptradeusergoodsdata": {
  487. "type": "object",
  488. "required": [
  489. "accountid",
  490. "goodsid"
  491. ],
  492. "properties": {
  493. "EnabledQty": {
  494. "description": "可用量",
  495. "type": "integer"
  496. },
  497. "GoodsCode": {
  498. "description": "订单商品代码",
  499. "type": "string"
  500. },
  501. "GoodsName": {
  502. "description": "订单商品名称",
  503. "type": "string"
  504. },
  505. "WRStandardCode": {
  506. "description": "仓单标准代码",
  507. "type": "string"
  508. },
  509. "WRStandardName": {
  510. "description": "仓单标准名称",
  511. "type": "string"
  512. },
  513. "accountid": {
  514. "description": "账户ID",
  515. "type": "integer"
  516. },
  517. "cancelqty": {
  518. "description": "注销量",
  519. "type": "integer"
  520. },
  521. "curpresaleqty": {
  522. "description": "当前预售量",
  523. "type": "integer"
  524. },
  525. "deliveryqty": {
  526. "description": "交割量",
  527. "type": "integer"
  528. },
  529. "freezeamount": {
  530. "description": "冻结金额",
  531. "type": "number"
  532. },
  533. "goodsid": {
  534. "description": "商品ID",
  535. "type": "integer"
  536. },
  537. "goodunit": {
  538. "description": "报价单位",
  539. "type": "string"
  540. },
  541. "hasspotfreeze": {
  542. "description": "是否有现货冻结 - 0:否 1:有",
  543. "type": "integer"
  544. },
  545. "inqty": {
  546. "description": "转入量(总数量)",
  547. "type": "integer"
  548. },
  549. "marketid": {
  550. "description": "市场ID",
  551. "type": "integer"
  552. },
  553. "presaledamount": {
  554. "description": "已预售总金额",
  555. "type": "integer"
  556. },
  557. "presaledqty": {
  558. "description": "已预售量",
  559. "type": "integer"
  560. },
  561. "userid": {
  562. "description": "用户ID",
  563. "type": "integer"
  564. },
  565. "wrstandardid": {
  566. "description": "仓单标准ID",
  567. "type": "integer"
  568. }
  569. }
  570. }
  571. },
  572. "securityDefinitions": {
  573. "ApiKeyAuth": {
  574. "type": "apiKey",
  575. "name": "Authorization",
  576. "in": "header"
  577. }
  578. }
  579. }