seaportv1

package
v0.0.0-...-fce09a9 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Action_name = map[int32]string{
		0:   "ACTION_BUY",
		1:   "ACTION_SELL",
		255: "ACTION_INVALID",
	}
	Action_value = map[string]int32{
		"ACTION_BUY":     0,
		"ACTION_SELL":    1,
		"ACTION_INVALID": 255,
	}
)

Enum value maps for Action.

View Source
var (
	ItemType_name = map[int32]string{
		0: "ITEM_TYPE_NATIVE",
		1: "ITEM_TYPE_ERC20",
		2: "ITEM_TYPE_ERC721",
		3: "ITEM_TYPE_ERC1155",
		4: "ITEM_TYPE_ERC721_WITH_CRITERIA",
		5: "ITEM_TYPE_ERC1155_WITH_CRITERIA",
	}
	ItemType_value = map[string]int32{
		"ITEM_TYPE_NATIVE":                0,
		"ITEM_TYPE_ERC20":                 1,
		"ITEM_TYPE_ERC721":                2,
		"ITEM_TYPE_ERC1155":               3,
		"ITEM_TYPE_ERC721_WITH_CRITERIA":  4,
		"ITEM_TYPE_ERC1155_WITH_CRITERIA": 5,
	}
)

Enum value maps for ItemType.

View Source
var (
	OrderType_name = map[int32]string{
		0: "ORDER_TYPE_FULL_OPEN",
		1: "ORDER_TYPE_PARTIAL_OPEN",
		2: "ORDER_TYPE_FULL_RESTRICTED",
		3: "ORDER_TYPE_PARTIAL_RESTRICTED",
	}
	OrderType_value = map[string]int32{
		"ORDER_TYPE_FULL_OPEN":          0,
		"ORDER_TYPE_PARTIAL_OPEN":       1,
		"ORDER_TYPE_FULL_RESTRICTED":    2,
		"ORDER_TYPE_PARTIAL_RESTRICTED": 3,
	}
)

Enum value maps for OrderType.

View Source
var File_proto_seaport_v1_auth_proto protoreflect.FileDescriptor
View Source
var File_proto_seaport_v1_fees_proto protoreflect.FileDescriptor
View Source
var File_proto_seaport_v1_rfq_proto protoreflect.FileDescriptor
View Source
var File_proto_seaport_v1_seaport_proto protoreflect.FileDescriptor
View Source
var File_proto_seaport_v1_types_proto protoreflect.FileDescriptor

Functions

func MarshalProto

func MarshalProto(message any) ([]byte, error)

MarshalProto will serialize a given protobuf based struct to bytes

func MustGenRandomAddress

func MustGenRandomAddress(t *testing.T) (*ecdsa.PrivateKey, common.Address)

Types

type Action

type Action int32

* The Action enum specifies whether the taker is requesting a quote to buy or sell an asset.

const (
	Action_ACTION_BUY     Action = 0
	Action_ACTION_SELL    Action = 1
	Action_ACTION_INVALID Action = 255
)

func (Action) Descriptor

func (Action) Descriptor() protoreflect.EnumDescriptor

func (Action) Enum

func (x Action) Enum() *Action

func (Action) EnumDescriptor deprecated

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

Deprecated: Use Action.Descriptor instead.

func (Action) Number

func (x Action) Number() protoreflect.EnumNumber

func (Action) String

func (x Action) String() string

func (Action) Type

func (Action) Type() protoreflect.EnumType

type ConsiderationItem

type ConsiderationItem struct {
	ItemType             ItemType `protobuf:"varint,1,opt,name=item_type,json=itemType,proto3,enum=proto.seaport.v1.ItemType" json:"item_type,omitempty"`
	Token                *H160    `protobuf:"bytes,2,opt,name=token,proto3" json:"token,omitempty"`
	IdentifierOrCriteria *H256    `protobuf:"bytes,3,opt,name=identifier_or_criteria,json=identifierOrCriteria,proto3" json:"identifier_or_criteria,omitempty"` // uint256
	StartAmount          *H256    `protobuf:"bytes,4,opt,name=start_amount,json=startAmount,proto3" json:"start_amount,omitempty"`                              // uint256
	EndAmount            *H256    `protobuf:"bytes,5,opt,name=end_amount,json=endAmount,proto3" json:"end_amount,omitempty"`                                    // uint256
	Recipient            *H160    `protobuf:"bytes,6,opt,name=recipient,proto3" json:"recipient,omitempty"`
	// contains filtered or unexported fields
}

