rarible

package
v0.179.20 Latest Latest
Warning

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

Go to latest
Published: May 17, 2024 License: MPL-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CollectibleFilterFullTextFieldName        = "NAME"
	CollectibleFilterFullTextFieldDescription = "DESCRIPTION"
)
View Source
const (
	CollectibleFilterContainerSortRelevance = "RELEVANCE"
	CollectibleFilterContainerSortLatest    = "LATEST"
	CollectibleFilterContainerSortEarliest  = "EARLIEST"
)
View Source
const RaribleID = "rarible"

Variables

This section is empty.

Functions

This section is empty.

Types

type Attribute

type Attribute struct {
	Key   string         `json:"key"`
	Value AttributeValue `json:"value"`
}

type AttributeValue

type AttributeValue string

func (*AttributeValue) UnmarshalJSON

func (st *AttributeValue) UnmarshalJSON(b []byte) error

type BatchTokenIDs

type BatchTokenIDs struct {
	IDs []string `json:"ids"`
}

type Client

type Client struct {
	thirdparty.CollectibleContractOwnershipProvider
	// contains filtered or unexported fields
}

func NewClient

func NewClient(mainnetAPIKey string, testnetAPIKey string) *Client

func (*Client) FetchAllAssetsByOwner

func (o *Client) FetchAllAssetsByOwner(ctx context.Context, chainID walletCommon.ChainID, owner common.Address, cursor string, limit int) (*thirdparty.FullCollectibleDataContainer, error)

func (*Client) FetchAllAssetsByOwnerAndContractAddress

func (o *Client) FetchAllAssetsByOwnerAndContractAddress(ctx context.Context, chainID walletCommon.ChainID, owner common.Address, contractAddresses []common.Address, cursor string, limit int) (*thirdparty.FullCollectibleDataContainer, error)

func (*Client) FetchAssetsByCollectibleUniqueID

func (o *Client) FetchAssetsByCollectibleUniqueID(ctx context.Context, uniqueIDs []thirdparty.CollectibleUniqueID) ([]thirdparty.FullCollectibleData, error)

func (*Client) FetchCollectibleOwnersByContractAddress

func (o *Client) FetchCollectibleOwnersByContractAddress(ctx context.Context, chainID walletCommon.ChainID, contractAddress common.Address) (*thirdparty.CollectibleContractOwnership, error)

func (*Client) FetchCollectionSocials added in v0.179.17

func (o *Client) FetchCollectionSocials(ctx context.Context, contractID thirdparty.ContractID) (*thirdparty.CollectionSocials, error)

func (*Client) FetchCollectionsDataByContractID

func (o *Client) FetchCollectionsDataByContractID(ctx context.Context, contractIDs []thirdparty.ContractID) ([]thirdparty.CollectionData, error)

func (*Client) ID

func (o *Client) ID() string

func (*Client) IsChainSupported

func (o *Client) IsChainSupported(chainID walletCommon.ChainID) bool

func (*Client) IsConnected

func (o *Client) IsConnected() bool

func (*Client) SearchCollectibles added in v0.177.0

func (o *Client) SearchCollectibles(ctx context.Context, chainID walletCommon.ChainID, collections []common.Address, text string, cursor string, limit int) (*thirdparty.FullCollectibleDataContainer, error)

func (*Client) SearchCollections added in v0.177.0

func (o *Client) SearchCollections(ctx context.Context, chainID walletCommon.ChainID, text string, cursor string, limit int) (*thirdparty.CollectionDataContainer, error)

type Collectible

type Collectible struct {
	ID         string              `json:"id"`
	Blockchain string              `json:"blockchain"`
	Collection string              `json:"collection"`
	Contract   string              `json:"contract"`
	TokenID    *bigint.BigInt      `json:"tokenId"`
	Metadata   CollectibleMetadata `json:"meta"`
}

type CollectibleFilter added in v0.177.0

type CollectibleFilter struct {
	Blockchains []string                  `json:"blockchains"`
	Collections []string                  `json:"collections,omitempty"`
	Deleted     bool                      `json:"deleted"`
	FullText    CollectibleFilterFullText `json:"fullText"`
}

type CollectibleFilterContainer added in v0.177.0

type CollectibleFilterContainer struct {
	Limit  int                            `json:"size"`
	Cursor string                         `json:"continuation"`
	Filter CollectibleFilter              `json:"filter"`
	Sort   CollectibleFilterContainerSort `json:"sort"`
}

type CollectibleFilterContainerSort added in v0.177.0

type CollectibleFilterContainerSort = string

type CollectibleFilterFullText added in v0.177.0

type CollectibleFilterFullText struct {
	Text   string                           `json:"text"`
	Fields []CollectibleFilterFullTextField `json:"fields"`
}

type CollectibleFilterFullTextField added in v0.177.0

type CollectibleFilterFullTextField = string

type CollectibleMetadata

type CollectibleMetadata struct {
	Name            string      `json:"name"`
	Description     string      `json:"description"`
	ExternalURI     string      `json:"externalUri"`
	OriginalMetaURI string      `json:"originalMetaUri"`
	Attributes      []Attribute `json:"attributes"`
	Contents        []Content   `json:"content"`
}

type CollectiblesContainer

type CollectiblesContainer struct {
	Continuation string        `json:"continuation"`
	Collectibles []Collectible `json:"items"`
}

type Collection

type Collection struct {
	ID           string             `json:"id"`
	Blockchain   string             `json:"blockchain"`
	ContractType string             `json:"type"`
	Name         string             `json:"name"`
	Metadata     CollectionMetadata `json:"meta"`
}

type CollectionFilter added in v0.177.0

type CollectionFilter struct {
	Blockchains []string `json:"blockchains"`
	Text        string   `json:"text"`
}

type CollectionFilterContainer added in v0.177.0

type CollectionFilterContainer struct {
	Limit  int              `json:"size"`
	Cursor string           `json:"continuation"`
	Filter CollectionFilter `json:"filter"`
}

type CollectionMetadata

type CollectionMetadata struct {
	Name        string    `json:"name"`
	Description string    `json:"description"`
	Contents    []Content `json:"content"`
}

type CollectionsContainer added in v0.177.0

type CollectionsContainer struct {
	Continuation string       `json:"continuation"`
	Collections  []Collection `json:"collections"`
}

type Content

type Content struct {
	Type           string `json:"@type"`
	URL            string `json:"url"`
	Representation string `json:"representation"`
	Available      bool   `json:"available"`
}

type ContractOwnership

type ContractOwnership struct {
	ID         string         `json:"id"`
	Blockchain string         `json:"blockchain"`
	ItemID     string         `json:"itemId"`
	Contract   string         `json:"contract"`
	Collection string         `json:"collection"`
	TokenID    *bigint.BigInt `json:"tokenId"`
	Owner      string         `json:"owner"`
	Value      *bigint.BigInt `json:"value"`
}

type ContractOwnershipContainer

type ContractOwnershipContainer struct {
	Continuation string              `json:"continuation"`
	Ownerships   []ContractOwnership `json:"ownerships"`
}

Jump to

Keyboard shortcuts

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