api

package
v0.42.0-pre1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 26, 2021 License: MIT Imports: 16 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	SubmitTransactionV2Request_Type_name = map[int32]string{
		0: "TYPE_UNSPECIFIED",
		1: "TYPE_ASYNC",
		2: "TYPE_SYNC",
		3: "TYPE_COMMIT",
	}
	SubmitTransactionV2Request_Type_value = map[string]int32{
		"TYPE_UNSPECIFIED": 0,
		"TYPE_ASYNC":       1,
		"TYPE_SYNC":        2,
		"TYPE_COMMIT":      3,
	}
)

Enum value maps for SubmitTransactionV2Request_Type.

View Source
var File_api_trading_proto protoreflect.FileDescriptor
View Source
var TradingService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.v1.TradingService",
	HandlerType: (*TradingServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "SubmitTransactionV2",
			Handler:    _TradingService_SubmitTransactionV2_Handler,
		},
		{
			MethodName: "PropagateChainEvent",
			Handler:    _TradingService_PropagateChainEvent_Handler,
		},
		{
			MethodName: "Statistics",
			Handler:    _TradingService_Statistics_Handler,
		},
		{
			MethodName: "LastBlockHeight",
			Handler:    _TradingService_LastBlockHeight_Handler,
		},
		{
			MethodName: "GetVegaTime",
			Handler:    _TradingService_GetVegaTime_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "ObserveEventBus",
			Handler:       _TradingService_ObserveEventBus_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "api/trading.proto",
}

TradingService_ServiceDesc is the grpc.ServiceDesc for TradingService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterTradingServiceServer

func RegisterTradingServiceServer(s grpc.ServiceRegistrar, srv TradingServiceServer)

Types

type GetVegaTimeRequest

type GetVegaTimeRequest struct {
	// contains filtered or unexported fields
}

Request for the current time of the vega network

func (*GetVegaTimeRequest) Descriptor deprecated