* This is and item required in exchange for an offer.

func (*ConsiderationItem) Descriptor deprecated

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

Deprecated: Use ConsiderationItem.ProtoReflect.Descriptor instead.

func (*ConsiderationItem) GetEndAmount

func (x *ConsiderationItem) GetEndAmount() *H256

func (*ConsiderationItem) GetIdentifierOrCriteria

func (x *ConsiderationItem) GetIdentifierOrCriteria() *H256

func (*ConsiderationItem) GetItemType

func (x *ConsiderationItem) GetItemType() ItemType

func (*ConsiderationItem) GetRecipient

func (x *ConsiderationItem) GetRecipient() *H160

func (*ConsiderationItem) GetStartAmount

func (x *ConsiderationItem) GetStartAmount() *H256

func (*ConsiderationItem) GetToken

func (x *ConsiderationItem) GetToken() *H160

func (*ConsiderationItem) ProtoMessage

func (*ConsiderationItem) ProtoMessage()

func (*ConsiderationItem) ProtoReflect

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

func (*ConsiderationItem) Reset

func (x *ConsiderationItem) Reset()

func (*ConsiderationItem) String

func (x *ConsiderationItem) String() string

type Empty

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

* The empty message

func (*Empty) Descriptor deprecated

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

Deprecated: Use Empty.ProtoReflect.Descriptor instead.

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) ProtoReflect

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

func (*Empty) Reset

func (x *Empty) Reset()

func (*Empty) String

func (x *Empty) String() string

type EthSignature

type EthSignature struct {
	R []byte `protobuf:"bytes,1,opt,name=r,proto3" json:"r,omitempty"`
	S []byte `protobuf:"bytes,2,opt,name=s,proto3" json:"s,omitempty"`
	V []byte `protobuf:"bytes,3,opt,name=v,proto3" json:"v,omitempty"`
	// contains filtered or unexported fields
}

ECDSA signatures in Ethereum consist of three parameters: v, r and s. The signature is always 65-bytes in length.

r = first 32 bytes of signature
s = second 32 bytes of signature
v = final 1 byte of signature

Since protobuf doesn't support uint8, we use a boolean for v, which is always 8 bits.

func (*EthSignature) Descriptor deprecated

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

Deprecated: Use EthSignature.ProtoReflect.Descriptor instead.

func (*EthSignature) GetR

func (x *EthSignature) GetR() []byte

func (*EthSignature) GetS

func (x *EthSignature) GetS() []byte

func (*EthSignature) GetV

func (x *EthSignature) GetV() []byte

func (*EthSignature) ProtoMessage

func (*EthSignature) ProtoMessage()

func (*EthSignature) ProtoReflect

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

func (*EthSignature) Reset

func (x *EthSignature) Reset()

func (*EthSignature) String

func (x *EthSignature) String() string

type FeeStructure

type FeeStructure struct {
	Maker *TradeFees `protobuf:"bytes,1,opt,name=maker,proto3" json:"maker,omitempty"`
	Taker *TradeFees `protobuf:"bytes,2,opt,name=taker,proto3" json:"taker,omitempty"`
	// A fee or rebate on notional value written via Clear expressed in basis points.
	ClearWriteNotionalBps int32 `` /* 129-byte string literal not displayed */
	// A fee or rebate on underlying asset notional value redeemed via Clear expressed in basis points.
	ClearRedeemedNotionalBps int32 `` /* 138-byte string literal not displayed */
	// A fee or rebate on notional value exercised via Clear expressed in basis points.
	ClearExerciseNotionalBps int32 `` /* 138-byte string literal not displayed */
	// The address fees must be paid to or rebates are received from.
	Address *H160 `protobuf:"bytes,6,opt,name=address,proto3" json:"address,omitempty"`
	// contains filtered or unexported fields
}

func (*FeeStructure) Descriptor deprecated

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

Deprecated: Use FeeStructure.ProtoReflect.Descriptor instead.

func (*FeeStructure) GetAddress

func (x *FeeStructure) GetAddress() *H160

