feat(market): add ICO scheduling and lifecycle RPCs
This commit is contained in:
@@ -72,6 +72,8 @@ message MarketOrder {
|
|||||||
repeated string comment = 21;
|
repeated string comment = 21;
|
||||||
optional MarketOrder source = 22; // purchase is done via this field
|
optional MarketOrder source = 22; // purchase is done via this field
|
||||||
bool is_ico = 23;
|
bool is_ico = 23;
|
||||||
|
optional string starts_at = 24; // RFC3339; absent means immediately available
|
||||||
|
optional string ends_at = 25; // RFC3339; absent means no scheduled end
|
||||||
// repeated string attachments = 14; // possible files included by
|
// repeated string attachments = 14; // possible files included by
|
||||||
// seller/buyer
|
// seller/buyer
|
||||||
}
|
}
|
||||||
@@ -113,6 +115,15 @@ message MarketOrderList {
|
|||||||
uint32 total_count = 4;
|
uint32 total_count = 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// AdminCancelOrderReq is used by trusted administrative tooling to cancel an
|
||||||
|
// order through the wallet service. The wallet service authenticates the
|
||||||
|
// caller with the administrative gRPC token; actor_user_id is retained for
|
||||||
|
// audit attribution.
|
||||||
|
message AdminCancelOrderReq {
|
||||||
|
uint64 order_id = 1;
|
||||||
|
int64 actor_user_id = 2;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* participant_type: IS Maker/Taker
|
* participant_type: IS Maker/Taker
|
||||||
* side: IS Buying/Selling
|
* side: IS Buying/Selling
|
||||||
@@ -132,6 +143,8 @@ message NewMarketReq {
|
|||||||
// TODO: maker market order as optional
|
// TODO: maker market order as optional
|
||||||
optional uint64 maker_order_id = 9;
|
optional uint64 maker_order_id = 9;
|
||||||
bool is_ico = 10;
|
bool is_ico = 10;
|
||||||
|
optional string starts_at = 11; // RFC3339
|
||||||
|
optional string ends_at = 12; // RFC3339
|
||||||
}
|
}
|
||||||
|
|
||||||
enum MarketOrdersSortBy {
|
enum MarketOrdersSortBy {
|
||||||
|
|||||||
@@ -20,6 +20,8 @@ service MarketplaceSrv {
|
|||||||
rpc CalcICOBuy(wallet.v1.BuyAssetReq) returns (wallet.v1.CalcBuyAssetRes);
|
rpc CalcICOBuy(wallet.v1.BuyAssetReq) returns (wallet.v1.CalcBuyAssetRes);
|
||||||
|
|
||||||
rpc CancelOrder(auth.v1.IdReqWithIAMAndTFA) returns (base.v1.StatusRes); // cancel an order
|
rpc CancelOrder(auth.v1.IdReqWithIAMAndTFA) returns (base.v1.StatusRes); // cancel an order
|
||||||
|
rpc AdminCancelOrder(AdminCancelOrderReq) returns (base.v1.StatusRes); // cancel an order from trusted admin tooling
|
||||||
|
rpc DeleteOrder(auth.v1.IdReqWithIAMAndTFA) returns (base.v1.StatusRes); // delete a closed order
|
||||||
|
|
||||||
rpc NewMarketOrder(NewMarketReq) returns (MarketOrder); // insert new buy order to market
|
rpc NewMarketOrder(NewMarketReq) returns (MarketOrder); // insert new buy order to market
|
||||||
rpc GenerateMarketContract(MarketContractReq) returns (ContractMarketRes);
|
rpc GenerateMarketContract(MarketContractReq) returns (ContractMarketRes);
|
||||||
|
|||||||
Reference in New Issue
Block a user