swagger.yaml 39 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439
  1. basePath: /api
  2. definitions:
  3. app.Response:
  4. properties:
  5. code:
  6. type: integer
  7. data:
  8. type: object
  9. msg:
  10. type: string
  11. type: object
  12. cptrade.Cptradepositioncancel:
  13. properties:
  14. accountid:
  15. description: 申请人账户ID
  16. type: integer
  17. applystatus:
  18. description: 申请状态 - 1:已提交 2:初审通过 3:初审拒绝 4:初审失败 5复审通过 6:复审拒绝 7:复审失败 8:已撤销
  19. type: integer
  20. applytime:
  21. description: 申请时间
  22. type: string
  23. cancelid:
  24. description: 注销ID(SEQ_CPTRADE_POSITIONCANCEL)
  25. type: integer
  26. cancelqty:
  27. description: 注销数量
  28. type: integer
  29. createtime:
  30. description: 创建时间
  31. type: string
  32. creatorid:
  33. description: 创建人ID
  34. type: integer
  35. creatorname:
  36. description: 创建人
  37. type: string
  38. goodscode:
  39. description: 订单商品代码
  40. type: string
  41. goodsid:
  42. description: 商品ID
  43. type: integer
  44. goodsname:
  45. description: 订单商品名称
  46. type: string
  47. goodunit:
  48. description: 报价单位
  49. type: string
  50. handlestatus:
  51. description: 处理状态
  52. type: integer
  53. marketid:
  54. description: 市场ID
  55. type: integer
  56. marketname:
  57. description: 市场名称
  58. type: string
  59. tradedate:
  60. description: 交易日(yyyyMMdd)
  61. type: string
  62. userid:
  63. description: 申请人ID
  64. type: integer
  65. required:
  66. - cancelid
  67. type: object
  68. cptrade.Cptradepresaleapply:
  69. properties:
  70. accountid:
  71. description: 申请人账户ID
  72. type: integer
  73. applyid:
  74. description: 申请ID(181+Unix秒时间戳(10位)+xxxxxx)
  75. type: integer
  76. applyremark:
  77. description: 申请备注
  78. type: string
  79. applystatus:
  80. description: 申请状态 - 1:已提交 2:初审通过 3:初审拒绝 4:初审失败 5复审通过 6:复审拒绝 7:复审失败 8:已撤销
  81. type: integer
  82. applytime:
  83. description: 申请时间
  84. type: string
  85. attachmenturl:
  86. description: 附件地址
  87. type: string
  88. endtime:
  89. description: 预售结束时间
  90. type: string
  91. goodscode:
  92. description: 商品代码
  93. type: string
  94. goodsid:
  95. description: 商品ID
  96. type: integer
  97. goodsname:
  98. description: 商品名称
  99. type: string
  100. goodunit:
  101. description: 报价单位
  102. type: string
  103. handlestatus:
  104. description: 处理状态
  105. type: integer
  106. marketid:
  107. description: 预售市场ID
  108. type: integer
  109. marketname:
  110. description: 预售市场名称
  111. type: string
  112. presaleqty:
  113. description: 预售数量
  114. type: integer
  115. relatedgoodscode:
  116. description: 关联交易合约代码
  117. type: string
  118. relatedgoodsid:
  119. description: 关联交易合约ID
  120. type: integer
  121. relatedgoodsname:
  122. description: 关联交易合约名称
  123. type: string
  124. starttime:
  125. description: 预售开始时间
  126. type: string
  127. tradedate:
  128. description: 交易日(yyyyMMdd)
  129. type: string
  130. trademode:
  131. description: 交易模式 - 16:挂牌点选 21:大宗竞拍
  132. type: integer
  133. userid:
  134. description: 申请人ID
  135. type: integer
  136. required:
  137. - applyid
  138. type: object
  139. cptrade.Cptradeusergoodsdata:
  140. properties:
  141. EnabledQty:
  142. description: 可用量
  143. type: integer
  144. GoodsCode:
  145. description: 订单商品代码
  146. type: string
  147. GoodsName:
  148. description: 订单商品名称
  149. type: string
  150. WRStandardCode:
  151. description: 仓单标准代码
  152. type: string
  153. WRStandardName:
  154. description: 仓单标准名称
  155. type: string
  156. accountid:
  157. description: 账户ID
  158. type: integer
  159. cancelqty:
  160. description: 注销量
  161. type: integer
  162. curpresaleqty:
  163. description: 当前预售量
  164. type: integer
  165. deliveryqty:
  166. description: 交割量
  167. type: integer
  168. freezeamount:
  169. description: 冻结金额
  170. type: number
  171. goodsid:
  172. description: 商品ID
  173. type: integer
  174. goodunit:
  175. description: 报价单位
  176. type: string
  177. hasspotfreeze:
  178. description: 是否有现货冻结 - 0:否 1:有
  179. type: integer
  180. inqty:
  181. description: 转入量(总数量)
  182. type: integer
  183. marketid:
  184. description: 市场ID
  185. type: integer
  186. presaledamount:
  187. description: 已预售总金额
  188. type: integer
  189. presaledqty:
  190. description: 已预售量
  191. type: integer
  192. userid:
  193. description: 用户ID
  194. type: integer
  195. wrstandardid:
  196. description: 仓单标准ID
  197. type: integer
  198. required:
  199. - accountid
  200. - goodsid
  201. type: object
  202. cptrade.QueryCPTradeMyBidRsp:
  203. properties:
  204. accountid:
  205. description: 账户ID[报价币种]
  206. type: integer
  207. goodsid:
  208. description: 商品ID
  209. type: integer
  210. goodunit:
  211. description: 报价单位
  212. type: string
  213. marketid:
  214. description: 市场ID
  215. type: integer
  216. orderid:
  217. description: 委托单号(100+Unix秒时间戳(10位)+2位(MarketServiceID)+xxxx)
  218. type: integer
  219. orderprice:
  220. description: 委托价格
  221. type: number
  222. orderqty:
  223. description: 委托数量
  224. type: integer
  225. ordertime:
  226. description: 委托时间
  227. type: string
  228. ordertotalprice:
  229. description: 货款金额(委托总价格=委托价格*委托数量*合约单位)
  230. type: number
  231. ordertotalweight:
  232. description: 竞拍总重量(委托总重量=委托数量*合约单位)
  233. type: integer
  234. totaltotalprice:
  235. description: 成交货款金额(成交总价格=成交价格*成交数量*合约单位)
  236. type: number
  237. tradeprice:
  238. description: 成交价格
  239. type: number
  240. tradeqty:
  241. description: 成交数量
  242. type: integer
  243. required:
  244. - accountid
  245. - goodsid
  246. - marketid
  247. - orderid
  248. - orderqty
  249. - ordertime
  250. - tradeprice
  251. - tradeqty
  252. type: object
  253. cptrade.QueryCPTradeOrderDetailRsq:
  254. properties:
  255. accountid:
  256. description: 账户ID[报价币种]
  257. type: integer
  258. buildtype:
  259. description: 委托单据类型 - 1:建仓 2:平仓 3:先平后建
  260. type: integer
  261. buyorsell:
  262. description: 买卖 - 0:买 1:卖
  263. type: integer
  264. cancelorderid:
  265. description: 撤单单号(撤单时填写)
  266. type: integer
  267. cancelqty:
  268. description: 撤单数量
  269. type: integer
  270. clientordertime:
  271. description: 客户端委托时间
  272. type: string
  273. clientticket:
  274. description: 客户端流水号
  275. type: string
  276. clienttype:
  277. description: 客户端类型 - 0:保留为未填终端类型 1:PC管理端 2:PC交易端 3:手机客户端_安卓 4:网页客户端 5:微信客户端 6:手机客户端_苹果 7:网上开户客户端 8:无效终端编号 9:报价终端(中江)
  278. type: integer
  279. closeexchagechargevalue:
  280. description: 平仓交易所手续费设置值
  281. type: number
  282. closefeealgorithm:
  283. description: 平仓手续费收取方式 1:比率 2:固定
  284. type: integer
  285. closefreezecharge:
  286. description: 平仓冻结手续费(先建后平操作,需要记录)
  287. type: number
  288. closememberchargevalue:
  289. description: 平仓会员手续费设置值
  290. type: number
  291. closeqty:
  292. description: 平仓数量(先建后平操作 需要记录)
  293. type: integer
  294. closetradeqty:
  295. description: 平仓成交数量(先建后平操作,需要记录)
  296. type: integer
  297. closeunfreezecharge:
  298. description: 平仓解冻手续费(先建后平操作,需要记录)
  299. type: number
  300. delistingtype:
  301. description: 摘牌类型 - 1:价格最优 2:点选成交
  302. type: integer
  303. freezecharge:
  304. description: 冻结手续费
  305. type: number
  306. freezemargin:
  307. description: 冻结保证金(冻结交易金额)
  308. type: number
  309. gcaccountid:
  310. description: 账户ID[合约币种]
  311. type: integer
  312. goodsid:
  313. description: 商品ID
  314. type: integer
  315. isconfirmexercise:
  316. description: 是否确认行权- 0:否 1:是
  317. type: integer
  318. ispreexercise:
  319. description: 是否预申报- 0:否 1:是
  320. type: integer
  321. listingselecttype:
  322. description: 挂牌点选类型 - 1:挂牌 2:摘牌 3:先摘后挂
  323. type: integer
  324. marginalgorithm:
  325. description: 保证金收取方式 1:比率 2:固定
  326. type: integer
  327. marginvalue:
  328. description: 即市保证金设置值
  329. type: number
  330. marketid:
  331. description: 市场ID
  332. type: integer
  333. marketmaxsub:
  334. description: 市价最大偏移范围
  335. type: number
  336. memberuserid:
  337. description: 所属会员UserID
  338. type: integer
  339. openexchagechargevalue:
  340. description: 建仓交易所手续费设置值
  341. type: number
  342. openfeealgorithm:
  343. description: 建仓手续费收取方式 1:比率 2:固定
  344. type: integer
  345. openfreezecharge:
  346. description: 开仓冻结手续费(先建后平操作,需要记录)
  347. type: number
  348. openmemberchargevalue:
  349. description: 建仓会员手续费设置值
  350. type: number
  351. openqty:
  352. description: 开仓数量(先建后平操作,需要记录)
  353. type: integer
  354. opentradeqty:
  355. description: 开仓成交数量(先建后平操作,需要记录)
  356. type: integer
  357. openunfreezecharge:
  358. description: 开仓解冻手续费(先建后平操作,需要记录)
  359. type: number
  360. operatetype:
  361. description: 操作类型 - 1:正常下单 2:斩仓 3:转单 4:结算撤单 5:系统卖出(适用于先平后建的卖出) 6:行情源报价 7:(结算)到期强平 8:(结算)协议转让 9:系统对冲单 10:(结算)到期无效 11:交割协议转让 12:交割协议平仓 13:交割成交(所有权) 14:管理端强行平仓 15:管理端协议转让
  362. type: integer
  363. operatorid:
  364. description: 登录账号(LoginID)
  365. type: integer
  366. optiontype:
  367. description: 期权类型 - 1:认购(看涨) 2:认沽(看跌)
  368. type: integer
  369. orderprice:
  370. description: 委托价格
  371. type: number
  372. orderqty:
  373. description: 委托数量
  374. type: integer
  375. ordersrc:
  376. description: 委托来源 - 1:客户端 2:管理端 3:风控服务 4:交割服务 5:交易服务 6:交易日结 7:商品强平 8:管理端商品退市强平 9:交易接口 10:交割服务商被动(受托竞价) 11:预埋触发
  377. type: integer
  378. orderstatus:
  379. description: 委托状态 - 1: 委托请求 2:待冻结 3:委托成功 4: 委托失败 5:配对成功 6: 已撤销 7:部分成交 8:已成交 9:部成部撤 10:成交失败 11:已拒绝 12:经过摘牌(先摘后挂专用-先摘后挂已摘过) 13:冻结成功(通道交易专用) 14:通道已撤 15:通道部成部撤 16:成交失败违约(荷兰式竞拍专用)
  380. type: integer
  381. ordertime:
  382. description: 委托时间
  383. type: string
  384. preexerciseprice:
  385. description: 预申报价格
  386. type: number
  387. premium:
  388. description: 权利金
  389. type: number
  390. preorderid:
  391. description: 关联预埋单号(止盈止损单时填写)
  392. type: integer
  393. pricemode:
  394. description: '取价方式 - 1:市价 2: 限价'
  395. type: integer
  396. quoteid:
  397. description: 报价单ID
  398. type: integer
  399. relatedid:
  400. description: 关联单号(交割单)
  401. type: integer
  402. retcode:
  403. description: 错误代码
  404. type: integer
  405. sessionid:
  406. description: 会话ID
  407. type: integer
  408. strorderid:
  409. description: 委托单号
  410. type: string
  411. tradedate:
  412. description: 交易日(yyyyMMdd)
  413. type: string
  414. tradeproperty:
  415. description: 交易属性
  416. type: integer
  417. tradeqty:
  418. description: 成交数量
  419. type: integer
  420. unfreezecharge:
  421. description: 解冻手续费
  422. type: number
  423. unfreezemargin:
  424. description: 解冻保证金
  425. type: number
  426. updatetime:
  427. description: 更新时间
  428. type: string
  429. uuid:
  430. description: 发起端唯一id
  431. type: string
  432. validtime:
  433. description: 有效期限
  434. type: string
  435. validtype:
  436. description: 有效类型 - 1当日有效 2本周有效 3指定日期有效 4一直有效 5指定时间有效
  437. type: integer
  438. volumetype:
  439. description: 当时间有效类型为 “立即执行否则取消 IOC” 时,需要此项 - 0:任意量 1:最小量(暂时不支持) 2:全部量
  440. type: integer
  441. required:
  442. - accountid
  443. - buildtype
  444. - buyorsell
  445. - goodsid
  446. - marketid
  447. - memberuserid
  448. - operatetype
  449. - orderqty
  450. - ordertime
  451. - pricemode
  452. - strorderid
  453. - tradedate
  454. - validtype
  455. type: object
  456. cptrade.QueryMyCPTradeGoodsRsp:
  457. properties:
  458. accountid:
  459. description: 卖方账户ID
  460. type: integer
  461. agreeunit:
  462. description: 合约单位
  463. type: number
  464. applyid:
  465. description: 关联申请ID
  466. type: integer
  467. attachmenturl:
  468. description: 附件地址
  469. type: string
  470. createtime:
  471. description: 创建时间
  472. type: string
  473. currencyid:
  474. description: 报价货币ID
  475. type: integer
  476. decimalplace:
  477. description: 报价小数位
  478. type: integer
  479. endtime:
  480. description: 预售结束时间
  481. type: string
  482. floorprice:
  483. description: 底价[大宗式竞拍]
  484. type: number
  485. goodscode:
  486. description: 商品代码(预售)
  487. type: string
  488. goodsdetail:
  489. description: 详情[大宗]
  490. type: string
  491. goodsid:
  492. description: 商品ID(自增ID SEQ_GOODS)
  493. type: integer
  494. goodsname:
  495. description: 商品名称(预售)
  496. type: string
  497. goodunit:
  498. description: 报价单位
  499. type: string
  500. goodunitid:
  501. description: 报价单位ID
  502. type: integer
  503. marketid:
  504. description: 所属市场ID
  505. type: integer
  506. marketname:
  507. description: 预售市场名称
  508. type: string
  509. presaledamount:
  510. description: 已预售总金额(预售结束时更新)
  511. type: number
  512. presaledqty:
  513. description: 已预售量(预售结束时更新)
  514. type: integer
  515. presalemode:
  516. description: 预售模式 - 1:一口价 2:大宗式竞拍
  517. type: integer
  518. presaleqty:
  519. description: 预售数量
  520. type: integer
  521. refprice:
  522. description: 参考价格[一口价]
  523. type: number
  524. relatedgoodscode:
  525. description: 商品代码(订单)
  526. type: string
  527. relatedgoodsid:
  528. description: 关联交易合约ID
  529. type: integer
  530. relatedgoodsname:
  531. description: 商品名称(订单)
  532. type: string
  533. relatedmarketid:
  534. description: 关联交易合约市场ID
  535. type: integer
  536. sellstatus:
  537. description: 卖方处理状态 - 1:卖方头寸未处理 2:卖方头寸已处理
  538. type: integer
  539. startprice:
  540. description: 起拍价[大宗式竞拍]
  541. type: number
  542. starttime:
  543. description: 预售开始时间
  544. type: string
  545. tradedate:
  546. description: 交易日(yyyyMMdd)
  547. type: string
  548. tradeprice:
  549. description: 成交价[大宗]
  550. type: number
  551. userid:
  552. description: 卖方用户ID
  553. type: integer
  554. required:
  555. - goodscode
  556. - goodsid
  557. - goodsname
  558. - marketid
  559. - relatedgoodscode
  560. - relatedgoodsname
  561. type: object
  562. cptrade.QueryPresaleGoodsExRsp:
  563. properties:
  564. attachmenturl:
  565. description: 附件地址
  566. type: string
  567. createtime:
  568. description: 创建时间
  569. type: string
  570. endtime:
  571. description: 预售结束时间
  572. type: string
  573. floorprice:
  574. description: 底价[大宗式竞拍]
  575. type: number
  576. goodsdetail:
  577. description: 详情[大宗]
  578. type: string
  579. goodsid:
  580. description: 商品ID(预售)
  581. type: integer
  582. goodunit:
  583. description: 报价单位
  584. type: string
  585. marketid:
  586. description: 预售市场ID - 根据预售模式选择市场
  587. type: integer
  588. presaledamount:
  589. description: 已预售总金额(预售结束时更新)
  590. type: number
  591. presaledqty:
  592. description: 已预售量(预售结束时更新)
  593. type: integer
  594. presalemode:
  595. description: 预售模式 - 1:一口价 2:大宗式竞拍
  596. type: integer
  597. presaleqty:
  598. description: 预售数量
  599. type: integer
  600. refprice:
  601. description: 参考价格[一口价]
  602. type: number
  603. relatedgoodsid:
  604. description: 关联交易合约ID
  605. type: integer
  606. relatedmarketid:
  607. description: 关联交易合约市场ID
  608. type: integer
  609. sellstatus:
  610. description: 卖方处理状态 - 1:卖方头寸未处理 2:卖方头寸已处理
  611. type: integer
  612. startprice:
  613. description: 起拍价[大宗式竞拍]
  614. type: number
  615. starttime:
  616. description: 预售开始时间
  617. type: string
  618. tradedate:
  619. description: 交易日(yyyyMMdd)
  620. type: string
  621. tradeprice:
  622. description: 成交价[大宗]
  623. type: number
  624. required:
  625. - goodsid
  626. type: object
  627. delivery.QueryDeliveryRelationRsp:
  628. properties:
  629. begindate:
  630. description: 起始日期(yyyyMMdd)
  631. type: string
  632. buytemplateid:
  633. description: 买履约计划模板ID
  634. type: integer
  635. deliverygoodscode:
  636. description: 品种代码
  637. type: string
  638. deliverygoodsid:
  639. description: 交割商品
  640. type: integer
  641. deliverygoodsname:
  642. description: 品种名称
  643. type: string
  644. deliverymode:
  645. description: 交割方式 - 1:点选式 2:申报式
  646. type: integer
  647. deliverypricerule:
  648. description: 交割价规则- 1:行情价 2:建仓价
  649. type: integer
  650. deliverytype:
  651. description: 交割模式 - 1:X交割 2:X+P交割 3:X+C交割 4:X+P+C交割
  652. type: integer
  653. enddate:
  654. description: 结束日期(yyyyMMdd)
  655. type: string
  656. goodscode:
  657. description: 商品代码
  658. type: string
  659. goodsid:
  660. description: 交易合约ID
  661. type: integer
  662. goodsname:
  663. description: 商品名称
  664. type: string
  665. marketid:
  666. description: 市场ID
  667. type: integer
  668. mindeliveryqty:
  669. description: 最小交割系数(K)
  670. type: integer
  671. p2deliveryprice:
  672. description: P2合约价格(商品价时填写0,固定值时填写固定值)
  673. type: number
  674. p2deliveryratio:
  675. description: P2合约系数(p)
  676. type: integer
  677. p2goodsid:
  678. description: P2合约ID
  679. type: integer
  680. p2pricemode:
  681. description: P2合约价格方式 - 1:商品价 2:固定值
  682. type: integer
  683. pdeliveryprice:
  684. description: P合约价格(商品价时填写0,固定值时填写固定值)
  685. type: number
  686. pdeliveryratio:
  687. description: P合约系数(n)
  688. type: integer
  689. pgoodsid:
  690. description: P合约ID
  691. type: integer
  692. ppricemode:
  693. description: P合约价格方式 - 1:商品价 2:固定值
  694. type: integer
  695. rratio:
  696. description: 兑换系数(R)
  697. type: integer
  698. rratio1:
  699. description: 兑换系数(交易合约)(R1)
  700. type: integer
  701. rratio2:
  702. description: 兑换系数(仓单标准)(R2)
  703. type: integer
  704. selltemplateid:
  705. description: 卖履约计划模板ID
  706. type: integer
  707. wrstandardid:
  708. description: 仓单标准ID
  709. type: integer
  710. xdeliveryratio:
  711. description: 交易合约系数(m)
  712. type: integer
  713. required:
  714. - begindate
  715. - enddate
  716. - goodsid
  717. - mindeliveryqty
  718. - xdeliveryratio
  719. type: object
  720. erms2.QueryArbitrageStrategyRsp:
  721. properties:
  722. applybasis:
  723. description: 申请基差
  724. type: number
  725. asapplyid:
  726. description: 策略申请ID(702+Unix秒时间戳(10位)+xxxxxx)
  727. type: string
  728. asname:
  729. description: 策略名称
  730. type: string
  731. asno:
  732. description: 策略编号
  733. type: string
  734. basischangepl:
  735. description: 基差变动损益[结算更新]
  736. type: number
  737. biztype:
  738. description: 业务类型 - 1:正向套利 -1:反向套利
  739. type: integer
  740. closetradedate:
  741. description: 完结交易日(yyyyMMdd)
  742. type: string
  743. curbasis:
  744. description: 当前基差[结算更新]
  745. type: number
  746. deliverygoodsid:
  747. description: 现货品种ID
  748. type: integer
  749. futureavgprice:
  750. description: 期货建仓均价
  751. type: number
  752. futurecloseamount:
  753. description: 期货平仓金额
  754. type: number
  755. futurecloseqty:
  756. description: 期货平仓数量
  757. type: number
  758. futureopenamount:
  759. description: 期货开仓金额
  760. type: number
  761. futureopenqty:
  762. description: 期货开仓数量
  763. type: number
  764. futurepl:
  765. description: 期货总盈亏[结算更新]
  766. type: number
  767. futureqty:
  768. description: 期货持仓数量
  769. type: number
  770. futurequote:
  771. description: 期货额度
  772. type: number
  773. goodsgroupid:
  774. description: 期货品种ID
  775. type: integer
  776. marketid:
  777. description: 市场ID
  778. type: integer
  779. netexposure:
  780. description: 单笔业务头寸净敞口 = 期货持仓数量 + 已定价现货不含税数量
  781. type: number
  782. netexposurepl:
  783. description: 净敞口损益 = TotalPL - BasisChangePL[结算更新]
  784. type: number
  785. netexposurerate:
  786. description: 净敞口比例 - 0:未结束 = (NetExposure/PriceSpotQtyNoTax) ; 已结束为0
  787. type: number
  788. openbasis:
  789. description: 建仓基差
  790. type: number
  791. pricedspotqty:
  792. description: 已定价现货数量
  793. type: number
  794. pricedspotqtynotax:
  795. description: 已定价现货不含税数量
  796. type: number
  797. remark:
  798. description: 备注
  799. type: string
  800. spotavgprice:
  801. description: 现货均价
  802. type: number
  803. spotbuyamount:
  804. description: 现货采购金额
  805. type: number
  806. spotbuyqty:
  807. description: 现货采购数量
  808. type: number
  809. spotpl:
  810. description: 现货总盈亏[结算更新]
  811. type: number
  812. spotquota:
  813. description: 现货额度
  814. type: number
  815. spotsellamount:
  816. description: 现货销售金额
  817. type: number
  818. spotsellqty:
  819. description: 现货销售数量
  820. type: number
  821. spotusedquota:
  822. description: 现货占用资金
  823. type: number
  824. strategystatus:
  825. description: 策略状态 - 0:未结束 1:已结束
  826. type: integer
  827. totalpl:
  828. description: 业务合计损益 = FuturePL + SpotPL [结算更新]
  829. type: number
  830. tradedate:
  831. description: 交易日(yyyyMMdd)
  832. type: string
  833. updatetime:
  834. description: 更新时间
  835. type: string
  836. usedquota:
  837. description: 已占用资金
  838. type: number
  839. userid:
  840. description: 所属机构
  841. type: integer
  842. required:
  843. - asapplyid
  844. type: object
  845. erms2.QueryInnerTradeDetailRsp:
  846. properties:
  847. accountid:
  848. description: 账号ID
  849. type: integer
  850. agreeunit:
  851. description: 合约单位
  852. type: number
  853. asapplyid:
  854. description: 策略申请ID
  855. type: integer
  856. asname:
  857. description: 策略名称
  858. type: string
  859. asno:
  860. description: 策略编号
  861. type: string
  862. buyorsell:
  863. description: 方向 - 0:买 1:卖
  864. type: integer
  865. channelbuildtype:
  866. description: 委托单据类型 0:无 1:建仓 2:平仓
  867. type: integer
  868. closetype:
  869. description: 平仓方式 - 0:无 1:平今 2:平昨
  870. type: integer
  871. decimalplace:
  872. description: 报价小数位
  873. type: integer
  874. detailtype:
  875. description: 明细类型 - 1:套利对冲 2:期货换月 3:期货仓位调整
  876. type: integer
  877. exexchangecode:
  878. description: 外部交易所代码
  879. type: string
  880. exexchangename:
  881. description: 外部交易所名称
  882. type: string
  883. goodscode:
  884. description: 商品代码(合约)
  885. type: string
  886. goodsgroupid:
  887. description: 商品组ID(品种ID)
  888. type: integer
  889. goodsgroupname:
  890. description: 商品组名称(品种)
  891. type: string
  892. goodsid:
  893. description: 商品ID
  894. type: integer
  895. goodsname:
  896. description: 商品名称(合约)
  897. type: string
  898. goodunit:
  899. description: 报价单位
  900. type: string
  901. marketid:
  902. description: 市场ID
  903. type: integer
  904. orderid:
  905. description: 委托单号
  906. type: string
  907. outgoodscode:
  908. description: 商品代码(外部)
  909. type: string
  910. relatedouttradeid:
  911. description: 关联外部成交单ID
  912. type: string
  913. remark:
  914. description: 备注
  915. type: string
  916. spotcontractid:
  917. description: 现货合同ID [1:套利对冲 为合同ID,2:期货换月\3:期货仓位调整时为0]
  918. type: integer
  919. spotcontractno:
  920. description: 现货合同编号
  921. type: string
  922. tradeid:
  923. description: 成交单号(108+Unix秒时间戳(10位)+2位(MarketServiceID)+xxxx)
  924. type: string
  925. tradeprice:
  926. description: 成交价格
  927. type: number
  928. tradeqty:
  929. description: 成交数量
  930. type: integer
  931. tradetime:
  932. description: 成交时间
  933. type: string
  934. updatetime:
  935. description: 更新时间
  936. type: string
  937. required:
  938. - asapplyid
  939. - buyorsell
  940. - goodscode
  941. - goodsgroupid
  942. - goodsgroupname
  943. - goodsname
  944. - tradeid
  945. type: object
  946. erms2.QuerySpotContractRsp:
  947. properties:
  948. accountid:
  949. description: 资金账户ID
  950. type: integer
  951. areauserid:
  952. description: 所属机构
  953. type: integer
  954. closedate:
  955. description: 终止日期
  956. type: string
  957. closeremark:
  958. description: 结束备注
  959. type: string
  960. closetradedate:
  961. description: 完结交易日(yyyyMMdd)
  962. type: string
  963. closetype:
  964. description: 终止类型 - 1:违约 2:提前终止
  965. type: integer
  966. contractamount:
  967. description: 合同金额
  968. type: number
  969. contractattachment:
  970. description: 合同附件
  971. type: string
  972. contractno:
  973. description: 现货合同编号
  974. type: string
  975. contractqty:
  976. description: 合同数量(数值) (用于计算)
  977. type: number
  978. contractqtychar:
  979. description: 合同数量\已订价数量 (用于显示)
  980. type: string
  981. contractstatus:
  982. description: 合同状态 - 0:未结束 1:已结束
  983. type: integer
  984. contracttype:
  985. description: 现货合同类型 - 1:采购合同 -1:销售合同
  986. type: integer
  987. customeraccountid:
  988. description: 客户资金账户ID
  989. type: integer
  990. customeruserid:
  991. description: 客户ID
  992. type: integer
  993. deliverygoodsdesc:
  994. description: 品种说明
  995. type: string
  996. deliverygoodsid:
  997. description: 现货品种ID
  998. type: integer
  999. handlestatus:
  1000. description: 处理状态
  1001. type: integer
  1002. invoiceatt:
  1003. description: 发票附件
  1004. type: string
  1005. invoicedatetime:
  1006. description: 开收票更新时间
  1007. type: string
  1008. invoiceopentime:
  1009. description: 开票时间
  1010. type: string
  1011. invoiceremark:
  1012. description: 发票备注
  1013. type: string
  1014. invoicestatus:
  1015. description: 开收票状态 - 0:未开票 1:已开票
  1016. type: integer
  1017. lastdate:
  1018. description: 交货时间
  1019. type: string
  1020. marketid:
  1021. description: 市场ID
  1022. type: integer
  1023. paydatetime:
  1024. description: 收付款更新时间
  1025. type: string
  1026. payremark:
  1027. description: 收付款备注
  1028. type: string
  1029. paystatus:
  1030. description: 收付款状态 - 0:未支付 1:已收款 2:已付款
  1031. type: integer
  1032. positionqty:
  1033. description: 头寸数量 - 合同数量去小数部分
  1034. type: integer
  1035. producttype:
  1036. description: 产品类型 - 1:标准仓单 2:等标 3:非标
  1037. type: integer
  1038. relatedqty:
  1039. description: 已关联数量
  1040. type: number
  1041. relatedstatus:
  1042. description: 关联完结状态 - 0:未结束 1:已结束
  1043. type: integer
  1044. remark:
  1045. description: 备注
  1046. type: string
  1047. signdate:
  1048. description: 签订日期
  1049. type: string
  1050. spotcontractid:
  1051. description: 现货合同ID(701+Unix秒时间戳(10位)+xxxxxx)
  1052. type: string
  1053. spotdatetime:
  1054. description: 收发货更新时间
  1055. type: string
  1056. spotprice:
  1057. description: 价格
  1058. type: number
  1059. spotremark:
  1060. description: 收发货备注
  1061. type: string
  1062. spotstatus:
  1063. description: 收发货状态 - 0:未交收 1:已发货 2:已发货
  1064. type: integer
  1065. tradedate:
  1066. description: 交易日(yyyyMMdd)
  1067. type: string
  1068. userid:
  1069. description: 业务员用户ID
  1070. type: integer
  1071. warehouseid:
  1072. description: 仓库ID
  1073. type: integer
  1074. wrfactortypeid:
  1075. description: 仓单要素类型ID
  1076. type: integer
  1077. wrstandardid:
  1078. description: 仓单标准ID(SEQ_WRSTANDARD)
  1079. type: integer
  1080. required:
  1081. - spotcontractid
  1082. type: object
  1083. info:
  1084. contact: {}
  1085. description: 新的查询服务,替代原通用查询服务。
  1086. license: {}
  1087. termsOfService: http://muchinfo.cn
  1088. title: MTP2.0 查询服务 API
  1089. version: "1.0"
  1090. paths:
  1091. /CPTrade/QueryCPTradeMyBidInfos:
  1092. get:
  1093. parameters:
  1094. - description: 资金账户
  1095. in: query
  1096. name: accountid
  1097. required: true
  1098. type: integer
  1099. - description: 预售市场ID
  1100. in: query
  1101. name: marketid
  1102. type: integer
  1103. - description: 预售商品ID
  1104. in: query
  1105. name: goodsid
  1106. type: integer
  1107. produces:
  1108. - application/json
  1109. responses:
  1110. "200":
  1111. description: OK
  1112. schema:
  1113. $ref: '#/definitions/cptrade.QueryCPTradeMyBidRsp'
  1114. "500":
  1115. description: Internal Server Error
  1116. schema:
  1117. $ref: '#/definitions/app.Response'
  1118. security:
  1119. - ApiKeyAuth: []
  1120. summary: 查询产能预售我的出价信息
  1121. tags:
  1122. - 产能预售
  1123. /CPTrade/QueryCPTradeOrderDetail:
  1124. get:
  1125. parameters:
  1126. - description: 预售商品ID
  1127. in: query
  1128. name: goodsid
  1129. type: integer
  1130. - description: 预售市场ID
  1131. in: query
  1132. name: marketid
  1133. type: integer
  1134. - description: 预售商品ID列表 - 格式:1,2,3
  1135. in: query
  1136. name: goodsids
  1137. type: string
  1138. produces:
  1139. - application/json
  1140. responses:
  1141. "200":
  1142. description: OK
  1143. schema:
  1144. $ref: '#/definitions/cptrade.QueryCPTradeOrderDetailRsq'
  1145. "500":
  1146. description: Internal Server Error
  1147. schema:
  1148. $ref: '#/definitions/app.Response'
  1149. security:
  1150. - ApiKeyAuth: []
  1151. summary: 查询产能预售委托单信息
  1152. tags:
  1153. - 产能预售
  1154. /CPTrade/QueryMyCPTradeGoods:
  1155. get:
  1156. parameters:
  1157. - description: 资金账户
  1158. in: query
  1159. name: accountid
  1160. required: true
  1161. type: integer
  1162. produces:
  1163. - application/json
  1164. responses:
  1165. "200":
  1166. description: OK
  1167. schema:
  1168. $ref: '#/definitions/cptrade.QueryMyCPTradeGoodsRsp'
  1169. "500":
  1170. description: Internal Server Error
  1171. schema:
  1172. $ref: '#/definitions/app.Response'
  1173. security:
  1174. - ApiKeyAuth: []
  1175. summary: 查询我的预售信息
  1176. tags:
  1177. - 产能预售
  1178. /CPTrade/QueryPositionCancel:
  1179. get:
  1180. parameters:
  1181. - description: 账户ID
  1182. in: query
  1183. name: userid
  1184. required: true
  1185. type: integer
  1186. - description: 注销ID
  1187. in: query
  1188. name: cancelid
  1189. type: integer
  1190. - description: 资金账户ID
  1191. in: query
  1192. name: accountid
  1193. type: integer
  1194. produces:
  1195. - application/json
  1196. responses:
  1197. "200":
  1198. description: OK
  1199. schema:
  1200. $ref: '#/definitions/cptrade.Cptradepositioncancel'
  1201. "500":
  1202. description: Internal Server Error
  1203. schema:
  1204. $ref: '#/definitions/app.Response'
  1205. security:
  1206. - ApiKeyAuth: []
  1207. summary: 查询远期订单注销申请信息
  1208. tags:
  1209. - 产能预售
  1210. /CPTrade/QueryPreasleApply:
  1211. get:
  1212. parameters:
  1213. - description: 账户ID
  1214. in: query
  1215. name: userid
  1216. required: true
  1217. type: integer
  1218. - description: 申请ID
  1219. in: query
  1220. name: applyid
  1221. type: integer
  1222. - description: 资金账户ID
  1223. in: query
  1224. name: accountid
  1225. type: integer
  1226. produces:
  1227. - application/json
  1228. responses:
  1229. "200":
  1230. description: OK
  1231. schema:
  1232. $ref: '#/definitions/cptrade.Cptradepresaleapply'
  1233. "500":
  1234. description: Internal Server Error
  1235. schema:
  1236. $ref: '#/definitions/app.Response'
  1237. security:
  1238. - ApiKeyAuth: []
  1239. summary: 查询产能预售申请信息
  1240. tags:
  1241. - 产能预售
  1242. /CPTrade/QueryPresaleGoodsEx:
  1243. get:
  1244. parameters:
  1245. - description: 预售商品ID
  1246. in: query
  1247. name: goodsid
  1248. type: integer
  1249. - description: 预售市场ID
  1250. in: query
  1251. name: marketid
  1252. type: integer
  1253. - description: 预售模式 - 1:一口价 2:大宗式竞拍
  1254. in: query
  1255. name: presalemode
  1256. type: integer
  1257. - description: 预售商品ID列表 - 格式:1,2,3
  1258. in: query
  1259. name: goodsids
  1260. type: string
  1261. - description: 预售商品代码
  1262. in: query
  1263. name: goodscode
  1264. type: string
  1265. produces:
  1266. - application/json
  1267. responses:
  1268. "200":
  1269. description: OK
  1270. schema:
  1271. $ref: '#/definitions/cptrade.QueryPresaleGoodsExRsp'
  1272. "500":
  1273. description: Internal Server Error
  1274. schema:
  1275. $ref: '#/definitions/app.Response'
  1276. security:
  1277. - ApiKeyAuth: []
  1278. summary: 查询产能预售商品扩展信息
  1279. tags:
  1280. - 产能预售
  1281. /CPTrade/QueryUserGoodsData:
  1282. get:
  1283. parameters:
  1284. - description: 资金账户ID
  1285. in: query
  1286. name: accountid
  1287. required: true
  1288. type: integer
  1289. produces:
  1290. - application/json
  1291. responses:
  1292. "200":
  1293. description: OK
  1294. schema:
  1295. $ref: '#/definitions/cptrade.Cptradeusergoodsdata'
  1296. "500":
  1297. description: Internal Server Error
  1298. schema:
  1299. $ref: '#/definitions/app.Response'
  1300. security:
  1301. - ApiKeyAuth: []
  1302. summary: 查询远期订单信息
  1303. tags:
  1304. - 产能预售
  1305. /Delivery/QueryDeliveryRelation:
  1306. get:
  1307. parameters:
  1308. - description: 商品ID
  1309. in: query
  1310. name: goodsid
  1311. type: integer
  1312. - description: 品种ID
  1313. in: query
  1314. name: deliverygoodsid
  1315. type: integer
  1316. - description: 市场ID
  1317. in: query
  1318. name: marketid
  1319. type: integer
  1320. produces:
  1321. - application/json
  1322. responses:
  1323. "200":
  1324. description: OK
  1325. schema:
  1326. $ref: '#/definitions/delivery.QueryDeliveryRelationRsp'
  1327. "500":
  1328. description: Internal Server Error
  1329. schema:
  1330. $ref: '#/definitions/app.Response'
  1331. security:
  1332. - ApiKeyAuth: []
  1333. summary: 查询商品交割关系表
  1334. tags:
  1335. - 交割服务
  1336. /Erms2/QueryArbitrageStrategy:
  1337. get:
  1338. parameters:
  1339. - description: 账户ID
  1340. in: query
  1341. name: userid
  1342. required: true
  1343. type: integer
  1344. - description: 商品组ID(品种ID)
  1345. in: query
  1346. name: goodsgroupid
  1347. type: string
  1348. produces:
  1349. - application/json
  1350. responses:
  1351. "200":
  1352. description: OK
  1353. schema:
  1354. $ref: '#/definitions/erms2.QueryArbitrageStrategyRsp'
  1355. "500":
  1356. description: Internal Server Error
  1357. schema:
  1358. $ref: '#/definitions/app.Response'
  1359. security:
  1360. - ApiKeyAuth: []
  1361. summary: 查询期现套利策略表信息(指定资金账户、未结束的)
  1362. tags:
  1363. - 风险管理
  1364. /Erms2/QueryInnerTradeDetail:
  1365. get:
  1366. parameters:
  1367. - description: 资金账户
  1368. in: query
  1369. name: accountid
  1370. required: true
  1371. type: integer
  1372. produces:
  1373. - application/json
  1374. responses:
  1375. "200":
  1376. description: OK
  1377. schema:
  1378. $ref: '#/definitions/erms2.QueryInnerTradeDetailRsp'
  1379. "500":
  1380. description: Internal Server Error
  1381. schema:
  1382. $ref: '#/definitions/app.Response'
  1383. security:
  1384. - ApiKeyAuth: []
  1385. summary: 查询内部成交单信息
  1386. tags:
  1387. - 风险管理
  1388. /Erms2/QuerySpotContract:
  1389. get:
  1390. parameters:
  1391. - description: 策略申请ID
  1392. in: query
  1393. name: asapplyid
  1394. required: true
  1395. type: integer
  1396. - description: 现货合同ID
  1397. in: query
  1398. name: spotcontractid
  1399. type: integer
  1400. produces:
  1401. - application/json
  1402. responses:
  1403. "200":
  1404. description: OK
  1405. schema:
  1406. $ref: '#/definitions/erms2.QuerySpotContractRsp'
  1407. "500":
  1408. description: Internal Server Error
  1409. schema:
  1410. $ref: '#/definitions/app.Response'
  1411. security:
  1412. - ApiKeyAuth: []
  1413. summary: 查询现货合同表信息(指定策略ID、未结束的)
  1414. tags:
  1415. - 风险管理
  1416. /WRTrade/GetAllDeliveryGoods:
  1417. get:
  1418. produces:
  1419. - application/json
  1420. responses:
  1421. "200":
  1422. description: OK
  1423. schema:
  1424. $ref: '#/definitions/app.Response'
  1425. "500":
  1426. description: Internal Server Error
  1427. schema:
  1428. $ref: '#/definitions/app.Response'
  1429. security:
  1430. - ApiKeyAuth: []
  1431. summary: 获取带仓单分类的种类信息
  1432. tags:
  1433. - 仓单贸易
  1434. securityDefinitions:
  1435. ApiKeyAuth:
  1436. in: header
  1437. name: Authorization
  1438. type: apiKey
  1439. swagger: "2.0"