func (*FeeStructure) GetClearExerciseNotionalBps

func (x *FeeStructure) GetClearExerciseNotionalBps() int32

func (*FeeStructure) GetClearRedeemedNotionalBps

func (x *FeeStructure) GetClearRedeemedNotionalBps() int32

func (*FeeStructure) GetClearWriteNotionalBps

func (x *FeeStructure) GetClearWriteNotionalBps() int32

func (*FeeStructure) GetMaker

func (x *FeeStructure) GetMaker() *TradeFees

func (*FeeStructure) GetTaker

func (x *FeeStructure) GetTaker() *TradeFees

func (*FeeStructure) ProtoMessage

func (*FeeStructure) ProtoMessage()

func (*FeeStructure) ProtoReflect

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

func (*FeeStructure) Reset

func (x *FeeStructure) Reset()

func (*FeeStructure) String

func (x *FeeStructure) String() string

type H128

type H128 struct {
	Hi uint64 `protobuf:"varint,1,opt,name=hi,proto3" json:"hi,omitempty"`
	Lo uint64 `protobuf:"varint,2,opt,name=lo,proto3" json:"lo,omitempty"`
	// contains filtered or unexported fields
}

func (*H128) Descriptor deprecated

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

Deprecated: Use H128.ProtoReflect.Descriptor instead.

func (*H128) GetHi

func (x *H128) GetHi() uint64

func (*H128) GetLo

func (x *H128) GetLo() uint64

func (*H128) ProtoMessage

func (*H128) ProtoMessage()

func (*H128) ProtoReflect

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

func (*H128) Reset

func (x *H128) Reset()

func (*H128) String

func (x *H128) String() string

type H160

type H160 struct {
	Hi *H128  `protobuf:"bytes,1,opt,name=hi,proto3" json:"hi,omitempty"`
	Lo uint32 `protobuf:"varint,2,opt,name=lo,proto3" json:"lo,omitempty"`
	// contains filtered or unexported fields
}

func AddressToH160

func AddressToH160(address common.Address) *H160

AddressToH160 converts an ecdsa.PublicKey address to a v1.H160

func MustGenRandomH160

func MustGenRandomH160(t *testing.T) (*ecdsa.PrivateKey, *H160)

func (*H160) Descriptor deprecated

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

Deprecated: Use H160.ProtoReflect.Descriptor instead.

func (*H160) GetHi

func (x *H160) GetHi() *H128

func (*H160) GetLo

func (x *H160) GetLo() uint32

func (*H160) ProtoMessage

func (*H160) ProtoMessage()

func (*H160) ProtoReflect

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

func (*H160) Reset

func (x *H160) Reset()

func (*H160) String

func (x *H160) String() string

func (*H160) ToAddress

func (h160 *H160) ToAddress() common.Address

ToAddress converts a H160 to an ethereum address

type H256

type H256 struct {
	Hi *H128 `protobuf:"bytes,1,opt,name=hi,proto3" json:"hi,omitempty"`
	Lo *H128 `protobuf:"bytes,2,opt,name=lo,proto3" json:"lo,omitempty"`
	// contains filtered or unexported fields
}

func (*H256) Descriptor deprecated

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

Deprecated: Use H256.ProtoReflect.Descriptor instead.

func (*H256) GetHi

func (x *H256) GetHi() *H128

func (*H256) GetLo

func (x *H256) GetLo() *H128

func (*H256) ProtoMessage

func (*H256) ProtoMessage()

func (*H256) ProtoReflect

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

func (*H256) Reset

func (x *H256) Reset()

func (*H256) String

func (x *H256) String() string

type H40

type H40 struct {
	Hi uint32 `protobuf:"varint,1,opt,name=hi,proto3" json:"hi,omitempty"`
	// Note: lo is really a uint8, however the closest type in Protocol Buffers is uint32. Parsing needs
	//
	//	to take this into consideration.
	Lo uint32 `protobuf:"varint,2,opt,name=lo,proto3" json:"lo,omitempty"`
	// contains filtered or unexported fields
}

func (*H40) Descriptor deprecated

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

Deprecated: Use H40.ProtoReflect.Descriptor instead.

func (*H40) GetHi

func (x *H40) GetHi() uint32

func (*H40) GetLo

