gf_nft

package
v0.0.0-...-0e512e9 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2024 License: GPL-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DBmongoCreateBulkAlchemyNFTs

func DBmongoCreateBulkAlchemyNFTs(pNFTsLst []*gf_nft_extern_services.GFnftAlchemy,
	pMetrics *GFmetrics,
	pCtx context.Context,
	pRuntimeSys *gf_core.RuntimeSys) *gf_core.GFerror

func DBmongoCreateBulkNFTs

func DBmongoCreateBulkNFTs(pNFTsLst []*GFnft,
	pMetrics *GFmetrics,
	pCtx context.Context,
	pRuntimeSys *gf_core.RuntimeSys) *gf_core.GFerror

func DBmongoUpdateGFimageProps

func DBmongoUpdateGFimageProps(pNFTid gf_core.GF_ID,
	pGFimageID gf_images_core.GFimageID,
	pGFimageThumbURLstr *string,
	pCtx context.Context,
	pRuntimeSys *gf_core.RuntimeSys) *gf_core.GFerror

func InitHandlers

func InitHandlers(pKeyServer *gf_identity_core.GFkeyServerInfo,
	pHTTPmux *http.ServeMux,
	pConfig *gf_eth_core.GF_config,
	pImagesJobsMngrCh chan gf_images_jobs_core.JobMsg,
	pRuntimeSys *gf_core.RuntimeSys) *gf_core.GFerror

func TgetByOwner

func TgetByOwner(pAddressStr string,
	pChainStr string,
	pCookiesLst []*http.Cookie,
	pHTTPagent *gorequest.SuperAgent,
	pTestPortInt int,
	pTest *testing.T)

func TindexAddress

func TindexAddress(pAddressStr string,
	pChainStr string,
	pCookiesLst []*http.Cookie,
	pHTTPagent *gorequest.SuperAgent,
	pTestPortInt int,
	pTest *testing.T)

Types

type GFgetByOwnerInput

type GFgetByOwnerInput struct {
	UserID     gf_core.GF_ID
	AddressStr string
	ChainStr   string
}

type GFgetInput

type GFgetInput struct {
	UserID            gf_core.GF_ID
	TokenIDstr        string
	CollectionNameStr string
}

type GFindexAddressInput

type GFindexAddressInput struct {
	UserID     gf_core.GF_ID
	AddressStr string
	ChainStr   string

	// if a specific NFT fetcher should be used (perhaps one
	// thats not included by the OS gloflow core)
	FetcherNameStr string
}

type GFmetrics

type GFmetrics struct {
	NftDBinsertsCount        prometheus.Counter
	NftAlchemyDBinsertsCount prometheus.Counter
}

func MetricsCreate

func MetricsCreate() *GFmetrics

type GFnft

type GFnft struct {
	Vstr              string             `bson:"v_str"` // schema_version
	Id                primitive.ObjectID `bson:"_id,omitempty"`
	IDstr             gf_core.GF_ID      `bson:"id_str"`
	DeletedBool       bool               `bson:"deleted_bool"`
	CreationUNIXtimeF float64            `bson:"creation_unix_time_f"`

	OwnerAddressStr    string `bson:"owner_address_str"`
	TokenIDstr         string `bson:"token_id_str"`
	ContractAddressStr string `bson:"contract_address_str"`
	ContractNameStr    string `bson:"contract_name_str"`
	ChainStr           string `bson:"chain_str"`

	// URIs
	TokenURIrawStr string `bson:"token_uri_raw_str"`
	MediaURIrawStr string `bson:"media_uri_raw_str"`

	// GATEWAY_URIs
	TokenURIgatewayStr string `bson:"token_uri_gateway_str"`
	MediaURIgatewayStr string `bson:"media_uri_gateway_str"`

	GFimageID          gf_images_core.GFimageID `bson:"gf_image_id_str"`
	GFimageThumbURLstr string                   `bson:"gf_image_thumb_url_str"`

	OpenSeaIDstr gf_core.GF_ID `bson:"open_sea_id_str"`
	AlchemyIDstr gf_core.GF_ID `bson:"alchemy_id_str"`
}

func DBmongoGetByOwner

func DBmongoGetByOwner(pAddressStr string,
	pChainStr string,
	pCtx context.Context,
	pRuntimeSys *gf_core.RuntimeSys) ([]*GFnft, *gf_core.GFerror)

type GFnftExtern

type GFnftExtern struct {
	OwnerAddressStr    string `json:"owner_address_str"`
	TokenIDstr         string `json:"token_id_str"`
	ContractAddressStr string `json:"contract_address_str"`
	ContractNameStr    string `json:"contract_name_str"`
	ChainStr           string `json:"chain_str"`

	TokenURIrawStr string `json:"token_uri_raw_str"`
	MediaURIrawStr string `json:"media_uri_raw_str"`

	// GATEWAY_URIs
	TokenURIgatewayStr string `json:"token_uri_gateway_str"`
	MediaURIgatewayStr string `json:"media_uri_gateway_str"`

	GFimageID          gf_images_core.GFimageID `json:"gf_image_id_str"`
	GFimageThumbURLstr string                   `json:"gf_image_thumb_url_str"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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