后台API。
Login(GET)
- endpoint: /client/login/{clientId}
- response success sample:
{ "code": 0, "msg": "Success", "data": { "id": 1, "name": "Alpha", "assetValue": 100.0 } }
- response fail sample:
{ "code": -101, "msg": "User not found", "data": null }
Client 查询 BWIC list(GET)
- endpoint: /bwic/list/{clientId}
- response sample:
{ "code": 0, "msg": "Success", "data": [ { "bwicId": 1, "cusip": "037833100", "position": 400, "price": 30.0, "dueDate": "2023-02-20", "marketValue": 10000, "overDue": true, "totalBids": 10, "bidRank": "3/5", "bidMarketValue": 10500, "winner": "Alpha" }, { "bwicId": 2, "cusip": "02079K107", "position": 80, "price": 10.0, "dueDate": "2023-08-20", "marketValue": 500, "overDue": false, "totalBids": 8, "bidRank": "5/10", "bidMarketValue": 450, "winner": null } ] }
Client my BWIC list(GET)
- endpoint: /bwic/mylist/{clientId}
- response same as [/list]
Client bid/update(POST)
- endpoint: /bwic/bid
- request:
{ "bwicId": 1, "clientId": 1, "bidMarketValue": 1000 }
- response success sample: same as [/list]
- response fail sample:
{ "code": -102, "msg": "User's asset is not enough", "data": null }
Client cancel(POST)
- endpoint: /bwic/cancel
- request:
{ "bwicId": 1, "clientId": 1 }
- response success sample: same as [/list]
- response fail sample:
{ "code": -201, "msg": "BWIC is overdue", "data": null }