func (x *H40) GetLo() uint32

func (*H40) ProtoMessage

func (*H40) ProtoMessage()

func (*H40) ProtoReflect

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

func (*H40) Reset

func (x *H40) Reset()

func (*H40) String

func (x *H40) String() string

type H96

type H96 struct {
	Hi uint64 `protobuf:"varint,1,opt,name=hi,proto3" json:"hi,omitempty"`
	Lo uint32 `protobuf:"varint,2,opt,name=lo,proto3" json:"lo,omitempty"`
	// contains filtered or unexported fields
}

func (*H96) Descriptor deprecated

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

Deprecated: Use H96.ProtoReflect.Descriptor instead.

func (*H96) GetHi

func (x *H96) GetHi() uint64

func (*H96) GetLo

func (x *H96) GetLo() uint32

func (*H96) ProtoMessage

func (*H96) ProtoMessage()

func (*H96) ProtoReflect

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

func (*H96) Reset

func (x *H96) Reset()

func (*H96) String

func (x *H96) String() string

type ItemType

type ItemType int32

* The ItemType designates the type of item, with valid types being Ether (or other native token for the given chain), ERC20, ERC721, ERC1155, ERC721 with "criteria" (explained below), and ERC1155 with criteria.

const (
	ItemType_ITEM_TYPE_NATIVE                ItemType = 0
	ItemType_ITEM_TYPE_ERC20                 ItemType = 1
	ItemType_ITEM_TYPE_ERC721                ItemType = 2
	ItemType_ITEM_TYPE_ERC1155               ItemType = 3
	ItemType_ITEM_TYPE_ERC721_WITH_CRITERIA  ItemType = 4
	ItemType_ITEM_TYPE_ERC1155_WITH_CRITERIA ItemType = 5
)

func (ItemType) Descriptor

func (ItemType) Descriptor() protoreflect.EnumDescriptor

func (ItemType) Enum

func (x ItemType) Enum() *ItemType

func (ItemType) EnumDescriptor deprecated

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

Deprecated: Use ItemType.Descriptor instead.

func (ItemType) Number

func (x ItemType) Number() protoreflect.EnumNumber

func (ItemType) String

func (x ItemType) String() string

func (ItemType) Type

type NonceResponse

type NonceResponse struct {
	Nonce string `protobuf:"bytes,1,opt,name=nonce,proto3" json:"nonce,omitempty"`
	// contains filtered or unexported fields
}

* Nonce response message containing the generated `nonce` string.

func (*NonceResponse) Descriptor deprecated

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

Deprecated: Use NonceResponse.ProtoReflect.Descriptor instead.

func (*NonceResponse) GetNonce

func (x *NonceResponse) GetNonce() string

func (*NonceResponse) ProtoMessage

func (*NonceResponse) ProtoMessage()

func (*NonceResponse) ProtoReflect

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

func (*NonceResponse) Reset

func (x *NonceResponse) Reset()

func (*NonceResponse) String

func (x *NonceResponse) String() string

type OfferItem

type OfferItem struct {
	ItemType ItemType `protobuf:"varint,1,opt,name=item_type,json=itemType,proto3,enum=proto.seaport.v1.ItemType" json:"item_type,omitempty"`
	// * The token designates the account of the item's token contract
	// (with the null address used for Ether or other native tokens).
	Token *H160 `protobuf:"bytes,2,opt,name=token,proto3" json:"token,omitempty"`
	// * The identifier_or_criteria represents either the ERC721 or ERC1155
	// token identifier or, in the case of a criteria-based item type, a
	// merkle root composed of the valid set of token identifiers for
	// the item. This value will be ignored for Ether and ERC20 item types,
	// and can optionally be zero for criteria-based item types to allow
	// for any identifier.
	IdentifierOrCriteria *H256 `protobuf:"bytes,3,opt,name=identifier_or_criteria,json=identifierOrCriteria,proto3" json:"identifier_or_criteria,omitempty"`
	// * The start_amount represents the amount of the item in question that
	// will be required should the order be fulfilled at the moment the
	// order becomes active.
	StartAmount *H256 `protobuf:"bytes,4,opt,name=start_amount,json=startAmount,proto3" json:"start_amount,omitempty"`
	// * The end_amount represents the amount of the item in question that
	// will be required should the order be fulfilled at the moment the
	// order expires. If this value differs from the item's start_amount,
	// the realized amount is calculated linearly based on the time elapsed
	// since the order became active.
	EndAmount *H256 `protobuf:"bytes,5,opt,name=end_amount,json=endAmount,proto3" json:"end_amount,omitempty"` // uint256
	// contains filtered or unexported fields
}

