shopifyclient

package
v0.0.0-...-3bd4a2f Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Images

type Images struct {
	ID         int64         `json:"id"`
	CreatedAt  time.Time     `json:"created_at"`
	Position   int           `json:"position"`
	UpdatedAt  time.Time     `json:"updated_at"`
	ProductID  int64         `json:"product_id"`
	VariantIds []interface{} `json:"variant_ids"`
	Src        string        `json:"src"`
	Width      int           `json:"width"`
	Height     int           `json:"height"`
}

type Options

type Options struct {
	Name     string   `json:"name"`
	Position int      `json:"position"`
	Values   []string `json:"values"`
}

type Products

type Products struct {
	ID          int64      `json:"id"`
	Title       string     `json:"title"`
	Handle      string     `json:"handle"`
	BodyHTML    string     `json:"body_html"`
	PublishedAt time.Time  `json:"published_at"`
	CreatedAt   time.Time  `json:"created_at"`
	UpdatedAt   time.Time  `json:"updated_at"`
	Vendor      string     `json:"vendor"`
	ProductType string     `json:"product_type"`
	Tags        []string   `json:"tags"`
	Variants    []Variants `json:"variants"`
	Images      []Images   `json:"images"`
	Options     []Options  `json:"options"`
}

type ShopifyResponse

type ShopifyResponse struct {
	Products []Products `json:"products"`
}

func GetShopifyProducts

func GetShopifyProducts(client *http.Client, url string) (ShopifyResponse, error)

type Variants

type Variants struct {
	ID               int64       `json:"id"`
	Title            string      `json:"title"`
	Option1          string      `json:"option1"`
	Option2          interface{} `json:"option2"`
	Option3          interface{} `json:"option3"`
	Sku              string      `json:"sku"`
	RequiresShipping bool        `json:"requires_shipping"`
	Taxable          bool        `json:"taxable"`
	FeaturedImage    interface{} `json:"featured_image"`
	Available        bool        `json:"available"`
	Price            string      `json:"price"`
	Grams            int         `json:"grams"`
	CompareAtPrice   interface{} `json:"compare_at_price"`
	Position         int         `json:"position"`
	ProductID        int64       `json:"product_id"`
	CreatedAt        time.Time   `json:"created_at"`
	UpdatedAt        time.Time   `json:"updated_at"`
}

Jump to

Keyboard shortcuts

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