Documentation ¶
Overview ¶
Package tdexv2 is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Package tdexv2 is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Variables
- func RegisterTradeServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterTradeServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client TradeServiceClient) error
- func RegisterTradeServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterTradeServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server TradeServiceServer) error
- func RegisterTradeServiceServer(s grpc.ServiceRegistrar, srv TradeServiceServer)
- func RegisterTransportServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterTransportServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client TransportServiceClient) error
- func RegisterTransportServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterTransportServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server TransportServiceServer) error
- func RegisterTransportServiceServer(s grpc.ServiceRegistrar, srv TransportServiceServer)
- type Balance
- type CompleteTradeRequest
- func (*CompleteTradeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CompleteTradeRequest) GetSwapComplete() *SwapComplete
- func (x *CompleteTradeRequest) GetSwapFail() *SwapFail
- func (*CompleteTradeRequest) ProtoMessage()
- func (x *CompleteTradeRequest) ProtoReflect() protoreflect.Message
- func (x *CompleteTradeRequest) Reset()
- func (x *CompleteTradeRequest) String() string
- type CompleteTradeResponse
- func (*CompleteTradeResponse) Descriptor() ([]byte, []int)deprecated
- func (x *CompleteTradeResponse) GetSwapFail() *SwapFail
- func (x *CompleteTradeResponse) GetTxid() string
- func (*CompleteTradeResponse) ProtoMessage()
- func (x *CompleteTradeResponse) ProtoReflect() protoreflect.Message
- func (x *CompleteTradeResponse) Reset()
- func (x *CompleteTradeResponse) String() string
- type ContentType
- func (ContentType) Descriptor() protoreflect.EnumDescriptor
- func (x ContentType) Enum() *ContentType
- func (ContentType) EnumDescriptor() ([]byte, []int)deprecated
- func (x ContentType) Number() protoreflect.EnumNumber
- func (x ContentType) String() string
- func (ContentType) Type() protoreflect.EnumType
- type Fee
- type GetMarketBalanceRequest
- func (*GetMarketBalanceRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetMarketBalanceRequest) GetMarket() *Market
- func (*GetMarketBalanceRequest) ProtoMessage()
- func (x *GetMarketBalanceRequest) ProtoReflect() protoreflect.Message
- func (x *GetMarketBalanceRequest) Reset()
- func (x *GetMarketBalanceRequest) String() string
- type GetMarketBalanceResponse
- func (*GetMarketBalanceResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetMarketBalanceResponse) GetBalance() *Balance
- func (x *GetMarketBalanceResponse) GetFee() *Fee
- func (*GetMarketBalanceResponse) ProtoMessage()
- func (x *GetMarketBalanceResponse) ProtoReflect() protoreflect.Message
- func (x *GetMarketBalanceResponse) Reset()
- func (x *GetMarketBalanceResponse) String() string
- type GetMarketPriceRequest
- func (*GetMarketPriceRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetMarketPriceRequest) GetMarket() *Market
- func (*GetMarketPriceRequest) ProtoMessage()
- func (x *GetMarketPriceRequest) ProtoReflect() protoreflect.Message
- func (x *GetMarketPriceRequest) Reset()
- func (x *GetMarketPriceRequest) String() string
- type GetMarketPriceResponse
- func (*GetMarketPriceResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetMarketPriceResponse) GetBalance() *Balance
- func (x *GetMarketPriceResponse) GetMinTradableAmount() uint64
- func (x *GetMarketPriceResponse) GetSpotPrice() float64
- func (*GetMarketPriceResponse) ProtoMessage()
- func (x *GetMarketPriceResponse) ProtoReflect() protoreflect.Message
- func (x *GetMarketPriceResponse) Reset()
- func (x *GetMarketPriceResponse) String() string
- type ListMarketsRequest
- type ListMarketsResponse
- func (*ListMarketsResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListMarketsResponse) GetMarkets() []*MarketWithFee
- func (*ListMarketsResponse) ProtoMessage()
- func (x *ListMarketsResponse) ProtoReflect() protoreflect.Message
- func (x *ListMarketsResponse) Reset()
- func (x *ListMarketsResponse) String() string
- type Market
- type MarketFee
- type MarketWithFee
- func (*MarketWithFee) Descriptor() ([]byte, []int)deprecated
- func (x *MarketWithFee) GetFee() *Fee
- func (x *MarketWithFee) GetMarket() *Market
- func (*MarketWithFee) ProtoMessage()
- func (x *MarketWithFee) ProtoReflect() protoreflect.Message
- func (x *MarketWithFee) Reset()
- func (x *MarketWithFee) String() string
- type Preview
- func (*Preview) Descriptor() ([]byte, []int)deprecated
- func (x *Preview) GetAmount() uint64
- func (x *Preview) GetAsset() string
- func (x *Preview) GetFee() *Fee
- func (x *Preview) GetFeeAmount() uint64
- func (x *Preview) GetFeeAsset() string
- func (x *Preview) GetPrice() *Price
- func (*Preview) ProtoMessage()
- func (x *Preview) ProtoReflect() protoreflect.Message
- func (x *Preview) Reset()
- func (x *Preview) String() string
- type PreviewTradeRequest
- func (*PreviewTradeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *PreviewTradeRequest) GetAmount() uint64
- func (x *PreviewTradeRequest) GetAsset() string
- func (x *PreviewTradeRequest) GetFeeAsset() string
- func (x *PreviewTradeRequest) GetMarket() *Market
- func (x *PreviewTradeRequest) GetType() TradeType
- func (*PreviewTradeRequest) ProtoMessage()
- func (x *PreviewTradeRequest) ProtoReflect() protoreflect.Message
- func (x *PreviewTradeRequest) Reset()
- func (x *PreviewTradeRequest) String() string
- type PreviewTradeResponse
- func (*PreviewTradeResponse) Descriptor() ([]byte, []int)deprecated
- func (x *PreviewTradeResponse) GetPreviews() []*Preview
- func (*PreviewTradeResponse) ProtoMessage()
- func (x *PreviewTradeResponse) ProtoReflect() protoreflect.Message
- func (x *PreviewTradeResponse) Reset()
- func (x *PreviewTradeResponse) String() string
- type Price
- type ProposeTradeRequest
- func (*ProposeTradeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ProposeTradeRequest) GetFeeAmount() uint64
- func (x *ProposeTradeRequest) GetFeeAsset() string
- func (x *ProposeTradeRequest) GetMarket() *Market
- func (x *ProposeTradeRequest) GetSwapRequest() *SwapRequest
- func (x *ProposeTradeRequest) GetType() TradeType
- func (*ProposeTradeRequest) ProtoMessage()
- func (x *ProposeTradeRequest) ProtoReflect() protoreflect.Message
- func (x *ProposeTradeRequest) Reset()
- func (x *ProposeTradeRequest) String() string
- type ProposeTradeResponse
- func (*ProposeTradeResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ProposeTradeResponse) GetExpiryTimeUnix() uint64
- func (x *ProposeTradeResponse) GetSwapAccept() *SwapAccept
- func (x *ProposeTradeResponse) GetSwapFail() *SwapFail
- func (*ProposeTradeResponse) ProtoMessage()
- func (x *ProposeTradeResponse) ProtoReflect() protoreflect.Message
- func (x *ProposeTradeResponse) Reset()
- func (x *ProposeTradeResponse) String() string
- type SupportedContentTypesRequest
- func (*SupportedContentTypesRequest) Descriptor() ([]byte, []int)deprecated
- func (*SupportedContentTypesRequest) ProtoMessage()
- func (x *SupportedContentTypesRequest) ProtoReflect() protoreflect.Message
- func (x *SupportedContentTypesRequest) Reset()
- func (x *SupportedContentTypesRequest) String() string
- type SupportedContentTypesResponse
- func (*SupportedContentTypesResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SupportedContentTypesResponse) GetAcceptedTypes() []ContentType
- func (*SupportedContentTypesResponse) ProtoMessage()
- func (x *SupportedContentTypesResponse) ProtoReflect() protoreflect.Message
- func (x *SupportedContentTypesResponse) Reset()
- func (x *SupportedContentTypesResponse) String() string
- type SwapAccept
- func (*SwapAccept) Descriptor() ([]byte, []int)deprecated
- func (x *SwapAccept) GetId() string
- func (x *SwapAccept) GetRequestId() string
- func (x *SwapAccept) GetTransaction() string
- func (x *SwapAccept) GetUnblindedInputs() []*UnblindedInput
- func (*SwapAccept) ProtoMessage()
- func (x *SwapAccept) ProtoReflect() protoreflect.Message
- func (x *SwapAccept) Reset()
- func (x *SwapAccept) String() string
- type SwapComplete
- func (*SwapComplete) Descriptor() ([]byte, []int)deprecated
- func (x *SwapComplete) GetAcceptId() string
- func (x *SwapComplete) GetId() string
- func (x *SwapComplete) GetTransaction() string
- func (*SwapComplete) ProtoMessage()
- func (x *SwapComplete) ProtoReflect() protoreflect.Message
- func (x *SwapComplete) Reset()
- func (x *SwapComplete) String() string
- type SwapFail
- func (*SwapFail) Descriptor() ([]byte, []int)deprecated
- func (x *SwapFail) GetFailureCode() uint32
- func (x *SwapFail) GetFailureMessage() string
- func (x *SwapFail) GetId() string
- func (x *SwapFail) GetMessageId() string
- func (*SwapFail) ProtoMessage()
- func (x *SwapFail) ProtoReflect() protoreflect.Message
- func (x *SwapFail) Reset()
- func (x *SwapFail) String() string
- type SwapRequest
- func (*SwapRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SwapRequest) GetAmountP() uint64
- func (x *SwapRequest) GetAmountR() uint64
- func (x *SwapRequest) GetAssetP() string
- func (x *SwapRequest) GetAssetR() string
- func (x *SwapRequest) GetId() string
- func (x *SwapRequest) GetTransaction() string
- func (x *SwapRequest) GetUnblindedInputs() []*UnblindedInput
- func (*SwapRequest) ProtoMessage()
- func (x *SwapRequest) ProtoReflect() protoreflect.Message
- func (x *SwapRequest) Reset()
- func (x *SwapRequest) String() string
- type TradeServiceClient
- type TradeServiceServer
- type TradeType
- type TransportServiceClient
- type TransportServiceServer
- type UnblindedInput
- func (*UnblindedInput) Descriptor() ([]byte, []int)deprecated
- func (x *UnblindedInput) GetAmount() uint64
- func (x *UnblindedInput) GetAmountBlinder() string
- func (x *UnblindedInput) GetAsset() string
- func (x *UnblindedInput) GetAssetBlinder() string
- func (x *UnblindedInput) GetIndex() uint32
- func (*UnblindedInput) ProtoMessage()
- func (x *UnblindedInput) ProtoReflect() protoreflect.Message
- func (x *UnblindedInput) Reset()
- func (x *UnblindedInput) String() string
- type UnimplementedTradeServiceServer
- func (UnimplementedTradeServiceServer) CompleteTrade(context.Context, *CompleteTradeRequest) (*CompleteTradeResponse, error)
- func (UnimplementedTradeServiceServer) GetMarketBalance(context.Context, *GetMarketBalanceRequest) (*GetMarketBalanceResponse, error)
- func (UnimplementedTradeServiceServer) GetMarketPrice(context.Context, *GetMarketPriceRequest) (*GetMarketPriceResponse, error)
- func (UnimplementedTradeServiceServer) ListMarkets(context.Context, *ListMarketsRequest) (*ListMarketsResponse, error)
- func (UnimplementedTradeServiceServer) PreviewTrade(context.Context, *PreviewTradeRequest) (*PreviewTradeResponse, error)
- func (UnimplementedTradeServiceServer) ProposeTrade(context.Context, *ProposeTradeRequest) (*ProposeTradeResponse, error)
- type UnimplementedTransportServiceServer
- type UnsafeTradeServiceServer
- type UnsafeTransportServiceServer
Constants ¶
This section is empty.
Variables ¶
var ( TradeType_name = map[int32]string{ 0: "TRADE_TYPE_BUY", 1: "TRADE_TYPE_SELL", } TradeType_value = map[string]int32{ "TRADE_TYPE_BUY": 0, "TRADE_TYPE_SELL": 1, } )
Enum value maps for TradeType.
var ( ContentType_name = map[int32]string{ 0: "CONTENT_TYPE_JSON", 1: "CONTENT_TYPE_GRPC", 2: "CONTENT_TYPE_GRPCWEB", 3: "CONTENT_TYPE_GRPCWEBTEXT", } ContentType_value = map[string]int32{ "CONTENT_TYPE_JSON": 0, "CONTENT_TYPE_GRPC": 1, "CONTENT_TYPE_GRPCWEB": 2, "CONTENT_TYPE_GRPCWEBTEXT": 3, } )
Enum value maps for ContentType.
var File_tdex_v2_swap_proto protoreflect.FileDescriptor
var File_tdex_v2_trade_proto protoreflect.FileDescriptor
var File_tdex_v2_transport_proto protoreflect.FileDescriptor
var File_tdex_v2_types_proto protoreflect.FileDescriptor
var TradeService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "tdex.v2.TradeService", HandlerType: (*TradeServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "ListMarkets", Handler: _TradeService_ListMarkets_Handler, }, { MethodName: "GetMarketBalance", Handler: _TradeService_GetMarketBalance_Handler, }, { MethodName: "GetMarketPrice", Handler: _TradeService_GetMarketPrice_Handler, }, { MethodName: "PreviewTrade", Handler: _TradeService_PreviewTrade_Handler, }, { MethodName: "ProposeTrade", Handler: _TradeService_ProposeTrade_Handler, }, { MethodName: "CompleteTrade", Handler: _TradeService_CompleteTrade_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "tdex/v2/trade.proto", }
TradeService_ServiceDesc is the grpc.ServiceDesc for TradeService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var TransportService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "tdex.v2.TransportService", HandlerType: (*TransportServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "SupportedContentTypes", Handler: _TransportService_SupportedContentTypes_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "tdex/v2/transport.proto", }
TransportService_ServiceDesc is the grpc.ServiceDesc for TransportService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterTradeServiceHandler ¶
func RegisterTradeServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterTradeServiceHandler registers the http handlers for service TradeService to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterTradeServiceHandlerClient ¶
func RegisterTradeServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client TradeServiceClient) error
RegisterTradeServiceHandlerClient registers the http handlers for service TradeService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "TradeServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "TradeServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "TradeServiceClient" to call the correct interceptors.
func RegisterTradeServiceHandlerFromEndpoint ¶
func RegisterTradeServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterTradeServiceHandlerFromEndpoint is same as RegisterTradeServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterTradeServiceHandlerServer ¶
func RegisterTradeServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server TradeServiceServer) error
RegisterTradeServiceHandlerServer registers the http handlers for service TradeService to "mux". UnaryRPC :call TradeServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterTradeServiceHandlerFromEndpoint instead.
func RegisterTradeServiceServer ¶
func RegisterTradeServiceServer(s grpc.ServiceRegistrar, srv TradeServiceServer)
func RegisterTransportServiceHandler ¶
func RegisterTransportServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterTransportServiceHandler registers the http handlers for service TransportService to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterTransportServiceHandlerClient ¶
func RegisterTransportServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client TransportServiceClient) error
RegisterTransportServiceHandlerClient registers the http handlers for service TransportService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "TransportServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "TransportServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "TransportServiceClient" to call the correct interceptors.
func RegisterTransportServiceHandlerFromEndpoint ¶
func RegisterTransportServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterTransportServiceHandlerFromEndpoint is same as RegisterTransportServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterTransportServiceHandlerServer ¶
func RegisterTransportServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server TransportServiceServer) error
RegisterTransportServiceHandlerServer registers the http handlers for service TransportService to "mux". UnaryRPC :call TransportServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterTransportServiceHandlerFromEndpoint instead.
func RegisterTransportServiceServer ¶
func RegisterTransportServiceServer(s grpc.ServiceRegistrar, srv TransportServiceServer)
Types ¶
type Balance ¶
type Balance struct { BaseAmount uint64 `protobuf:"varint,1,opt,name=base_amount,json=baseAmount,proto3" json:"base_amount,omitempty"` QuoteAmount uint64 `protobuf:"varint,2,opt,name=quote_amount,json=quoteAmount,proto3" json:"quote_amount,omitempty"` // contains filtered or unexported fields }
func (*Balance) Descriptor
deprecated
func (*Balance) GetBaseAmount ¶
func (*Balance) GetQuoteAmount ¶
func (*Balance) ProtoMessage ¶
func (*Balance) ProtoMessage()
func (*Balance) ProtoReflect ¶
func (x *Balance) ProtoReflect() protoreflect.Message
type CompleteTradeRequest ¶
type CompleteTradeRequest struct { SwapComplete *SwapComplete `protobuf:"bytes,1,opt,name=swap_complete,json=swapComplete,proto3" json:"swap_complete,omitempty"` SwapFail *SwapFail `protobuf:"bytes,2,opt,name=swap_fail,json=swapFail,proto3" json:"swap_fail,omitempty"` // contains filtered or unexported fields }
func (*CompleteTradeRequest) Descriptor
deprecated
func (*CompleteTradeRequest) Descriptor() ([]byte, []int)
Deprecated: Use CompleteTradeRequest.ProtoReflect.Descriptor instead.
func (*CompleteTradeRequest) GetSwapComplete ¶
func (x *CompleteTradeRequest) GetSwapComplete() *SwapComplete
func (*CompleteTradeRequest) GetSwapFail ¶
func (x *CompleteTradeRequest) GetSwapFail() *SwapFail
func (*CompleteTradeRequest) ProtoMessage ¶
func (*CompleteTradeRequest) ProtoMessage()
func (*CompleteTradeRequest) ProtoReflect ¶
func (x *CompleteTradeRequest) ProtoReflect() protoreflect.Message
func (*CompleteTradeRequest) Reset ¶
func (x *CompleteTradeRequest) Reset()
func (*CompleteTradeRequest) String ¶
func (x *CompleteTradeRequest) String() string
type CompleteTradeResponse ¶
type CompleteTradeResponse struct { Txid string `protobuf:"bytes,1,opt,name=txid,proto3" json:"txid,omitempty"` SwapFail *SwapFail `protobuf:"bytes,2,opt,name=swap_fail,json=swapFail,proto3" json:"swap_fail,omitempty"` // contains filtered or unexported fields }
func (*CompleteTradeResponse) Descriptor
deprecated
func (*CompleteTradeResponse) Descriptor() ([]byte, []int)
Deprecated: Use CompleteTradeResponse.ProtoReflect.Descriptor instead.
func (*CompleteTradeResponse) GetSwapFail ¶
func (x *CompleteTradeResponse) GetSwapFail() *SwapFail
func (*CompleteTradeResponse) GetTxid ¶
func (x *CompleteTradeResponse) GetTxid() string
func (*CompleteTradeResponse) ProtoMessage ¶
func (*CompleteTradeResponse) ProtoMessage()
func (*CompleteTradeResponse) ProtoReflect ¶
func (x *CompleteTradeResponse) ProtoReflect() protoreflect.Message
func (*CompleteTradeResponse) Reset ¶
func (x *CompleteTradeResponse) Reset()
func (*CompleteTradeResponse) String ¶
func (x *CompleteTradeResponse) String() string
type ContentType ¶
type ContentType int32
const ( ContentType_CONTENT_TYPE_JSON ContentType = 0 ContentType_CONTENT_TYPE_GRPC ContentType = 1 ContentType_CONTENT_TYPE_GRPCWEB ContentType = 2 ContentType_CONTENT_TYPE_GRPCWEBTEXT ContentType = 3 )
func (ContentType) Descriptor ¶
func (ContentType) Descriptor() protoreflect.EnumDescriptor
func (ContentType) Enum ¶
func (x ContentType) Enum() *ContentType
func (ContentType) EnumDescriptor
deprecated
func (ContentType) EnumDescriptor() ([]byte, []int)
Deprecated: Use ContentType.Descriptor instead.
func (ContentType) Number ¶
func (x ContentType) Number() protoreflect.EnumNumber
func (ContentType) String ¶
func (x ContentType) String() string
func (ContentType) Type ¶
func (ContentType) Type() protoreflect.EnumType
type Fee ¶
type Fee struct { // Percentage fee on both assets of the market in basis point. PercentageFee *MarketFee `protobuf:"bytes,1,opt,name=percentage_fee,json=percentageFee,proto3" json:"percentage_fee,omitempty"` // Fixed fee on both assets of the market in satoshi. FixedFee *MarketFee `protobuf:"bytes,2,opt,name=fixed_fee,json=fixedFee,proto3" json:"fixed_fee,omitempty"` // contains filtered or unexported fields }
func (*Fee) Descriptor
deprecated
func (*Fee) GetFixedFee ¶
func (*Fee) GetPercentageFee ¶
func (*Fee) ProtoMessage ¶
func (*Fee) ProtoMessage()
func (*Fee) ProtoReflect ¶
func (x *Fee) ProtoReflect() protoreflect.Message
type GetMarketBalanceRequest ¶
type GetMarketBalanceRequest struct { Market *Market `protobuf:"bytes,1,opt,name=market,proto3" json:"market,omitempty"` // contains filtered or unexported fields }
func (*GetMarketBalanceRequest) Descriptor
deprecated
func (*GetMarketBalanceRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetMarketBalanceRequest.ProtoReflect.Descriptor instead.
func (*GetMarketBalanceRequest) GetMarket ¶
func (x *GetMarketBalanceRequest) GetMarket() *Market
func (*GetMarketBalanceRequest) ProtoMessage ¶
func (*GetMarketBalanceRequest) ProtoMessage()
func (*GetMarketBalanceRequest) ProtoReflect ¶
func (x *GetMarketBalanceRequest) ProtoReflect() protoreflect.Message
func (*GetMarketBalanceRequest) Reset ¶
func (x *GetMarketBalanceRequest) Reset()
func (*GetMarketBalanceRequest) String ¶
func (x *GetMarketBalanceRequest) String() string
type GetMarketBalanceResponse ¶
type GetMarketBalanceResponse struct { Balance *Balance `protobuf:"bytes,1,opt,name=balance,proto3" json:"balance,omitempty"` Fee *Fee `protobuf:"bytes,2,opt,name=fee,proto3" json:"fee,omitempty"` // contains filtered or unexported fields }
func (*GetMarketBalanceResponse) Descriptor
deprecated
func (*GetMarketBalanceResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetMarketBalanceResponse.ProtoReflect.Descriptor instead.
func (*GetMarketBalanceResponse) GetBalance ¶
func (x *GetMarketBalanceResponse) GetBalance() *Balance
func (*GetMarketBalanceResponse) GetFee ¶
func (x *GetMarketBalanceResponse) GetFee() *Fee
func (*GetMarketBalanceResponse) ProtoMessage ¶
func (*GetMarketBalanceResponse) ProtoMessage()
func (*GetMarketBalanceResponse) ProtoReflect ¶
func (x *GetMarketBalanceResponse) ProtoReflect() protoreflect.Message
func (*GetMarketBalanceResponse) Reset ¶
func (x *GetMarketBalanceResponse) Reset()
func (*GetMarketBalanceResponse) String ¶
func (x *GetMarketBalanceResponse) String() string
type GetMarketPriceRequest ¶
type GetMarketPriceRequest struct { Market *Market `protobuf:"bytes,1,opt,name=market,proto3" json:"market,omitempty"` // contains filtered or unexported fields }
func (*GetMarketPriceRequest) Descriptor
deprecated
func (*GetMarketPriceRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetMarketPriceRequest.ProtoReflect.Descriptor instead.
func (*GetMarketPriceRequest) GetMarket ¶
func (x *GetMarketPriceRequest) GetMarket() *Market
func (*GetMarketPriceRequest) ProtoMessage ¶
func (*GetMarketPriceRequest) ProtoMessage()
func (*GetMarketPriceRequest) ProtoReflect ¶
func (x *GetMarketPriceRequest) ProtoReflect() protoreflect.Message
func (*GetMarketPriceRequest) Reset ¶
func (x *GetMarketPriceRequest) Reset()
func (*GetMarketPriceRequest) String ¶
func (x *GetMarketPriceRequest) String() string
type GetMarketPriceResponse ¶
type GetMarketPriceResponse struct { SpotPrice float64 `protobuf:"fixed64,1,opt,name=spot_price,json=spotPrice,proto3" json:"spot_price,omitempty"` MinTradableAmount uint64 `protobuf:"varint,2,opt,name=min_tradable_amount,json=minTradableAmount,proto3" json:"min_tradable_amount,omitempty"` Balance *Balance `protobuf:"bytes,3,opt,name=balance,proto3" json:"balance,omitempty"` // contains filtered or unexported fields }
func (*GetMarketPriceResponse) Descriptor
deprecated
func (*GetMarketPriceResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetMarketPriceResponse.ProtoReflect.Descriptor instead.
func (*GetMarketPriceResponse) GetBalance ¶
func (x *GetMarketPriceResponse) GetBalance() *Balance
func (*GetMarketPriceResponse) GetMinTradableAmount ¶
func (x *GetMarketPriceResponse) GetMinTradableAmount() uint64
func (*GetMarketPriceResponse) GetSpotPrice ¶
func (x *GetMarketPriceResponse) GetSpotPrice() float64
func (*GetMarketPriceResponse) ProtoMessage ¶
func (*GetMarketPriceResponse) ProtoMessage()
func (*GetMarketPriceResponse) ProtoReflect ¶
func (x *GetMarketPriceResponse) ProtoReflect() protoreflect.Message
func (*GetMarketPriceResponse) Reset ¶
func (x *GetMarketPriceResponse) Reset()
func (*GetMarketPriceResponse) String ¶
func (x *GetMarketPriceResponse) String() string
type ListMarketsRequest ¶
type ListMarketsRequest struct {
// contains filtered or unexported fields
}
BOTD#4 Service's messages
func (*ListMarketsRequest) Descriptor
deprecated
func (*ListMarketsRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListMarketsRequest.ProtoReflect.Descriptor instead.
func (*ListMarketsRequest) ProtoMessage ¶
func (*ListMarketsRequest) ProtoMessage()
func (*ListMarketsRequest) ProtoReflect ¶
func (x *ListMarketsRequest) ProtoReflect() protoreflect.Message
func (*ListMarketsRequest) Reset ¶
func (x *ListMarketsRequest) Reset()
func (*ListMarketsRequest) String ¶
func (x *ListMarketsRequest) String() string
type ListMarketsResponse ¶
type ListMarketsResponse struct { Markets []*MarketWithFee `protobuf:"bytes,1,rep,name=markets,proto3" json:"markets,omitempty"` // contains filtered or unexported fields }
func (*ListMarketsResponse) Descriptor
deprecated
func (*ListMarketsResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListMarketsResponse.ProtoReflect.Descriptor instead.
func (*ListMarketsResponse) GetMarkets ¶
func (x *ListMarketsResponse) GetMarkets() []*MarketWithFee
func (*ListMarketsResponse) ProtoMessage ¶
func (*ListMarketsResponse) ProtoMessage()
func (*ListMarketsResponse) ProtoReflect ¶
func (x *ListMarketsResponse) ProtoReflect() protoreflect.Message
func (*ListMarketsResponse) Reset ¶
func (x *ListMarketsResponse) Reset()
func (*ListMarketsResponse) String ¶
func (x *ListMarketsResponse) String() string
type Market ¶
type Market struct { BaseAsset string `protobuf:"bytes,1,opt,name=base_asset,json=baseAsset,proto3" json:"base_asset,omitempty"` QuoteAsset string `protobuf:"bytes,2,opt,name=quote_asset,json=quoteAsset,proto3" json:"quote_asset,omitempty"` // contains filtered or unexported fields }
func (*Market) Descriptor
deprecated
func (*Market) GetBaseAsset ¶
func (*Market) GetQuoteAsset ¶
func (*Market) ProtoMessage ¶
func (*Market) ProtoMessage()
func (*Market) ProtoReflect ¶
func (x *Market) ProtoReflect() protoreflect.Message
type MarketFee ¶
type MarketFee struct { BaseAsset int64 `protobuf:"varint,1,opt,name=base_asset,json=baseAsset,proto3" json:"base_asset,omitempty"` QuoteAsset int64 `protobuf:"varint,2,opt,name=quote_asset,json=quoteAsset,proto3" json:"quote_asset,omitempty"` // contains filtered or unexported fields }
func (*MarketFee) Descriptor
deprecated
func (*MarketFee) GetBaseAsset ¶
func (*MarketFee) GetQuoteAsset ¶
func (*MarketFee) ProtoMessage ¶
func (*MarketFee) ProtoMessage()
func (*MarketFee) ProtoReflect ¶
func (x *MarketFee) ProtoReflect() protoreflect.Message
type MarketWithFee ¶
type MarketWithFee struct { Market *Market `protobuf:"bytes,1,opt,name=market,proto3" json:"market,omitempty"` Fee *Fee `protobuf:"bytes,2,opt,name=fee,proto3" json:"fee,omitempty"` // contains filtered or unexported fields }
func (*MarketWithFee) Descriptor
deprecated
func (*MarketWithFee) Descriptor() ([]byte, []int)
Deprecated: Use MarketWithFee.ProtoReflect.Descriptor instead.
func (*MarketWithFee) GetFee ¶
func (x *MarketWithFee) GetFee() *Fee
func (*MarketWithFee) GetMarket ¶
func (x *MarketWithFee) GetMarket() *Market
func (*MarketWithFee) ProtoMessage ¶
func (*MarketWithFee) ProtoMessage()
func (*MarketWithFee) ProtoReflect ¶
func (x *MarketWithFee) ProtoReflect() protoreflect.Message
func (*MarketWithFee) Reset ¶
func (x *MarketWithFee) Reset()
func (*MarketWithFee) String ¶
func (x *MarketWithFee) String() string
type Preview ¶
type Preview struct { // The price of the market. Price *Price `protobuf:"bytes,1,opt,name=price,proto3" json:"price,omitempty"` // The fees of the market. Fee *Fee `protobuf:"bytes,2,opt,name=fee,proto3" json:"fee,omitempty"` // The previewd amount (fees excluded). Amount uint64 `protobuf:"varint,3,opt,name=amount,proto3" json:"amount,omitempty"` // The asset of the previewed amount (fees excluded). Asset string `protobuf:"bytes,4,opt,name=asset,proto3" json:"asset,omitempty"` // The previewed fee amount, FeeAmount uint64 `protobuf:"varint,5,opt,name=fee_amount,json=feeAmount,proto3" json:"fee_amount,omitempty"` // The asset of the previewed fee amount, FeeAsset string `protobuf:"bytes,6,opt,name=fee_asset,json=feeAsset,proto3" json:"fee_asset,omitempty"` // contains filtered or unexported fields }
func (*Preview) Descriptor
deprecated
func (*Preview) GetFeeAmount ¶
func (*Preview) GetFeeAsset ¶
func (*Preview) ProtoMessage ¶
func (*Preview) ProtoMessage()
func (*Preview) ProtoReflect ¶
func (x *Preview) ProtoReflect() protoreflect.Message
type PreviewTradeRequest ¶
type PreviewTradeRequest struct { Market *Market `protobuf:"bytes,1,opt,name=market,proto3" json:"market,omitempty"` Type TradeType `protobuf:"varint,2,opt,name=type,proto3,enum=tdex.v2.TradeType" json:"type,omitempty"` Amount uint64 `protobuf:"varint,3,opt,name=amount,proto3" json:"amount,omitempty"` Asset string `protobuf:"bytes,4,opt,name=asset,proto3" json:"asset,omitempty"` FeeAsset string `protobuf:"bytes,5,opt,name=fee_asset,json=feeAsset,proto3" json:"fee_asset,omitempty"` // contains filtered or unexported fields }
func (*PreviewTradeRequest) Descriptor
deprecated
func (*PreviewTradeRequest) Descriptor() ([]byte, []int)
Deprecated: Use PreviewTradeRequest.ProtoReflect.Descriptor instead.
func (*PreviewTradeRequest) GetAmount ¶
func (x *PreviewTradeRequest) GetAmount() uint64
func (*PreviewTradeRequest) GetAsset ¶
func (x *PreviewTradeRequest) GetAsset() string
func (*PreviewTradeRequest) GetFeeAsset ¶
func (x *PreviewTradeRequest) GetFeeAsset() string
func (*PreviewTradeRequest) GetMarket ¶
func (x *PreviewTradeRequest) GetMarket() *Market
func (*PreviewTradeRequest) GetType ¶
func (x *PreviewTradeRequest) GetType() TradeType
func (*PreviewTradeRequest) ProtoMessage ¶
func (*PreviewTradeRequest) ProtoMessage()
func (*PreviewTradeRequest) ProtoReflect ¶
func (x *PreviewTradeRequest) ProtoReflect() protoreflect.Message
func (*PreviewTradeRequest) Reset ¶
func (x *PreviewTradeRequest) Reset()
func (*PreviewTradeRequest) String ¶
func (x *PreviewTradeRequest) String() string
type PreviewTradeResponse ¶
type PreviewTradeResponse struct { Previews []*Preview `protobuf:"bytes,1,rep,name=previews,proto3" json:"previews,omitempty"` // contains filtered or unexported fields }
func (*PreviewTradeResponse) Descriptor
deprecated
func (*PreviewTradeResponse) Descriptor() ([]byte, []int)
Deprecated: Use PreviewTradeResponse.ProtoReflect.Descriptor instead.
func (*PreviewTradeResponse) GetPreviews ¶
func (x *PreviewTradeResponse) GetPreviews() []*Preview
func (*PreviewTradeResponse) ProtoMessage ¶
func (*PreviewTradeResponse) ProtoMessage()
func (*PreviewTradeResponse) ProtoReflect ¶
func (x *PreviewTradeResponse) ProtoReflect() protoreflect.Message
func (*PreviewTradeResponse) Reset ¶
func (x *PreviewTradeResponse) Reset()
func (*PreviewTradeResponse) String ¶
func (x *PreviewTradeResponse) String() string
type Price ¶
type Price struct { BasePrice float64 `protobuf:"fixed64,1,opt,name=base_price,json=basePrice,proto3" json:"base_price,omitempty"` QuotePrice float64 `protobuf:"fixed64,2,opt,name=quote_price,json=quotePrice,proto3" json:"quote_price,omitempty"` // contains filtered or unexported fields }
func (*Price) Descriptor
deprecated
func (*Price) GetBasePrice ¶
func (*Price) GetQuotePrice ¶
func (*Price) ProtoMessage ¶
func (*Price) ProtoMessage()
func (*Price) ProtoReflect ¶
func (x *Price) ProtoReflect() protoreflect.Message
type ProposeTradeRequest ¶
type ProposeTradeRequest struct { Market *Market `protobuf:"bytes,1,opt,name=market,proto3" json:"market,omitempty"` Type TradeType `protobuf:"varint,2,opt,name=type,proto3,enum=tdex.v2.TradeType" json:"type,omitempty"` SwapRequest *SwapRequest `protobuf:"bytes,3,opt,name=swap_request,json=swapRequest,proto3" json:"swap_request,omitempty"` FeeAmount uint64 `protobuf:"varint,4,opt,name=fee_amount,json=feeAmount,proto3" json:"fee_amount,omitempty"` FeeAsset string `protobuf:"bytes,5,opt,name=fee_asset,json=feeAsset,proto3" json:"fee_asset,omitempty"` // contains filtered or unexported fields }
func (*ProposeTradeRequest) Descriptor
deprecated
func (*ProposeTradeRequest) Descriptor() ([]byte, []int)
Deprecated: Use ProposeTradeRequest.ProtoReflect.Descriptor instead.
func (*ProposeTradeRequest) GetFeeAmount ¶
func (x *ProposeTradeRequest) GetFeeAmount() uint64
func (*ProposeTradeRequest) GetFeeAsset ¶
func (x *ProposeTradeRequest) GetFeeAsset() string
func (*ProposeTradeRequest) GetMarket ¶
func (x *ProposeTradeRequest) GetMarket() *Market
func (*ProposeTradeRequest) GetSwapRequest ¶
func (x *ProposeTradeRequest) GetSwapRequest() *SwapRequest
func (*ProposeTradeRequest) GetType ¶
func (x *ProposeTradeRequest) GetType() TradeType
func (*ProposeTradeRequest) ProtoMessage ¶
func (*ProposeTradeRequest) ProtoMessage()
func (*ProposeTradeRequest) ProtoReflect ¶
func (x *ProposeTradeRequest) ProtoReflect() protoreflect.Message
func (*ProposeTradeRequest) Reset ¶
func (x *ProposeTradeRequest) Reset()
func (*ProposeTradeRequest) String ¶
func (x *ProposeTradeRequest) String() string
type ProposeTradeResponse ¶
type ProposeTradeResponse struct { SwapAccept *SwapAccept `protobuf:"bytes,1,opt,name=swap_accept,json=swapAccept,proto3" json:"swap_accept,omitempty"` SwapFail *SwapFail `protobuf:"bytes,2,opt,name=swap_fail,json=swapFail,proto3" json:"swap_fail,omitempty"` ExpiryTimeUnix uint64 `protobuf:"varint,3,opt,name=expiry_time_unix,json=expiryTimeUnix,proto3" json:"expiry_time_unix,omitempty"` // contains filtered or unexported fields }
func (*ProposeTradeResponse) Descriptor
deprecated
func (*ProposeTradeResponse) Descriptor() ([]byte, []int)
Deprecated: Use ProposeTradeResponse.ProtoReflect.Descriptor instead.
func (*ProposeTradeResponse) GetExpiryTimeUnix ¶
func (x *ProposeTradeResponse) GetExpiryTimeUnix() uint64
func (*ProposeTradeResponse) GetSwapAccept ¶
func (x *ProposeTradeResponse) GetSwapAccept() *SwapAccept
func (*ProposeTradeResponse) GetSwapFail ¶
func (x *ProposeTradeResponse) GetSwapFail() *SwapFail
func (*ProposeTradeResponse) ProtoMessage ¶
func (*ProposeTradeResponse) ProtoMessage()
func (*ProposeTradeResponse) ProtoReflect ¶
func (x *ProposeTradeResponse) ProtoReflect() protoreflect.Message
func (*ProposeTradeResponse) Reset ¶
func (x *ProposeTradeResponse) Reset()
func (*ProposeTradeResponse) String ¶
func (x *ProposeTradeResponse) String() string
type SupportedContentTypesRequest ¶
type SupportedContentTypesRequest struct {
// contains filtered or unexported fields
}
func (*SupportedContentTypesRequest) Descriptor
deprecated
func (*SupportedContentTypesRequest) Descriptor() ([]byte, []int)
Deprecated: Use SupportedContentTypesRequest.ProtoReflect.Descriptor instead.
func (*SupportedContentTypesRequest) ProtoMessage ¶
func (*SupportedContentTypesRequest) ProtoMessage()
func (*SupportedContentTypesRequest) ProtoReflect ¶
func (x *SupportedContentTypesRequest) ProtoReflect() protoreflect.Message
func (*SupportedContentTypesRequest) Reset ¶
func (x *SupportedContentTypesRequest) Reset()
func (*SupportedContentTypesRequest) String ¶
func (x *SupportedContentTypesRequest) String() string
type SupportedContentTypesResponse ¶
type SupportedContentTypesResponse struct { AcceptedTypes []ContentType `` /* 133-byte string literal not displayed */ // contains filtered or unexported fields }
func (*SupportedContentTypesResponse) Descriptor
deprecated
func (*SupportedContentTypesResponse) Descriptor() ([]byte, []int)
Deprecated: Use SupportedContentTypesResponse.ProtoReflect.Descriptor instead.
func (*SupportedContentTypesResponse) GetAcceptedTypes ¶
func (x *SupportedContentTypesResponse) GetAcceptedTypes() []ContentType
func (*SupportedContentTypesResponse) ProtoMessage ¶
func (*SupportedContentTypesResponse) ProtoMessage()
func (*SupportedContentTypesResponse) ProtoReflect ¶
func (x *SupportedContentTypesResponse) ProtoReflect() protoreflect.Message
func (*SupportedContentTypesResponse) Reset ¶
func (x *SupportedContentTypesResponse) Reset()
func (*SupportedContentTypesResponse) String ¶
func (x *SupportedContentTypesResponse) String() string
type SwapAccept ¶
type SwapAccept struct { // Random unique identifier for the current message Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // indetifier of the SwapRequest message RequestId string `protobuf:"bytes,2,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // The partial signed transaction base64 encoded containing the Responder's // signed inputs in a PSBT format Transaction string `protobuf:"bytes,3,opt,name=transaction,proto3" json:"transaction,omitempty"` // In case of psetv2 transaction, the original list of trader's unblinded inputs, // including also those of the inputs added by the provider. UnblindedInputs []*UnblindedInput `protobuf:"bytes,4,rep,name=unblinded_inputs,json=unblindedInputs,proto3" json:"unblinded_inputs,omitempty"` // contains filtered or unexported fields }
func (*SwapAccept) Descriptor
deprecated
func (*SwapAccept) Descriptor() ([]byte, []int)
Deprecated: Use SwapAccept.ProtoReflect.Descriptor instead.
func (*SwapAccept) GetId ¶
func (x *SwapAccept) GetId() string
func (*SwapAccept) GetRequestId ¶
func (x *SwapAccept) GetRequestId() string
func (*SwapAccept) GetTransaction ¶
func (x *SwapAccept) GetTransaction() string
func (*SwapAccept) GetUnblindedInputs ¶
func (x *SwapAccept) GetUnblindedInputs() []*UnblindedInput
func (*SwapAccept) ProtoMessage ¶
func (*SwapAccept) ProtoMessage()
func (*SwapAccept) ProtoReflect ¶
func (x *SwapAccept) ProtoReflect() protoreflect.Message
func (*SwapAccept) Reset ¶
func (x *SwapAccept) Reset()
func (*SwapAccept) String ¶
func (x *SwapAccept) String() string
type SwapComplete ¶
type SwapComplete struct { // Random unique identifier for the current message Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // indetifier of the SwapAccept message AcceptId string `protobuf:"bytes,2,opt,name=accept_id,json=acceptId,proto3" json:"accept_id,omitempty"` // The signed transaction base64 encoded containing the Proposers's signed // inputs in a PSBT format Transaction string `protobuf:"bytes,3,opt,name=transaction,proto3" json:"transaction,omitempty"` // contains filtered or unexported fields }
func (*SwapComplete) Descriptor
deprecated
func (*SwapComplete) Descriptor() ([]byte, []int)
Deprecated: Use SwapComplete.ProtoReflect.Descriptor instead.
func (*SwapComplete) GetAcceptId ¶
func (x *SwapComplete) GetAcceptId() string
func (*SwapComplete) GetId ¶
func (x *SwapComplete) GetId() string
func (*SwapComplete) GetTransaction ¶
func (x *SwapComplete) GetTransaction() string
func (*SwapComplete) ProtoMessage ¶
func (*SwapComplete) ProtoMessage()
func (*SwapComplete) ProtoReflect ¶
func (x *SwapComplete) ProtoReflect() protoreflect.Message
func (*SwapComplete) Reset ¶
func (x *SwapComplete) Reset()
func (*SwapComplete) String ¶
func (x *SwapComplete) String() string
type SwapFail ¶
type SwapFail struct { // Random unique identifier for the current message Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // indetifier of either SwapRequest or SwapAccept message. It can be empty MessageId string `protobuf:"bytes,2,opt,name=message_id,json=messageId,proto3" json:"message_id,omitempty"` // The failure code. It can be empty FailureCode uint32 `protobuf:"varint,3,opt,name=failure_code,json=failureCode,proto3" json:"failure_code,omitempty"` // The failure reason messaged FailureMessage string `protobuf:"bytes,4,opt,name=failure_message,json=failureMessage,proto3" json:"failure_message,omitempty"` // contains filtered or unexported fields }
func (*SwapFail) Descriptor
deprecated
func (*SwapFail) GetFailureCode ¶
func (*SwapFail) GetFailureMessage ¶
func (*SwapFail) GetMessageId ¶
func (*SwapFail) ProtoMessage ¶
func (*SwapFail) ProtoMessage()
func (*SwapFail) ProtoReflect ¶
func (x *SwapFail) ProtoReflect() protoreflect.Message
type SwapRequest ¶
type SwapRequest struct { // Random unique identifier for the current message Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // The proposer's quantity AmountP uint64 `protobuf:"varint,2,opt,name=amount_p,json=amountP,proto3" json:"amount_p,omitempty"` // The proposer's asset hash AssetP string `protobuf:"bytes,3,opt,name=asset_p,json=assetP,proto3" json:"asset_p,omitempty"` // The responder's quantity AmountR uint64 `protobuf:"varint,4,opt,name=amount_r,json=amountR,proto3" json:"amount_r,omitempty"` // The responder's asset hash AssetR string `protobuf:"bytes,5,opt,name=asset_r,json=assetR,proto3" json:"asset_r,omitempty"` // The proposer's unsigned transaction in PSET v2 format (base64 string) Transaction string `protobuf:"bytes,6,opt,name=transaction,proto3" json:"transaction,omitempty"` // The list of trader's unblinded inputs data, even in case they are // unconfidential. UnblindedInputs []*UnblindedInput `protobuf:"bytes,7,rep,name=unblinded_inputs,json=unblindedInputs,proto3" json:"unblinded_inputs,omitempty"` // contains filtered or unexported fields }
func (*SwapRequest) Descriptor
deprecated
func (*SwapRequest) Descriptor() ([]byte, []int)
Deprecated: Use SwapRequest.ProtoReflect.Descriptor instead.
func (*SwapRequest) GetAmountP ¶
func (x *SwapRequest) GetAmountP() uint64
func (*SwapRequest) GetAmountR ¶
func (x *SwapRequest) GetAmountR() uint64
func (*SwapRequest) GetAssetP ¶
func (x *SwapRequest) GetAssetP() string
func (*SwapRequest) GetAssetR ¶
func (x *SwapRequest) GetAssetR() string
func (*SwapRequest) GetId ¶
func (x *SwapRequest) GetId() string
func (*SwapRequest) GetTransaction ¶
func (x *SwapRequest) GetTransaction() string
func (*SwapRequest) GetUnblindedInputs ¶
func (x *SwapRequest) GetUnblindedInputs() []*UnblindedInput
func (*SwapRequest) ProtoMessage ¶
func (*SwapRequest) ProtoMessage()
func (*SwapRequest) ProtoReflect ¶
func (x *SwapRequest) ProtoReflect() protoreflect.Message
func (*SwapRequest) Reset ¶
func (x *SwapRequest) Reset()
func (*SwapRequest) String ¶
func (x *SwapRequest) String() string
type TradeServiceClient ¶
type TradeServiceClient interface { // ListMarkets lists all the markets open for trading. ListMarkets(ctx context.Context, in *ListMarketsRequest, opts ...grpc.CallOption) (*ListMarketsResponse, error) // GetMarketBalance retutns the balance of the two current reserves of the // given market. GetMarketBalance(ctx context.Context, in *GetMarketBalanceRequest, opts ...grpc.CallOption) (*GetMarketBalanceResponse, error) // GetMarketPrice retutns the spot price for the requested market and its // minimum tradable amount of base asset. GetMarketPrice(ctx context.Context, in *GetMarketPriceRequest, opts ...grpc.CallOption) (*GetMarketPriceResponse, error) // PreviewTrade returns a counter amount and asset in response to the // provided ones and a trade type for a market. // // The trade type can assume values BUY or SELL and it always refer to the // fixed base asset. // For example: // * if trade type is BUY, it means the trader wants to buy base asset funds. // * if trade type is SELL, it means the trader wants to sell base asset funds. PreviewTrade(ctx context.Context, in *PreviewTradeRequest, opts ...grpc.CallOption) (*PreviewTradeResponse, error) // ProposeTrade allows a trader to present a SwapRequest. The service answers // with a SwapAccept, filling the request's partial transaction, + an // expiration time to complete the swap when accepting the swap, or, // otherwise, with a SwapFail containg the reason for the rejection of the // proposal. ProposeTrade(ctx context.Context, in *ProposeTradeRequest, opts ...grpc.CallOption) (*ProposeTradeResponse, error) // CompleteTrade can be used by the trader to let the daemon finalizing, // extracting, and broadcasting the swap transaction, once he's signed his // inputs. // This is not mandatory, the trader can do the steps above on his own // alternatively. CompleteTrade(ctx context.Context, in *CompleteTradeRequest, opts ...grpc.CallOption) (*CompleteTradeResponse, error) }
TradeServiceClient is the client API for TradeService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewTradeServiceClient ¶
func NewTradeServiceClient(cc grpc.ClientConnInterface) TradeServiceClient
type TradeServiceServer ¶
type TradeServiceServer interface { // ListMarkets lists all the markets open for trading. ListMarkets(context.Context, *ListMarketsRequest) (*ListMarketsResponse, error) // GetMarketBalance retutns the balance of the two current reserves of the // given market. GetMarketBalance(context.Context, *GetMarketBalanceRequest) (*GetMarketBalanceResponse, error) // GetMarketPrice retutns the spot price for the requested market and its // minimum tradable amount of base asset. GetMarketPrice(context.Context, *GetMarketPriceRequest) (*GetMarketPriceResponse, error) // PreviewTrade returns a counter amount and asset in response to the // provided ones and a trade type for a market. // // The trade type can assume values BUY or SELL and it always refer to the // fixed base asset. // For example: // * if trade type is BUY, it means the trader wants to buy base asset funds. // * if trade type is SELL, it means the trader wants to sell base asset funds. PreviewTrade(context.Context, *PreviewTradeRequest) (*PreviewTradeResponse, error) // ProposeTrade allows a trader to present a SwapRequest. The service answers // with a SwapAccept, filling the request's partial transaction, + an // expiration time to complete the swap when accepting the swap, or, // otherwise, with a SwapFail containg the reason for the rejection of the // proposal. ProposeTrade(context.Context, *ProposeTradeRequest) (*ProposeTradeResponse, error) // CompleteTrade can be used by the trader to let the daemon finalizing, // extracting, and broadcasting the swap transaction, once he's signed his // inputs. // This is not mandatory, the trader can do the steps above on his own // alternatively. CompleteTrade(context.Context, *CompleteTradeRequest) (*CompleteTradeResponse, error) }
TradeServiceServer is the server API for TradeService service. All implementations should embed UnimplementedTradeServiceServer for forward compatibility
type TradeType ¶
type TradeType int32
func (TradeType) Descriptor ¶
func (TradeType) Descriptor() protoreflect.EnumDescriptor
func (TradeType) EnumDescriptor
deprecated
func (TradeType) Number ¶
func (x TradeType) Number() protoreflect.EnumNumber
func (TradeType) Type ¶
func (TradeType) Type() protoreflect.EnumType
type TransportServiceClient ¶
type TransportServiceClient interface {
SupportedContentTypes(ctx context.Context, in *SupportedContentTypesRequest, opts ...grpc.CallOption) (*SupportedContentTypesResponse, error)
}
TransportServiceClient is the client API for TransportService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewTransportServiceClient ¶
func NewTransportServiceClient(cc grpc.ClientConnInterface) TransportServiceClient
type TransportServiceServer ¶
type TransportServiceServer interface {
SupportedContentTypes(context.Context, *SupportedContentTypesRequest) (*SupportedContentTypesResponse, error)
}
TransportServiceServer is the server API for TransportService service. All implementations should embed UnimplementedTransportServiceServer for forward compatibility
type UnblindedInput ¶
type UnblindedInput struct { // Index of the transaction input of reference. Index uint32 `protobuf:"varint,1,opt,name=index,proto3" json:"index,omitempty"` // Unblinded asset. Asset string `protobuf:"bytes,2,opt,name=asset,proto3" json:"asset,omitempty"` // Unblinded amount. Amount uint64 `protobuf:"varint,3,opt,name=amount,proto3" json:"amount,omitempty"` // Asset blinider when blinding the prevout. AssetBlinder string `protobuf:"bytes,4,opt,name=asset_blinder,json=assetBlinder,proto3" json:"asset_blinder,omitempty"` // Amount blinider used when blinding the prevout. AmountBlinder string `protobuf:"bytes,5,opt,name=amount_blinder,json=amountBlinder,proto3" json:"amount_blinder,omitempty"` // contains filtered or unexported fields }
func (*UnblindedInput) Descriptor
deprecated
func (*UnblindedInput) Descriptor() ([]byte, []int)
Deprecated: Use UnblindedInput.ProtoReflect.Descriptor instead.
func (*UnblindedInput) GetAmount ¶
func (x *UnblindedInput) GetAmount() uint64
func (*UnblindedInput) GetAmountBlinder ¶
func (x *UnblindedInput) GetAmountBlinder() string
func (*UnblindedInput) GetAsset ¶
func (x *UnblindedInput) GetAsset() string
func (*UnblindedInput) GetAssetBlinder ¶
func (x *UnblindedInput) GetAssetBlinder() string
func (*UnblindedInput) GetIndex ¶
func (x *UnblindedInput) GetIndex() uint32
func (*UnblindedInput) ProtoMessage ¶
func (*UnblindedInput) ProtoMessage()
func (*UnblindedInput) ProtoReflect ¶
func (x *UnblindedInput) ProtoReflect() protoreflect.Message
func (*UnblindedInput) Reset ¶
func (x *UnblindedInput) Reset()
func (*UnblindedInput) String ¶
func (x *UnblindedInput) String() string
type UnimplementedTradeServiceServer ¶
type UnimplementedTradeServiceServer struct { }
UnimplementedTradeServiceServer should be embedded to have forward compatible implementations.
func (UnimplementedTradeServiceServer) CompleteTrade ¶
func (UnimplementedTradeServiceServer) CompleteTrade(context.Context, *CompleteTradeRequest) (*CompleteTradeResponse, error)
func (UnimplementedTradeServiceServer) GetMarketBalance ¶
func (UnimplementedTradeServiceServer) GetMarketBalance(context.Context, *GetMarketBalanceRequest) (*GetMarketBalanceResponse, error)
func (UnimplementedTradeServiceServer) GetMarketPrice ¶
func (UnimplementedTradeServiceServer) GetMarketPrice(context.Context, *GetMarketPriceRequest) (*GetMarketPriceResponse, error)
func (UnimplementedTradeServiceServer) ListMarkets ¶
func (UnimplementedTradeServiceServer) ListMarkets(context.Context, *ListMarketsRequest) (*ListMarketsResponse, error)
func (UnimplementedTradeServiceServer) PreviewTrade ¶
func (UnimplementedTradeServiceServer) PreviewTrade(context.Context, *PreviewTradeRequest) (*PreviewTradeResponse, error)
func (UnimplementedTradeServiceServer) ProposeTrade ¶
func (UnimplementedTradeServiceServer) ProposeTrade(context.Context, *ProposeTradeRequest) (*ProposeTradeResponse, error)
type UnimplementedTransportServiceServer ¶
type UnimplementedTransportServiceServer struct { }
UnimplementedTransportServiceServer should be embedded to have forward compatible implementations.
func (UnimplementedTransportServiceServer) SupportedContentTypes ¶
func (UnimplementedTransportServiceServer) SupportedContentTypes(context.Context, *SupportedContentTypesRequest) (*SupportedContentTypesResponse, error)
type UnsafeTradeServiceServer ¶
type UnsafeTradeServiceServer interface {
// contains filtered or unexported methods
}
UnsafeTradeServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TradeServiceServer will result in compilation errors.
type UnsafeTransportServiceServer ¶
type UnsafeTransportServiceServer interface {
// contains filtered or unexported methods
}
UnsafeTransportServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TransportServiceServer will result in compilation errors.