* This is an item offered in exchange for consideration.

func (*OfferItem) Descriptor deprecated

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

Deprecated: Use OfferItem.ProtoReflect.Descriptor instead.

func (*OfferItem) GetEndAmount

func (x *OfferItem) GetEndAmount() *H256

func (*OfferItem) GetIdentifierOrCriteria

func (x *OfferItem) GetIdentifierOrCriteria() *H256

func (*OfferItem) GetItemType

func (x *OfferItem) GetItemType() ItemType

func (*OfferItem) GetStartAmount

func (x *OfferItem) GetStartAmount() *H256

func (*OfferItem) GetToken

func (x *OfferItem) GetToken() *H160

func (*OfferItem) ProtoMessage

func (*OfferItem) ProtoMessage()

func (*OfferItem) ProtoReflect

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

func (*OfferItem) Reset

func (x *OfferItem) Reset()

func (*OfferItem) String

func (x *OfferItem) String() string

type Order

type Order struct {

	// * The offerer of the order supplies all offered items and must either
	// fulfill the order personally (i.e. msg.sender == offerer) or approve
	// the order via signature (either standard 65-byte EDCSA, 64-byte
	// EIP-2098, or an EIP-1271 isValidSignature check) or by listing
	// the order on-chain (i.e. calling validate).
	Offerer *H160 `protobuf:"bytes,1,opt,name=offerer,proto3" json:"offerer,omitempty"`
	// * The zone of the order is an optional secondary account attached to the
	// order with two additional privileges:
	//
	// The zone may cancel orders where it is named as the zone by calling
	// cancel. (Note that offerers can also cancel their own orders, either
	// individually or for all orders signed with their current counter at
	// once by calling incrementCounter).
	// "Restricted" orders (as specified by the order type) must either be
	// executed by the zone or the offerer, or must be approved as indicated
	// by a call to an validateOrder on the zone.
	Zone *H160 `protobuf:"bytes,2,opt,name=zone,proto3" json:"zone,omitempty"`
	// * The offers array contains an array of items that may be transferred
	// from the offerer's account.
	Offer []*OfferItem `protobuf:"bytes,3,rep,name=offer,proto3" json:"offer,omitempty"`
	// * The consideration contains an array of items that must be received
	// in order to fulfill the order. It contains all of the same components
	// as an offered item, and additionally includes a recipient that will
	// receive each item. This array may be extended by the fulfiller on
	// order fulfillment so as to support "tipping" (e.g. relayer or
	// referral payments)
	Consideration []*ConsiderationItem `protobuf:"bytes,4,rep,name=consideration,proto3" json:"consideration,omitempty"`
	OrderType     OrderType            `protobuf:"varint,5,opt,name=order_type,json=orderType,proto3,enum=proto.seaport.v1.OrderType" json:"order_type,omitempty"`
	// * The start_time indicates the block timestamp at which the order
	// becomes active.
	StartTime *H256 `protobuf:"bytes,6,opt,name=start_time,json=startTime,proto3" json:"start_time,omitempty"`
	// * The end_time indicates the block timestamp at which the order expires.
	// This value and the startTime are used in conjunction with the
	// start_amount and end_amount of each item to derive their current amount.
	EndTime *H256 `protobuf:"bytes,7,opt,name=end_time,json=endTime,proto3" json:"end_time,omitempty"`
	// * The zoneHash represents an arbitrary 32-byte value that will be
	// supplied to the zone when fulfilling restricted orders that the zone
	// can utilize when making a determination on whether to authorize the order.
	ZoneHash *H256 `protobuf:"bytes,8,opt,name=zone_hash,json=zoneHash,proto3" json:"zone_hash,omitempty"`
	// * The salt represents an arbitrary source of entropy for the order.
	Salt *H256 `protobuf:"bytes,9,opt,name=salt,proto3" json:"salt,omitempty"`
	// * The conduit_key is a bytes32 value that indicates what conduit,
	// if any, should be utilized as a source for token approvals when
	// performing transfers. By default (i.e. when conduitKey is set to the
	// zero hash), the offerer will grant ERC20, ERC721, and ERC1155 token
	// approvals to Seaport directly so that it can perform any transfers
	// specified by the order during fulfillment. In contrast, an offerer
	// that elects to utilize a conduit will grant token approvals to the
	// conduit contract corresponding to the supplied conduit key, and
	// Seaport will then instruct that conduit to transfer the respective
	// tokens.
	ConduitKey *H256 `protobuf:"bytes,10,opt,name=conduit_key,json=conduitKey,proto3" json:"conduit_key,omitempty"`
	// contains filtered or unexported fields
}