func (*GetVegaTimeRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetVegaTimeRequest.ProtoReflect.Descriptor instead.

func (*GetVegaTimeRequest) ProtoMessage

func (*GetVegaTimeRequest) ProtoMessage()

func (*GetVegaTimeRequest) ProtoReflect

func (x *GetVegaTimeRequest) ProtoReflect() protoreflect.Message

func (*GetVegaTimeRequest) Reset

func (x *GetVegaTimeRequest) Reset()

func (*GetVegaTimeRequest) String

func (x *GetVegaTimeRequest) String() string

func (*GetVegaTimeRequest) Validate

func (this *GetVegaTimeRequest) Validate() error

type GetVegaTimeResponse

type GetVegaTimeResponse struct {

	// Timestamp representation of current VegaTime as represented in
	// Nanoseconds since the epoch, for example `1580473859111222333` corresponds to `2020-01-31T12:30:59.111222333Z`
	Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// contains filtered or unexported fields
}

Response for the current consensus coordinated time on the Vega network, referred to as "VegaTime"

func (*GetVegaTimeResponse) Descriptor deprecated

func (*GetVegaTimeResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetVegaTimeResponse.ProtoReflect.Descriptor instead.

func (*GetVegaTimeResponse) GetTimestamp

func (x *GetVegaTimeResponse) GetTimestamp() int64

func (*GetVegaTimeResponse) ProtoMessage

func (*GetVegaTimeResponse) ProtoMessage()

func (*GetVegaTimeResponse) ProtoReflect

func (x *GetVegaTimeResponse) ProtoReflect() protoreflect.Message

func (*GetVegaTimeResponse) Reset

func (x *GetVegaTimeResponse) Reset()

func (*GetVegaTimeResponse) String

func (x *GetVegaTimeResponse) String() string

func (*GetVegaTimeResponse) Validate

func (this *GetVegaTimeResponse) Validate() error

type LastBlockHeightRequest added in v0.38.0

type LastBlockHeightRequest struct {
	// contains filtered or unexported fields
}

A request to get the height of the very last block processed by tendermint

func (*LastBlockHeightRequest) Descriptor deprecated added in v0.38.0

func (*LastBlockHeightRequest) Descriptor() ([]byte, []int)

Deprecated: Use LastBlockHeightRequest.ProtoReflect.Descriptor instead.

func (*LastBlockHeightRequest) ProtoMessage added in v0.38.0

func (*LastBlockHeightRequest) ProtoMessage()

func (*LastBlockHeightRequest) ProtoReflect added in v0.38.0

func (x *LastBlockHeightRequest) ProtoReflect() protoreflect.Message

func (*LastBlockHeightRequest) Reset added in v0.38.0

func (x *LastBlockHeightRequest) Reset()

func (*LastBlockHeightRequest) String added in v0.38.0

func (x *LastBlockHeightRequest) String() string

func (*LastBlockHeightRequest) Validate added in v0.38.0

func (this *LastBlockHeightRequest) Validate() error

type LastBlockHeightResponse added in v0.38.0

type LastBlockHeightResponse struct {
	Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"`
	// contains filtered or unexported fields
}

A response with the height of the last block processed by tendermint

func (*LastBlockHeightResponse) Descriptor deprecated added in v0.38.0

func (*LastBlockHeightResponse) Descriptor() ([]byte, []int)

Deprecated: Use LastBlockHeightResponse.ProtoReflect.Descriptor instead.

func (*LastBlockHeightResponse) GetHeight added in v0.38.0

func (x *LastBlockHeightResponse) GetHeight() uint64

func (*LastBlockHeightResponse) ProtoMessage added in v0.38.0

func (*LastBlockHeightResponse) ProtoMessage()

func (*LastBlockHeightResponse) ProtoReflect added in v0.38.0

func (x *LastBlockHeightResponse) ProtoReflect() protoreflect.Message

func (*LastBlockHeightResponse) Reset added in v0.38.0

func (x *LastBlockHeightResponse) Reset()

func (*LastBlockHeightResponse) String added in v0.38.0

func (x *LastBlockHeightResponse) String() string

func (*LastBlockHeightResponse) Validate added in v0.38.0

func (this *LastBlockHeightResponse) Validate() error

type ObserveEventBusRequest

type ObserveEventBusRequest struct {

	// One or more types of event, required field
	Type []v11.BusEventType `protobuf:"varint,1,rep,packed,name=type,proto3,enum=vega.events.v1.BusEventType" json:"type,omitempty"`
	// Market identifier, optional field
	MarketId string `protobuf:"bytes,2,opt,name=market_id,json=marketId,proto3" json:"market_id,omitempty"`
	// Party identifier, optional field
	PartyId string `protobuf:"bytes,3,opt,name=party_id,json=partyId,proto3" json:"party_id,omitempty"`
	// Batch size, optional field -
	// If not specified, any events received will be sent immediately. If the client is not ready
	// for the next data-set, data may be dropped a number of times, and eventually the stream is closed.
	// if specified, the first batch will be sent when ready. To receive the next set of events, the client
	// must write an `ObserveEventBatch` message on the stream to flush the buffer.
	// If no message is received in 5 seconds, the stream is closed.
	// Default: 0, send any and all events when they are available.
	BatchSize int64 `protobuf:"varint,4,opt,name=batch_size,json=batchSize,proto3" json:"batch_size,omitempty"`
	// contains filtered or unexported fields
}

Request to subscribe to a stream of one or more event types from the Vega event bus

func (*ObserveEventBusRequest) Descriptor deprecated

func (*ObserveEventBusRequest) Descriptor() ([]byte, []int)

Deprecated: Use ObserveEventBusRequest.ProtoReflect.Descriptor instead.

func (*ObserveEventBusRequest) GetBatchSize

func (x *ObserveEventBusRequest) GetBatchSize() int64

func (*ObserveEventBusRequest) GetMarketId

func (x *ObserveEventBusRequest) GetMarketId() string

func (*ObserveEventBusRequest) GetPartyId

func (x *ObserveEventBusRequest) GetPartyId() string

func (*ObserveEventBusRequest) GetType

func (x *ObserveEventBusRequest) GetType() []v11.BusEventType

func (*ObserveEventBusRequest) ProtoMessage

func (*ObserveEventBusRequest) ProtoMessage()

func (*ObserveEventBusRequest) ProtoReflect

func (x *ObserveEventBusRequest) ProtoReflect() protoreflect.Message

func (*ObserveEventBusRequest) Reset

func (x *ObserveEventBusRequest) Reset()

func (*ObserveEventBusRequest) String

func (x *ObserveEventBusRequest) String() string

func (*ObserveEventBusRequest) Validate

func (this *ObserveEventBusRequest) Validate() error

type ObserveEventBusResponse

type ObserveEventBusResponse struct {

	// One or more events
	Events []*v11.BusEvent `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"`
	// contains filtered or unexported fields
}

Response to a subscribed stream of events from the Vega event bus

func (*ObserveEventBusResponse) Descriptor deprecated

func (*ObserveEventBusResponse) Descriptor() ([]byte, []int)

Deprecated: Use ObserveEventBusResponse.ProtoReflect.Descriptor instead.

func (*ObserveEventBusResponse) GetEvents

func (x *ObserveEventBusResponse) GetEvents() []*v11.BusEvent

func (*ObserveEventBusResponse) ProtoMessage

func (*ObserveEventBusResponse) ProtoMessage()

func (*ObserveEventBusResponse) ProtoReflect

func (x *ObserveEventBusResponse) ProtoReflect() protoreflect.Message

func (*ObserveEventBusResponse) Reset

func (x *ObserveEventBusResponse) Reset()

func (*ObserveEventBusResponse) String

func (x *ObserveEventBusResponse) String() string

func (*ObserveEventBusResponse) Validate

func (this *ObserveEventBusResponse) Validate() error

type PropagateChainEventRequest

type PropagateChainEventRequest struct {

	// Chain event
	Event []byte `protobuf:"bytes,1,opt,name=event,proto3" json:"event,omitempty"`
	// Public key
	PubKey string `protobuf:"bytes,2,opt,name=pub_key,json=pubKey,proto3" json:"pub_key,omitempty"`
	// Signature
	Signature []byte `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"`
	// contains filtered or unexported fields
}

Request for a new event sent by the blockchain queue to be propagated on Vega

func (*PropagateChainEventRequest) Descriptor deprecated

func (*PropagateChainEventRequest) Descriptor() ([]byte, []int)

Deprecated: Use PropagateChainEventRequest.ProtoReflect.Descriptor instead.

func (*PropagateChainEventRequest) GetEvent

func (x *PropagateChainEventRequest) GetEvent() []byte

func (*PropagateChainEventRequest) GetPubKey

func (x *PropagateChainEventRequest) GetPubKey() string

func (*PropagateChainEventRequest) GetSignature

func (x *PropagateChainEventRequest) GetSignature() []byte

func (*PropagateChainEventRequest) ProtoMessage

func (*PropagateChainEventRequest) ProtoMessage()

func (*PropagateChainEventRequest) ProtoReflect

func (*PropagateChainEventRequest) Reset

func (x *PropagateChainEventRequest) Reset()

func (*PropagateChainEventRequest) String

func (x *PropagateChainEventRequest) String() string

func (*PropagateChainEventRequest) Validate

func (this *PropagateChainEventRequest) Validate() error

type PropagateChainEventResponse

type PropagateChainEventResponse struct {

	// Success will be true if the event was accepted by the node,
	// **Important** - success does not mean that the event is confirmed by consensus
	Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
	// contains filtered or unexported fields
}

Response for a new event sent by the blockchain queue to be propagated on Vega

func (*PropagateChainEventResponse) Descriptor deprecated

func (*PropagateChainEventResponse) Descriptor() ([]byte, []int)

Deprecated: Use PropagateChainEventResponse.ProtoReflect.Descriptor instead.

func (*PropagateChainEventResponse) GetSuccess

func (x *PropagateChainEventResponse) GetSuccess() bool

func (*PropagateChainEventResponse) ProtoMessage

func (*PropagateChainEventResponse) ProtoMessage()

func (*PropagateChainEventResponse) ProtoReflect

func (*PropagateChainEventResponse) Reset

func (x *PropagateChainEventResponse) Reset()

func (*PropagateChainEventResponse) String

func (x *PropagateChainEventResponse) String() string

func (*PropagateChainEventResponse) Validate

func (this *PropagateChainEventResponse) Validate() error

type Statistics

type Statistics struct {

	// Current block height as reported by the Vega blockchain
	BlockHeight uint64 `protobuf:"varint,1,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"`
	// Current backlog length (number of transactions) that are waiting to be included in a block
	BacklogLength uint64 `protobuf:"varint,2,opt,name=backlog_length,json=backlogLength,proto3" json:"backlog_length,omitempty"`
	// Total number of connected peers to this node
	TotalPeers uint64 `protobuf:"varint,3,opt,name=total_peers,json=totalPeers,proto3" json:"total_peers,omitempty"`
	// Genesis block date and time formatted in ISO-8601 datetime format with nanosecond precision
	GenesisTime string `protobuf:"bytes,4,opt,name=genesis_time,json=genesisTime,proto3" json:"genesis_time,omitempty"`
	// Current system date and time formatted in ISO-8601 datetime format with nanosecond precision
	CurrentTime string `protobuf:"bytes,5,opt,name=current_time,json=currentTime,proto3" json:"current_time,omitempty"`
	// Current Vega date and time formatted in ISO-8601 datetime format with nanosecond precision
	VegaTime string `protobuf:"bytes,6,opt,name=vega_time,json=vegaTime,proto3" json:"vega_time,omitempty"`
	// Status of the connection to the Vega blockchain
	// - See [`ChainStatus`](#vega.ChainStatus)
	Status proto1.ChainStatus `protobuf:"varint,7,opt,name=status,proto3,enum=vega.ChainStatus" json:"status,omitempty"`
	// Transactions per block
	TxPerBlock uint64 `protobuf:"varint,8,opt,name=tx_per_block,json=txPerBlock,proto3" json:"tx_per_block,omitempty"`
	// Average transaction size in bytes
	AverageTxBytes uint64 `protobuf:"varint,9,opt,name=average_tx_bytes,json=averageTxBytes,proto3" json:"average_tx_bytes,omitempty"`
	// Average orders per block
	AverageOrdersPerBlock uint64 `` /* 130-byte string literal not displayed */
	// Trades emitted per second
	TradesPerSecond uint64 `protobuf:"varint,11,opt,name=trades_per_second,json=tradesPerSecond,proto3" json:"trades_per_second,omitempty"`
	// Orders processed per second
	OrdersPerSecond uint64 `protobuf:"varint,12,opt,name=orders_per_second,json=ordersPerSecond,proto3" json:"orders_per_second,omitempty"`
	// Total markets on this Vega network
	TotalMarkets uint64 `protobuf:"varint,13,opt,name=total_markets,json=totalMarkets,proto3" json:"total_markets,omitempty"`
	// Total number of order amendments since genesis (on all markets)
	TotalAmendOrder uint64 `protobuf:"varint,16,opt,name=total_amend_order,json=totalAmendOrder,proto3" json:"total_amend_order,omitempty"`
	// Total number of order cancellations since genesis (on all markets)
	TotalCancelOrder uint64 `protobuf:"varint,17,opt,name=total_cancel_order,json=totalCancelOrder,proto3" json:"total_cancel_order,omitempty"`
	// Total number of order submissions since genesis (on all markets)
	TotalCreateOrder uint64 `protobuf:"varint,18,opt,name=total_create_order,json=totalCreateOrder,proto3" json:"total_create_order,omitempty"`
	// Total number of orders processed since genesis (on all markets)
	TotalOrders uint64 `protobuf:"varint,19,opt,name=total_orders,json=totalOrders,proto3" json:"total_orders,omitempty"`
	// Total number of trades emitted since genesis (on all markets)
	TotalTrades uint64 `protobuf:"varint,20,opt,name=total_trades,json=totalTrades,proto3" json:"total_trades,omitempty"`
	// Current number of stream subscribers to order data
	OrderSubscriptions uint32 `protobuf:"varint,21,opt,name=order_subscriptions,json=orderSubscriptions,proto3" json:"order_subscriptions,omitempty"`
	// Current number of stream subscribers to trade data
	TradeSubscriptions uint32 `protobuf:"varint,22,opt,name=trade_subscriptions,json=tradeSubscriptions,proto3" json:"trade_subscriptions,omitempty"`
	// Current number of stream subscribers to candle-stick data
	CandleSubscriptions uint32 `protobuf:"varint,23,opt,name=candle_subscriptions,json=candleSubscriptions,proto3" json:"candle_subscriptions,omitempty"`
	// Current number of stream subscribers to market depth data
	MarketDepthSubscriptions uint32 `` /* 137-byte string literal not displayed */
	// Current number of stream subscribers to positions data
	PositionsSubscriptions uint32 `` /* 129-byte string literal not displayed */
	// Current number of stream subscribers to account data
	AccountSubscriptions uint32 `protobuf:"varint,26,opt,name=account_subscriptions,json=accountSubscriptions,proto3" json:"account_subscriptions,omitempty"`
	// Current number of stream subscribers to market data
	MarketDataSubscriptions uint32 `` /* 134-byte string literal not displayed */
	// The version hash of the Vega node software
	AppVersionHash string `protobuf:"bytes,28,opt,name=app_version_hash,json=appVersionHash,proto3" json:"app_version_hash,omitempty"`
	// The version of the Vega node software
	AppVersion string `protobuf:"bytes,29,opt,name=app_version,json=appVersion,proto3" json:"app_version,omitempty"`
	// The version of the underlying Vega blockchain
	ChainVersion string `protobuf:"bytes,30,opt,name=chain_version,json=chainVersion,proto3" json:"chain_version,omitempty"`
	// Current block duration, in nanoseconds
	BlockDuration uint64 `protobuf:"varint,31,opt,name=block_duration,json=blockDuration,proto3" json:"block_duration,omitempty"`
	// Total uptime for this node formatted in ISO-8601 datetime format with nanosecond precision
	Uptime string `protobuf:"bytes,32,opt,name=uptime,proto3" json:"uptime,omitempty"`
	// Unique identifier for the underlying Vega blockchain
	ChainId string `protobuf:"bytes,33,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
	// Current number of stream subscribers to market depth update data
	MarketDepthUpdatesSubscriptions uint32 `` /* 160-byte string literal not displayed */
	// contains filtered or unexported fields
}

Vega domain specific statistics as reported by the node the caller is connected to

func (*Statistics) Descriptor deprecated

func (*Statistics) Descriptor() ([]byte, []int)

Deprecated: Use Statistics.ProtoReflect.Descriptor instead.

func (*Statistics) GetAccountSubscriptions

func (x *Statistics) GetAccountSubscriptions() uint32

func (*Statistics) GetAppVersion

func (x *Statistics) GetAppVersion() string

func (*Statistics) GetAppVersionHash

func (x *Statistics) GetAppVersionHash() string

func (*Statistics) GetAverageOrdersPerBlock

func (x *Statistics) GetAverageOrdersPerBlock() uint64

func (*Statistics) GetAverageTxBytes

func (x *Statistics) GetAverageTxBytes() uint64

func (*Statistics) GetBacklogLength

func (x *Statistics) GetBacklogLength() uint64

func (*Statistics) GetBlockDuration

func (x *Statistics) GetBlockDuration() uint64

func (*Statistics) GetBlockHeight

func (x *Statistics) GetBlockHeight() uint64

func (*Statistics) GetCandleSubscriptions

func (x *Statistics) GetCandleSubscriptions() uint32

func (*Statistics) GetChainId

func (x *Statistics) GetChainId() string

func (*Statistics) GetChainVersion

func (x *Statistics) GetChainVersion() string

func (*Statistics) GetCurrentTime

func (x *Statistics) GetCurrentTime() string

func (*Statistics) GetGenesisTime

func (x *Statistics) GetGenesisTime() string

func (*Statistics) GetMarketDataSubscriptions

func (x *Statistics) GetMarketDataSubscriptions() uint32

func (*Statistics) GetMarketDepthSubscriptions

func (x *Statistics) GetMarketDepthSubscriptions() uint32

func (*Statistics) GetMarketDepthUpdatesSubscriptions

func (x *Statistics) GetMarketDepthUpdatesSubscriptions() uint32

func (*Statistics) GetOrderSubscriptions

func (x *Statistics) GetOrderSubscriptions() uint32

func (*Statistics) GetOrdersPerSecond

func (x *Statistics) GetOrdersPerSecond() uint64

func (*Statistics) GetPositionsSubscriptions

func (x *Statistics) GetPositionsSubscriptions() uint32

func (*Statistics) GetStatus

func (x *Statistics) GetStatus() proto1.ChainStatus

func (*Statistics) GetTotalAmendOrder

func (x *Statistics) GetTotalAmendOrder() uint64

func (*Statistics) GetTotalCancelOrder

func (x *Statistics) GetTotalCancelOrder() uint64

func (*Statistics) GetTotalCreateOrder

func (x *Statistics) GetTotalCreateOrder() uint64

func (*Statistics) GetTotalMarkets

func (x *Statistics) GetTotalMarkets() uint64

func (*Statistics) GetTotalOrders

func (x *Statistics) GetTotalOrders() uint64

func (*Statistics) GetTotalPeers

func (x *Statistics) GetTotalPeers() uint64

func (*Statistics) GetTotalTrades

func (x *Statistics) GetTotalTrades() uint64

func (*Statistics) GetTradeSubscriptions

func (x *Statistics) GetTradeSubscriptions() uint32

func (*Statistics) GetTradesPerSecond

func (x *Statistics) GetTradesPerSecond() uint64

func (*Statistics) GetTxPerBlock

func (x *Statistics) GetTxPerBlock() uint64

func (*Statistics) GetUptime

func (x *Statistics) GetUptime() string

func (*Statistics) GetVegaTime

func (x *Statistics) GetVegaTime() string

func (*Statistics) ProtoMessage

func (*Statistics) ProtoMessage()

func (*Statistics) ProtoReflect

func (x *Statistics) ProtoReflect() protoreflect.Message

func (*Statistics) Reset

func (x *Statistics) Reset()

func (*Statistics) String

func (x *Statistics) String() string

func (*Statistics) Validate

func (this *Statistics) Validate() error

type StatisticsRequest

type StatisticsRequest struct {
	// contains filtered or unexported fields
}

A a request for statistics about the Vega network

func (*StatisticsRequest) Descriptor deprecated

func (*StatisticsRequest) Descriptor() ([]byte, []int)

Deprecated: Use StatisticsRequest.ProtoReflect.Descriptor instead.

func (*StatisticsRequest) ProtoMessage

func (*StatisticsRequest) ProtoMessage()

func (*StatisticsRequest) ProtoReflect

func (x *StatisticsRequest) ProtoReflect() protoreflect.Message

func (*StatisticsRequest) Reset

func (x *StatisticsRequest) Reset()

func (*StatisticsRequest) String

func (x *StatisticsRequest) String() string

func (*StatisticsRequest) Validate

func (this *StatisticsRequest) Validate() error

type StatisticsResponse

type StatisticsResponse struct {
	Statistics *Statistics `protobuf:"bytes,1,opt,name=statistics,proto3" json:"statistics,omitempty"`
	// contains filtered or unexported fields
}

func (*StatisticsResponse) Descriptor deprecated

func (*StatisticsResponse) Descriptor() ([]byte, []int)

Deprecated: Use StatisticsResponse.ProtoReflect.Descriptor instead.

func (*StatisticsResponse) GetStatistics

func (x *StatisticsResponse) GetStatistics() *Statistics

func (*StatisticsResponse) ProtoMessage

func (*StatisticsResponse) ProtoMessage()

func (*StatisticsResponse) ProtoReflect

func (x *StatisticsResponse) ProtoReflect() protoreflect.Message

func (*StatisticsResponse) Reset

func (x *StatisticsResponse) Reset()

func (*StatisticsResponse) String

func (x *StatisticsResponse) String() string

func (*StatisticsResponse) Validate

func (this *StatisticsResponse) Validate() error

type SubmitTransactionV2Request added in v0.38.0

type SubmitTransactionV2Request struct {

	// A bundle of signed payload and signature, to form a transaction that will be submitted to the Vega blockchain
	Tx *v1.Transaction `protobuf:"bytes,1,opt,name=tx,proto3" json:"tx,omitempty"`
	// Type of transaction request, for example ASYNC, meaning the transaction will be submitted and not block on a response
	Type SubmitTransactionV2Request_Type `protobuf:"varint,2,opt,name=type,proto3,enum=api.v1.SubmitTransactionV2Request_Type" json:"type,omitempty"`
	// contains filtered or unexported fields
}

Request for submitting a transaction v2 on Vega

func (*SubmitTransactionV2Request) Descriptor deprecated added in v0.38.0

func (*SubmitTransactionV2Request) Descriptor() ([]byte, []int)

Deprecated: Use SubmitTransactionV2Request.ProtoReflect.Descriptor instead.

func (*SubmitTransactionV2Request) GetTx added in v0.38.0

func (*SubmitTransactionV2Request) GetType added in v0.38.0

func (*SubmitTransactionV2Request) ProtoMessage added in v0.38.0

func (*SubmitTransactionV2Request) ProtoMessage()

func (*SubmitTransactionV2Request) ProtoReflect added in v0.38.0

func (*SubmitTransactionV2Request) Reset added in v0.38.0

func (x *SubmitTransactionV2Request) Reset()

func (*SubmitTransactionV2Request) String added in v0.38.0

func (x *SubmitTransactionV2Request) String() string

func (*SubmitTransactionV2Request) Validate added in v0.38.0

func (this *SubmitTransactionV2Request) Validate() error

type SubmitTransactionV2Request_Type added in v0.38.0

type SubmitTransactionV2Request_Type int32

Blockchain transaction type

const (
	SubmitTransactionV2Request_TYPE_UNSPECIFIED SubmitTransactionV2Request_Type = 0
	// The transaction will be submitted without waiting for response
	SubmitTransactionV2Request_TYPE_ASYNC SubmitTransactionV2Request_Type = 1
	// The transaction will be submitted, and blocking until the
	// tendermint mempool return a response
	SubmitTransactionV2Request_TYPE_SYNC SubmitTransactionV2Request_Type = 2
	// The transaction will submitted, and blocking until the tendermint
	// network will have committed it into a block
	SubmitTransactionV2Request_TYPE_COMMIT SubmitTransactionV2Request_Type = 3
)

func (SubmitTransactionV2Request_Type) Descriptor added in v0.38.0

func (SubmitTransactionV2Request_Type) Enum added in v0.38.0

func (SubmitTransactionV2Request_Type) EnumDescriptor deprecated added in v0.38.0

func (SubmitTransactionV2Request_Type) EnumDescriptor() ([]byte, []int)

Deprecated: Use SubmitTransactionV2Request_Type.Descriptor instead.

func (SubmitTransactionV2Request_Type) Number added in v0.38.0

func (SubmitTransactionV2Request_Type) String added in v0.38.0

func (SubmitTransactionV2Request_Type) Type added in v0.38.0

type SubmitTransactionV2Response added in v0.38.0

type SubmitTransactionV2Response struct {

	// Success will be true if the transaction was accepted by the node,
	// **Important** - success does not mean that the event is confirmed by consensus
	Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
	// contains filtered or unexported fields
}

Response for submitting a transaction v2 on Vega

func (*SubmitTransactionV2Response) Descriptor deprecated added in v0.38.0

func (*SubmitTransactionV2Response) Descriptor() ([]byte, []int)

Deprecated: Use SubmitTransactionV2Response.ProtoReflect.Descriptor instead.

func (*SubmitTransactionV2Response) GetSuccess added in v0.38.0

func (x *SubmitTransactionV2Response) GetSuccess() bool

func (*SubmitTransactionV2Response) ProtoMessage added in v0.38.0

func (*SubmitTransactionV2Response) ProtoMessage()

func (*SubmitTransactionV2Response) ProtoReflect added in v0.38.0

func (*SubmitTransactionV2Response) Reset added in v0.38.0

func (x *SubmitTransactionV2Response) Reset()

func (*SubmitTransactionV2Response) String added in v0.38.0

func (x *SubmitTransactionV2Response) String() string

func (*SubmitTransactionV2Response) Validate added in v0.38.0

func (this *SubmitTransactionV2Response) Validate() error

type TradingServiceClient

type TradingServiceClient interface {
	// Submit a signed transaction (v2)
	SubmitTransactionV2(ctx context.Context, in *SubmitTransactionV2Request, opts ...grpc.CallOption) (*SubmitTransactionV2Response, error)
	// Propagate a chain event
	PropagateChainEvent(ctx context.Context, in *PropagateChainEventRequest, opts ...grpc.CallOption) (*PropagateChainEventResponse, error)
	// Get Statistics on Vega
	Statistics(ctx context.Context, in *StatisticsRequest, opts ...grpc.CallOption) (*StatisticsResponse, error)
	// Get the height of the last tendermint block
	LastBlockHeight(ctx context.Context, in *LastBlockHeightRequest, opts ...grpc.CallOption) (*LastBlockHeightResponse, error)
	// Get Time
	GetVegaTime(ctx context.Context, in *GetVegaTimeRequest, opts ...grpc.CallOption) (*GetVegaTimeResponse, error)
	// Subscribe to a stream of events from the core
	ObserveEventBus(ctx context.Context, opts ...grpc.CallOption) (TradingService_ObserveEventBusClient, error)
}

TradingServiceClient is the client API for TradingService 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.

type TradingServiceServer

type TradingServiceServer interface {
	// Submit a signed transaction (v2)
	SubmitTransactionV2(context.Context, *SubmitTransactionV2Request) (*SubmitTransactionV2Response, error)
	// Propagate a chain event
	PropagateChainEvent(context.Context, *PropagateChainEventRequest) (*PropagateChainEventResponse, error)
	// Get Statistics on Vega
	Statistics(context.Context, *StatisticsRequest) (*StatisticsResponse, error)
	// Get the height of the last tendermint block
	LastBlockHeight(context.Context, *LastBlockHeightRequest) (*LastBlockHeightResponse, error)
	// Get Time
	GetVegaTime(context.Context, *GetVegaTimeRequest) (*GetVegaTimeResponse, error)
	// Subscribe to a stream of events from the core
	ObserveEventBus(TradingService_ObserveEventBusServer) error
	// contains filtered or unexported methods
}

TradingServiceServer is the server API for TradingService service. All implementations must embed UnimplementedTradingServiceServer for forward compatibility

type TradingService_ObserveEventBusClient

type TradingService_ObserveEventBusClient interface {
	Send(*ObserveEventBusRequest) error
	Recv() (*ObserveEventBusResponse, error)
	grpc.ClientStream
}

type TradingService_ObserveEventBusServer

type TradingService_ObserveEventBusServer interface {
	Send(*ObserveEventBusResponse) error
	Recv() (*ObserveEventBusRequest, error)
	grpc.ServerStream
}

type UnimplementedTradingServiceServer

type UnimplementedTradingServiceServer struct {
}

UnimplementedTradingServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedTradingServiceServer) GetVegaTime

func (UnimplementedTradingServiceServer) LastBlockHeight

func (UnimplementedTradingServiceServer) ObserveEventBus

func (UnimplementedTradingServiceServer) PropagateChainEvent

func (UnimplementedTradingServiceServer) Statistics

func (UnimplementedTradingServiceServer) SubmitTransactionV2 added in v0.38.0

type UnsafeTradingServiceServer

type UnsafeTradingServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeTradingServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TradingServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL