rarible

package
v0.172.7 Latest Latest
Warning

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

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

Documentation

Index

Constants

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) 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

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 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"`
	Name       string             `json:"name"`
	Metadata   CollectionMetadata `json:"meta"`
}

type CollectionMetadata

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

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