* Each order contains ten key components

func (*Order) Descriptor deprecated

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

Deprecated: Use Order.ProtoReflect.Descriptor instead.

func (*Order) GetConduitKey

func (x *Order) GetConduitKey() *H256

func (*Order) GetConsideration

func (x *Order) GetConsideration() []*ConsiderationItem

func (*Order) GetEndTime

func (x *Order) GetEndTime() *H256

func (*Order) GetOffer

func (x *Order) GetOffer() []*OfferItem

func (*Order) GetOfferer

func (x *Order) GetOfferer() *H160

func (*Order) GetOrderType

func (x *Order) GetOrderType() OrderType

func (*Order) GetSalt

func (x *Order) GetSalt() *H256

func (*Order) GetStartTime

func (x *Order) GetStartTime() *H256

func (*Order) GetZone

func (x *Order) GetZone() *H160

func (*Order) GetZoneHash

func (x *Order) GetZoneHash() *H256

func (*Order) ProtoMessage

func (*Order) ProtoMessage()

func (*Order) ProtoReflect

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

func (*Order) Reset

func (x *Order) Reset()

func (*Order) String

func (x *Order) String() string

type OrderType

type OrderType int32

* The OrderType designates one of four types for the order depending on two distinct preferences:

FULL indicates that the order does not support partial fills, whereas PARTIAL enables filling some fraction of the order, with the important caveat that each item must be cleanly divisible by the supplied fraction (i.e. no remainder after division).

OPEN indicates that the call to execute the order can be submitted by any account, whereas RESTRICTED requires that the order either be executed by the offerer or the zone of the order, or that a magic value indicating that the order is approved is returned upon calling validateOrder on the zone.

const (
	OrderType_ORDER_TYPE_FULL_OPEN          OrderType = 0
	OrderType_ORDER_TYPE_PARTIAL_OPEN       OrderType = 1
	OrderType_ORDER_TYPE_FULL_RESTRICTED    OrderType = 2
	OrderType_ORDER_TYPE_PARTIAL_RESTRICTED OrderType = 3
)

func (OrderType) Descriptor

func (OrderType) Descriptor() protoreflect.EnumDescriptor

func (OrderType) Enum

func (x OrderType) Enum() *OrderType

func (OrderType) EnumDescriptor deprecated

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

Deprecated: Use OrderType.Descriptor instead.

func (OrderType) Number

func (x OrderType) Number() protoreflect.EnumNumber

func (OrderType) String

func (x OrderType) String() string

func (OrderType) Type

type QuoteRequest

