cardkingdom

package
v0.0.0-...-882b071 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2020 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CKClient

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

func NewCKClient

func NewCKClient() *CKClient

func (*CKClient) GetPriceList

func (ck *CKClient) GetPriceList() (*CKPriceList, error)

type CKData

type CKData struct {
	Id           int    `json:"id"`
	SKU          string `json:"sku"`
	URL          string `json:"url"`
	Name         string `json:"name"`
	Variation    string `json:"variation"`
	Edition      string `json:"edition"`
	IsFoil       string `json:"is_foil"`
	SellPrice    string `json:"price_retail"`
	SellQuantity int    `json:"qty_retail"`
	BuyPrice     string `json:"price_buy"`
	BuyQuantity  int    `json:"qty_buying"`
}

type CKPriceList

type CKPriceList struct {
	Meta struct {
		CreatedAt string `json:"created_at"`
		BaseURL   string `json:"base_url"`
	} `json:"meta"`
	Data []CKData `json:"data"`
}

type Cardkingdom

type Cardkingdom struct {
	LogCallback   mtgban.LogCallbackFunc
	Partner       string
	InventoryDate time.Time
	BuylistDate   time.Time
	// contains filtered or unexported fields
}

func NewScraper

func NewScraper(db mtgjson.MTGDB) *Cardkingdom

func (*Cardkingdom) Buylist

func (ck *Cardkingdom) Buylist() (map[string]mtgban.BuylistEntry, error)

func (*Cardkingdom) Grading

func (ck *Cardkingdom) Grading(entry mtgban.BuylistEntry) (grade map[string]float64)

func (*Cardkingdom) Info

func (ck *Cardkingdom) Info() (info mtgban.ScraperInfo)

func (*Cardkingdom) Inventory

func (ck *Cardkingdom) Inventory() (map[string][]mtgban.InventoryEntry, error)

Jump to

Keyboard shortcuts

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