type QuoteRequest struct {

	// * The unique identifier for the quote request. This is used to match the
	// quote response to the quote request.
	Ulid *H128 `protobuf:"bytes,1,opt,name=ulid,proto3,oneof" json:"ulid,omitempty"`
	// * Ideally the maker would never know who the taker is, and vice-versa.
	// However, seaport reveals the makers' address to the taker.
	// takerAddress ensures there is no information asymmetry between
	// the maker and taker. Thought the trader may not always end up being
	// the taker.
	TakerAddress *H160    `protobuf:"bytes,2,opt,name=taker_address,json=takerAddress,proto3,oneof" json:"taker_address,omitempty"`
	ItemType     ItemType `protobuf:"varint,3,opt,name=item_type,json=itemType,proto3,enum=proto.seaport.v1.ItemType" json:"item_type,omitempty"`
	// The token address for which a quote is being requested.
	TokenAddress *H160 `protobuf:"bytes,4,opt,name=token_address,json=tokenAddress,proto3,oneof" json:"token_address,omitempty"`
	// * The identifier_or_criteria represents either the ERC721 or ERC1155
	// token identifier or, in the case of a criteria-based item type, a
	// merkle root composed of the valid set of token identifiers for
	// the item. This value will be ignored for Ether and ERC20 item types,
	// and can optionally be zero for criteria-based item types to allow
	// for any identifier.
	IdentifierOrCriteria *H256 `` /* 129-byte string literal not displayed */
	Amount               *H256 `protobuf:"bytes,6,opt,name=amount,proto3" json:"amount,omitempty"`
	// * A request by the Taker to the Maker, i.e. if the request is Buy the Taker wants to buy the option from the
	// Maker, whereas Sell is the Taker wanting to sell to the Maker.
	Action Action `protobuf:"varint,7,opt,name=action,proto3,enum=proto.seaport.v1.Action" json:"action,omitempty"`
	// The EIP-155 chain_id for the chain for which the quote is requested.
	ChainId *H256 `protobuf:"bytes,8,opt,name=chain_id,json=chainId,proto3,oneof" json:"chain_id,omitempty"`
	// The address of the seaport contract for which the quote is requested.
	SeaportAddress *H160 `protobuf:"bytes,9,opt,name=seaport_address,json=seaportAddress,proto3,oneof" json:"seaport_address,omitempty"`
	// contains filtered or unexported fields
}

* The fields comprising the quote request message give the maker what they need to provide a quote/signed offer.

func (*QuoteRequest) Descriptor deprecated

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

Deprecated: Use QuoteRequest.ProtoReflect.Descriptor instead.

func (*QuoteRequest) GetAction

func (x *QuoteRequest) GetAction() Action

func (*QuoteRequest) GetAmount

func (x *QuoteRequest) GetAmount() *H256

func (*QuoteRequest) GetChainId

func (x *QuoteRequest) GetChainId() *H256

func (*QuoteRequest) GetIdentifierOrCriteria

func (x *QuoteRequest) GetIdentifierOrCriteria() *H256

func (*QuoteRequest) GetItemType

func (x *QuoteRequest) GetItemType() ItemType

func (*QuoteRequest) GetSeaportAddress

func (x *QuoteRequest) GetSeaportAddress() *H160

func (*QuoteRequest) GetTakerAddress

func (x *QuoteRequest) GetTakerAddress() *H160

func (*QuoteRequest) GetTokenAddress

func (x *QuoteRequest) GetTokenAddress() *H160

func (*QuoteRequest) GetUlid

func (x *QuoteRequest) GetUlid() *H128

func (*QuoteRequest) ProtoMessage

func (*QuoteRequest) ProtoMessage()

func (*QuoteRequest) ProtoReflect

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

func (*QuoteRequest) Reset

func (x *QuoteRequest) Reset()

func (*QuoteRequest) String

func (x *QuoteRequest) String() string

type QuoteResponse

type QuoteResponse struct {

	// * The unique identifier for the quote request. This is used to match the
	// quote response to the quote request.
	Ulid *H128 `protobuf:"bytes,1,opt,name=ulid,proto3,oneof" json:"ulid,omitempty"`
	// * The address of the maker making the offer.
	MakerAddress *H160 `protobuf:"bytes,2,opt,name=maker_address,json=makerAddress,proto3,oneof" json:"maker_address,omitempty"`
	// * The order and signature from the maker.
	Order *SignedOrder `protobuf:"bytes,3,opt,name=order,proto3" json:"order,omitempty"`
	// The EIP-155 chain_id for the chain for which the offer was signed.
	ChainId *H256 `protobuf:"bytes,4,opt,name=chain_id,json=chainId,proto3,oneof" json:"chain_id,omitempty"`
	// The address of the seaport contract for which the offer was signed.
	SeaportAddress *H160 `protobuf:"bytes,5,opt,name=seaport_address,json=seaportAddress,proto3,oneof" json:"seaport_address,omitempty"`
	// contains filtered or unexported fields
}

The quote response message contains the quote/signed offer from the maker.

func (*QuoteResponse) Descriptor deprecated

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

Deprecated: Use QuoteResponse.ProtoReflect.Descriptor instead.

func (*QuoteResponse) GetChainId

func (x *QuoteResponse) GetChainId() *H256

func (*QuoteResponse) GetMakerAddress

func (x *QuoteResponse) GetMakerAddress() *H160

func (*QuoteResponse) GetOrder

func (x *QuoteResponse) GetOrder() *SignedOrder

func (*QuoteResponse) GetSeaportAddress

func (x *QuoteResponse) GetSeaportAddress() *H160

func (*QuoteResponse) GetUlid

func (x *QuoteResponse) GetUlid() *H128

func (*QuoteResponse) ProtoMessage

func (*QuoteResponse) ProtoMessage()

func (*QuoteResponse) ProtoReflect

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

func (*QuoteResponse) Reset

func (x *QuoteResponse) Reset()

func (*QuoteResponse) String

func (x *QuoteResponse) String() string

type SignedOrder

type SignedOrder struct {
	Parameters *Order        `protobuf:"bytes,1,opt,name=parameters,proto3" json:"parameters,omitempty"`
	Signature  *EthSignature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"`
	// contains filtered or unexported fields
}

func (*SignedOrder) Descriptor deprecated

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

Deprecated: Use SignedOrder.ProtoReflect.Descriptor instead.

func (*SignedOrder) GetParameters

func (x *SignedOrder) GetParameters() *Order

func (*SignedOrder) GetSignature

func (x *SignedOrder) GetSignature() *EthSignature

func (*SignedOrder) ProtoMessage

func (*SignedOrder) ProtoMessage()

func (*SignedOrder) ProtoReflect

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

func (*SignedOrder) Reset

func (x *SignedOrder) Reset()

func (*SignedOrder) String

func (x *SignedOrder) String() string

type TradeFees

type TradeFees struct {

	// A fee or rebate on notional value traded expressed in basis points.
	NotionalBps int32 `protobuf:"varint,1,opt,name=notional_bps,json=notionalBps,proto3" json:"notional_bps,omitempty"`
	// A fee or rebate on premia or credit value traded expressed in basis points.
	PremiumBps int32 `protobuf:"varint,2,opt,name=premium_bps,json=premiumBps,proto3" json:"premium_bps,omitempty"`
	// A fee or rebate on spot value traded expressed in basis points.
	SpotBps int32 `protobuf:"varint,3,opt,name=spot_bps,json=spotBps,proto3" json:"spot_bps,omitempty"`
	// A flat relayer fee or rebate expressed in 1e-6 USDC (dust)g - used for non-valued offers/considerations
	// such as NFTs.
	Flat int32 `protobuf:"varint,4,opt,name=flat,proto3" json:"flat,omitempty"`
	// contains filtered or unexported fields
}

func (*TradeFees) Descriptor deprecated

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

Deprecated: Use TradeFees.ProtoReflect.Descriptor instead.

func (*TradeFees) GetFlat

func (x *TradeFees) GetFlat() int32

func (*TradeFees) GetNotionalBps

func (x *TradeFees) GetNotionalBps() int32

func (*TradeFees) GetPremiumBps

func (x *TradeFees) GetPremiumBps() int32

func (*TradeFees) GetSpotBps

func (x *TradeFees) GetSpotBps() int32

func (*TradeFees) ProtoMessage

func (*TradeFees) ProtoMessage()

func (*TradeFees) ProtoReflect

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

func (*TradeFees) Reset

func (x *TradeFees) Reset()

func (*TradeFees) String

func (x *TradeFees) String() string

type VerifyRequest

type VerifyRequest struct {
	Message   string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	Signature string `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"`
	// contains filtered or unexported fields
}

* Verify request message containing the message & signature from a SIWE challenge.

func (*VerifyRequest) Descriptor deprecated

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

Deprecated: Use VerifyRequest.ProtoReflect.Descriptor instead.

func (*VerifyRequest) GetMessage

func (x *VerifyRequest) GetMessage() string

func (*VerifyRequest) GetSignature

func (x *VerifyRequest) GetSignature() string

func (*VerifyRequest) ProtoMessage

func (*VerifyRequest) ProtoMessage()

func (*VerifyRequest) ProtoReflect

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

func (*VerifyRequest) Reset

func (x *VerifyRequest) Reset()

func (*VerifyRequest) String

func (x *VerifyRequest) String() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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