Documentation ¶
Index ¶
- func GetComponent[V any](layout *PdpGetLayout) (*V, error)
- type AceSearchShopResp
- type AdParamsVar
- type Address
- type Ads
- type AllVariant
- type Amount
- type AnnotationData
- type Answer
- type AvailableFilter
- type BackgroundGradientColor
- type Badge
- type Banner
- type Banners
- type BasicInfo
- type BasicInfoStats
- type Bottomsheet
- type CallsError
- type Campaign
- type CartRedirection
- type Categories
- type CategoriesData
- type CategoriesHandler
- type Category
- type CategoryAllListLite
- type CategoryAllListLiteResp
- type CategoryDetail
- type CategoryGroup
- type CategoryProduct
- type CategoryProducts
- type CategoryRow
- type ClosedInfo
- type ClosedInfoDetail
- type Component
- type ComponentParser
- type CreateInfo
- type CustomSEO
- type DataValue
- type DetailImage
- type DetailReview
- type DevError
- type DiscussionDataByProductID
- type DiscussionDataProductByIDResp
- type DiscussionDataProductByIDVar
- type District
- type DrogonAnnotationCategoryV2
- type DynamicHomeIcon
- type DynamicRule
- type EpharmacyInfo
- type ErrCartRedirection
- type ErrNearestWarehouse
- type ErrShopInfo
- type Error
- type FavoriteData
- type FilterOption
- type FilterProduct
- type FilterSearch
- type FilterSortProduct
- type FilterSortProductData
- type FilterSortProductResp
- type Flags
- type FulfillmentData
- type GetDrogonAnnotationResp
- type GetDrogonAnnotationVar
- type GetPublicMerchantVoucherList
- type GetShopOperationalHourStatus
- type GetShopOperationalHourStatusResp
- type GetShopProduct
- type GetVariantCategoryCombination
- type GetVariantCategoryCombinationData
- type GlobalComponent
- type GlobalDataComponent
- type GoldOS
- type Header
- type HeaderErr
- type HeaderMainData
- type HeaderMainDataResp
- type HeaderSearchProduct
- type Image
- type ImageAttachment
- type InstallmentRecommendationData
- type InterfaceDataComp
- type IsCashback
- type JarvisRecommendationResp
- type JarvisRecommendationVar
- type KeroDistrictRecommendation
- type Label
- type LabelGroups
- type LikeDislike
- type Links
- type LocDisctricRecommendationResp
- type LocDisctricRecommendationVar
- type Media
- type MediaComponent
- type MediaComponentData
- type MediaType
- type Menu
- type MerchantVoucher
- type MerchantVoucherAmount
- type MerchantVoucherBanner
- type MerchantVoucherType
- type Meta
- type NearestWarehouse
- type NewVariantChild
- type NewVariantOptionData
- type NewVariantOptionsComponent
- type Owner
- type OwnerInfo
- type PDPComponentName
- type PDPListComponents
- type Pagination
- type ParamsVar
- type PartnerInfo
- type PdpGetData
- type PdpGetDataP2Data
- type PdpGetDataP2Resp
- type PdpGetDataP2Var
- type PdpGetLayout
- func (layout *PdpGetLayout) GetDescription() (string, error)
- func (layout *PdpGetLayout) GetImages() ([]string, error)
- func (layout *PdpGetLayout) GetPercentageAmount() (int, error)
- func (layout *PdpGetLayout) GetPrice() (int, error)
- func (layout *PdpGetLayout) GetPriceBeforeDiscount() (int, error)
- func (layout *PdpGetLayout) GetProductName() (string, error)
- func (layout *PdpGetLayout) GetStock() (int, error)
- type PdpGetReiewImageQueryResp
- type PdpGetReiewImageQueryVar
- type PdpGetlayoutData
- type PdpGetlayoutQueryResp
- type PdpGetlayoutQueryVar
- type PdpShopNoteResp
- type Picture
- type Preorder
- type Price
- type PrimaryImage
- type ProdDetailComTitle
- type ProductCampaign
- type ProductContentComponent
- type ProductContentData
- type ProductDetailComponent
- type ProductDetailContent
- type ProductDetailData
- type ProductIdVar
- type ProductLabel
- type ProductPrice
- type ProductRatingandTopicsResp
- type ProductRecommendationWidget
- type ProductReviewListResp
- type ProductReviewListVar
- type ProductSearch
- type ProductShop
- type ProductStock
- type ProductTxStats
- type ProductVariant
- type ProductrevGetProductRatingAndTopics
- type ProductrevGetProductReviewList
- type ProductrevGetReviewImage
- type Products
- type ProductsBebasOngkir
- type Question
- type RatesEstimate
- type RatesEstimateData
- type RatesEstimateQueryResp
- type RatesEstimateQueryVar
- type RatesEstimateV3
- type RatesService
- type Rating
- type RatingDetail
- type RecentOneMonth
- type RecomShop
- type RecomWidgetResp
- type RecomWidgetVar
- type Recomendation
- type Redirection
- type Related
- type Result
- type Review
- type ReviewImageDetail
- type ReviewImageList
- type ReviewResponse
- type ReviewStats
- type Reviewer
- type SearchProductAdParams
- type SearchProductBanner
- type SearchProductChunkHandler
- type SearchProductData
- type SearchProductQueryResp
- type SearchProductQueryV4Resp
- type SearchProductQueryVar
- type SearchProductVar
- type SearchProducts
- type SearchShop
- type ShipmentInfo
- type ShipmentInfoProduct
- type ShippingLoc
- type Shop
- type ShopAssets
- type ShopBadge
- type ShopCore
- type ShopCoreInfoResp
- type ShopCoreInfoVar
- type ShopFinishRate
- type ShopIdStrVar
- type ShopIdVar
- type ShopIdVarInt
- type ShopInfo
- type ShopInfoByID
- type ShopInfoByIDResult
- type ShopInfoFavoriteData
- type ShopNoteResp
- type ShopNoteResults
- type ShopNoteVar
- type ShopNotesByShopID
- type ShopPageGetLayout
- type ShopPageGetLayoutV2Resp
- type ShopPageGetLayoutV2Var
- type ShopProduct
- type ShopProductData
- type ShopProductResp
- type ShopProductVar
- type ShopRating
- type ShopReputation
- type ShopSatisfaction
- type ShopSpeedQueryResp
- type ShopStatisticQueryData
- type ShopStatisticQueryResp
- type ShopStatisticQueryVar
- type ShopStats
- type ShopSuggestion
- type ShopVoucher
- type ShopVoucherQueryResp
- type SortProduct
- type State
- type Stats
- type Status
- type StatusInfo
- type StockWording
- type Suggestion
- type ThematicCampaign
- type Ticker
- type Tokonow
- type TopadsProductQueryResp
- type Topic
- type User
- type UserLocation
- type Variant
- type VariantCategoryCombinationResp
- type VariantCategoryCombinationVar
- type VariantDetail
- type VariantDetailUnit
- type VariantOption
- type VariantStock
- type VariantUnitValue
- type Violation
- type VoucherCashback
- type VoucherType
- type Vouchers
- type WarehouseInfo
- type Widget
- type WidgetData
- type WidgetHeader
- type WidgetRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetComponent ¶ added in v1.1.8
func GetComponent[V any](layout *PdpGetLayout) (*V, error)
Types ¶
type AceSearchShopResp ¶
type AceSearchShopResp struct { Data struct { AceSearchShop struct { TotalData int `json:"totalData"` Shops []SearchShop `json:"shops"` Suggestion ShopSuggestion `json:"suggestion"` Header Header `json:"header"` Typename string `json:"__typename"` } `json:"aceSearchShop"` } `json:"data"` }
type AdParamsVar ¶
type AdParamsVar struct {
AdParams string `json:"adParams"`
}
type Address ¶ added in v1.0.2
type Address struct { CityName string `json:"city_name"` ProvinceName string `json:"province_name"` DistrictName string `json:"district_name"` Country string `json:"country"` PostalCode string `json:"postal_code"` Address string `json:"address"` Lat string `json:"lat"` Long string `json:"long"` Phone string `json:"phone"` AddrName string `json:"addr_name"` Address1 string `json:"address_1"` ReceiverName string `json:"receiver_name"` Typename string `json:"__typename"` }
type AllVariant ¶
type AnnotationData ¶
type Answer ¶
type Answer struct { AnswerID string `json:"answerID"` Content string `json:"content"` MaskedContent string `json:"maskedContent"` UserName string `json:"userName"` UserThumbnail string `json:"userThumbnail"` UserID string `json:"userID"` IsSeller bool `json:"isSeller"` CreateTime string `json:"createTime"` CreateTimeFormatted string `json:"createTimeFormatted"` LikeCount int `json:"likeCount"` State State `json:"state"` AttachedProductCount int `json:"attachedProductCount"` Typename string `json:"__typename"` }
type AvailableFilter ¶
type BackgroundGradientColor ¶
type BasicInfo ¶
type BasicInfo struct { Alias string `json:"alias"` CreatedAt string `json:"createdAt"` IsQA bool `json:"isQA"` ID string `json:"id"` ShopID string `json:"shopID"` ShopName string `json:"shopName"` MinOrder int `json:"minOrder"` MaxOrder int `json:"maxOrder"` Weight int `json:"weight"` WeightUnit string `json:"weightUnit"` Condition string `json:"condition"` Status string `json:"status"` URL string `json:"url"` NeedPrescription bool `json:"needPrescription"` CatalogID string `json:"catalogID"` IsLeasing bool `json:"isLeasing"` IsBlacklisted bool `json:"isBlacklisted"` IsTokoNow bool `json:"isTokoNow"` Menu Menu `json:"menu"` Category Category `json:"category"` TxStats ProductTxStats `json:"txStats"` Stats BasicInfoStats `json:"stats"` Typename string `json:"__typename"` }
type BasicInfoStats ¶
type BasicInfoStats struct { CountView int `json:"countView"` CountReview int `json:"countReview"` CountTalk int `json:"countTalk"` Rating float64 `json:"rating"` Typename string `json:"__typename"` }
func (*BasicInfoStats) UnmarshalJSON ¶ added in v1.1.27
func (stat *BasicInfoStats) UnmarshalJSON(data []byte) error
type Bottomsheet ¶
type CallsError ¶
type CallsError struct { ShopInfo ErrShopInfo `json:"shopInfo"` CartRedirection ErrCartRedirection `json:"cartRedirection"` NearestWarehouse ErrNearestWarehouse `json:"nearestWarehouse"` Typename string `json:"__typename"` }
type CartRedirection ¶
type CartRedirection struct { Status string `json:"status"` ErrorMessage []interface{} `json:"error_message"` Data []struct { ProductID string `json:"product_id"` ConfigName string `json:"config_name"` HideFloatingButton bool `json:"hide_floating_button"` AvailableButtons []struct { Text string `json:"text"` Color string `json:"color"` CartType string `json:"cart_type"` OnboardingMessage string `json:"onboarding_message"` ShowRecommendation bool `json:"show_recommendation"` Typename string `json:"__typename"` } `json:"available_buttons"` UnavailableButtons []string `json:"unavailable_buttons"` Typename string `json:"__typename"` } `json:"data"` Typename string `json:"__typename"` }
type Categories ¶
type Categories struct { ID int `json:"id"` Name string `json:"name"` URL string `json:"url,omitempty"` Children []*Categories `json:"children,omitempty"` Typename string `json:"__typename,omitempty"` }
type CategoriesData ¶ added in v1.1.27
type CategoriesData []*Categories
func (CategoriesData) GetCategoryByUrl ¶ added in v1.1.27
func (data CategoriesData) GetCategoryByUrl(url string) (*Categories, error)
func (CategoriesData) Iterate ¶ added in v1.1.27
func (data CategoriesData) Iterate(handler CategoriesHandler) error
type CategoriesHandler ¶ added in v1.1.27
type CategoriesHandler func(parents []*Categories, category *Categories) (stop bool, err error)
type Category ¶
type Category struct { ID string `json:"id"` Name string `json:"name"` Title string `json:"title"` Detail *CategoryDetail `json:"detail"` BreadcrumbURL string `json:"breadcrumbURL"` IsAdult bool `json:"isAdult"` IsKyc bool `json:"isKyc"` MinAge int `json:"minAge"` Typename string `json:"__typename"` }
type CategoryAllListLite ¶ added in v1.1.27
type CategoryAllListLite struct { Categories CategoriesData `json:"categories"` Typename string `json:"__typename"` }
type CategoryAllListLiteResp ¶
type CategoryAllListLiteResp struct { Data struct { CategoryAllListLite struct { Categories []*Categories `json:"categories"` Typename string `json:"__typename"` } `json:"categoryAllListLite"` } `json:"data"` }
type CategoryDetail ¶
type CategoryGroup ¶ added in v1.1.27
type CategoryGroup struct { ID int `json:"id"` Title string `json:"title"` Desc string `json:"desc"` CategoryRows []CategoryRow `json:"categoryRows"` Typename string `json:"__typename"` }
type CategoryProduct ¶ added in v1.0.2
type CategoryProduct struct { ID int64 `json:"id"` URL string `json:"url"` ImageURL string `json:"imageUrl"` ImageURLLarge string `json:"imageUrlLarge"` CatID int `json:"catId"` GaKey string `json:"gaKey"` CountReview int `json:"countReview"` DiscountPercentage int `json:"discountPercentage"` Preorder bool `json:"preorder"` Name string `json:"name"` Price string `json:"price"` PriceInt int `json:"priceInt"` OriginalPrice string `json:"original_price"` Rating int `json:"rating"` Wishlist bool `json:"wishlist"` Labels []interface{} `json:"labels"` Badges []struct { ImageURL string `json:"imageUrl"` Show bool `json:"show"` Typename string `json:"__typename"` } `json:"badges"` Shop struct { ID int `json:"id"` URL string `json:"url"` Name string `json:"name"` Goldmerchant bool `json:"goldmerchant"` Official bool `json:"official"` Reputation string `json:"reputation"` Clover string `json:"clover"` Location string `json:"location"` Typename string `json:"__typename"` } `json:"shop"` LabelGroups []LabelGroups `json:"labelGroups"` Typename string `json:"__typename"` }
type CategoryProducts ¶ added in v1.0.2
type CategoryProducts struct { Count int `json:"count"` Data []CategoryProduct `json:"data"` Typename string `json:"__typename"` }
type CategoryRow ¶ added in v1.1.27
type ClosedInfo ¶
type ClosedInfo struct { ClosedNote string `json:"closedNote"` Until string `json:"until,omitempty"` Reason string `json:"reason"` Detail ClosedInfoDetail `json:"detail"` Typename string `json:"__typename"` }
type ClosedInfoDetail ¶
type Component ¶
type Component struct { Name PDPComponentName `json:"name"` Type string `json:"type"` Position string `json:"position"` Typename string `json:"__typename"` }
type ComponentParser ¶
type ComponentParser struct { Name PDPComponentName `json:"name"` Type string `json:"type"` Component interface{} }
func (*ComponentParser) UnmarshalJSON ¶
func (p *ComponentParser) UnmarshalJSON(data []byte) error
type CreateInfo ¶
type DetailImage ¶
type DetailReview ¶
type DetailReview struct { Reviewer Reviewer `json:"reviewer"` ShopID string `json:"shopID"` FeedbackID string `json:"feedbackID"` VariantName string `json:"variantName"` ReviewText string `json:"reviewText"` Rating int `json:"rating"` ReviewTime string `json:"reviewTime"` LikeCount int `json:"likeCount"` BadRatingReasonFmt string `json:"badRatingReasonFmt"` IsLiked bool `json:"isLiked"` IsAnonymous bool `json:"isAnonymous"` IsReportable bool `json:"isReportable"` Typename string `json:"__typename"` }
type DiscussionDataProductByIDResp ¶
type DiscussionDataProductByIDResp struct { Data struct { DiscussionDataByProductID DiscussionDataByProductID `json:"discussionDataByProductID"` } `json:"data"` }
type District ¶
type District struct { DistrictID int `json:"districtId"` DistrictName string `json:"district_name"` CityID int `json:"cityId"` CityName string `json:"city_name"` ProvinceID int `json:"provinceId"` ProvinceName string `json:"province_name"` ZipCode []string `json:"zip_code"` Typename string `json:"__typename"` }
type DrogonAnnotationCategoryV2 ¶
type DrogonAnnotationCategoryV2 struct { Header HeaderErr `json:"header"` ProductID int64 `json:"productID"` Data []AnnotationData `json:"data"` Typename string `json:"__typename"` }
type DynamicHomeIcon ¶ added in v1.1.27
type DynamicHomeIcon struct { CategoryGroup []CategoryGroup `json:"categoryGroup"` Typename string `json:"__typename"` }
type DynamicRule ¶
type EpharmacyInfo ¶
type ErrCartRedirection ¶
type ErrNearestWarehouse ¶
type ErrShopInfo ¶
type FavoriteData ¶
type FilterOption ¶
type FilterOption struct { Name string `json:"name"` Description string `json:"Description"` Key string `json:"key"` Icon string `json:"icon"` Value string `json:"value"` InputType string `json:"inputType"` TotalData string `json:"totalData"` ValMax string `json:"valMax"` ValMin string `json:"valMin"` HexColor string `json:"hexColor"` Child []interface{} `json:"child"` IsPopular bool `json:"isPopular"` IsNew bool `json:"isNew"` Typename string `json:"__typename"` }
type FilterProduct ¶
type FilterProduct struct { Title string `json:"title"` TemplateName string `json:"template_name"` Search FilterSearch `json:"search"` Options []FilterOption `json:"options"` Typename string `json:"__typename"` }
type FilterSearch ¶
type FilterSortProduct ¶
type FilterSortProduct struct { Data FilterSortProductData `json:"data"` Typename string `json:"__typename"` }
type FilterSortProductData ¶
type FilterSortProductData struct { Filter []FilterProduct `json:"filter"` Sort []SortProduct `json:"sort"` Typename string `json:"__typename"` }
type FilterSortProductResp ¶
type FilterSortProductResp struct { Data struct { FilterSortProduct FilterSortProduct `json:"filter_sort_product"` } `json:"data"` }
type FulfillmentData ¶
type GetDrogonAnnotationResp ¶
type GetDrogonAnnotationResp struct { Data struct { DrogonAnnotationCategoryV2 DrogonAnnotationCategoryV2 `json:"drogonAnnotationCategoryV2"` } `json:"data"` }
type GetDrogonAnnotationVar ¶
type GetShopOperationalHourStatus ¶
type GetShopOperationalHourStatus struct { Timestamp string `json:"timestamp"` StatusActive bool `json:"statusActive"` StartTime string `json:"startTime"` EndTime string `json:"endTime"` TimestampUTCUnix string `json:"timestampUTCUnix"` TickerTitle string `json:"tickerTitle"` TickerMessage string `json:"tickerMessage"` Typename string `json:"__typename"` }
type GetShopOperationalHourStatusResp ¶
type GetShopOperationalHourStatusResp struct { Data struct { GetShopOperationalHourStatus GetShopOperationalHourStatus `json:"getShopOperationalHourStatus"` } `json:"data"` }
type GetShopProduct ¶
type GetShopProduct struct { Status string `json:"status"` Errors string `json:"errors"` Links Links `json:"links"` Data []*ShopProductData `json:"data"` Typename string `json:"__typename"` }
type GetVariantCategoryCombination ¶
type GetVariantCategoryCombination struct { Header HeaderErr `json:"header"` Data GetVariantCategoryCombinationData `json:"data"` Typename string `json:"__typename"` }
type GetVariantCategoryCombinationData ¶
type GetVariantCategoryCombinationData struct { CategoryID int `json:"categoryID"` VariantIDCombinations [][]int `json:"variantIDCombinations"` AllVariants []AllVariant `json:"allVariants"` VariantDetails []VariantDetail `json:"variantDetails"` Typename string `json:"__typename"` }
type GlobalComponent ¶
type GlobalComponent struct { Component Data []GlobalDataComponent `json:"data"` Typename string `json:"__typename"` }
type GlobalDataComponent ¶
type HeaderMainData ¶ added in v1.1.27
type HeaderMainData struct { DynamicHomeIcon DynamicHomeIcon `json:"dynamicHomeIcon"` CategoryAllListLite CategoryAllListLite `json:"categoryAllListLite"` }
type HeaderMainDataResp ¶ added in v1.1.5
type HeaderMainDataResp struct {
Data HeaderMainData `json:"data"`
}
type HeaderSearchProduct ¶
type HeaderSearchProduct struct { TotalData int `json:"totalData"` TotalDataText string `json:"totalDataText"` ProcessTime float64 `json:"processTime"` ResponseCode int `json:"responseCode"` ErrorMessage string `json:"errorMessage"` AdditionalParams string `json:"additionalParams"` KeywordProcess string `json:"keywordProcess"` ComponentID string `json:"componentId"` Typename string `json:"__typename"` }
type ImageAttachment ¶
type InstallmentRecommendationData ¶
type InstallmentRecommendationData struct { Term int `json:"term"` MdrValue int `json:"mdr_value"` MdrType string `json:"mdr_type"` InterestRate int `json:"interest_rate"` MinimumAmount int `json:"minimum_amount"` MaximumAmount int `json:"maximum_amount"` MonthlyPrice int `json:"monthly_price"` OsMonthlyPrice int `json:"os_monthly_price"` PartnerCode string `json:"partner_code"` PartnerName string `json:"partner_name"` PartnerIcon string `json:"partner_icon"` Subtitle string `json:"subtitle"` Typename string `json:"__typename"` }
type InterfaceDataComp ¶
type IsCashback ¶
type JarvisRecommendationResp ¶
type JarvisRecommendationResp struct { Data struct { GetJarvisRecommendation struct { Categories []Categories `json:"categories"` Typename string `json:"__typename"` } `json:"getJarvisRecommendation"` } `json:"data"` }
type JarvisRecommendationVar ¶
type JarvisRecommendationVar struct {
ProductName string `json:"productName"`
}
type LabelGroups ¶
type LikeDislike ¶
type LocDisctricRecommendationResp ¶
type LocDisctricRecommendationResp struct { Data struct { KeroDistrictRecommendation KeroDistrictRecommendation `json:"kero_district_recommendation"` } `json:"data"` }
type Media ¶
type Media struct { Type MediaType `json:"type"` URLOriginal string `json:"urlOriginal"` URLThumbnail string `json:"urlThumbnail"` URLMaxRes string `json:"urlMaxRes"` VideoURL string `json:"videoUrl"` Prefix string `json:"prefix"` Suffix string `json:"suffix"` Description string `json:"description"` VariantOptionID string `json:"variantOptionID"` Typename string `json:"__typename"` }
type MediaComponent ¶
type MediaComponent struct { Component Data []MediaComponentData `json:"data"` Typename string `json:"__typename"` }
type MediaComponentData ¶
type MerchantVoucher ¶
type MerchantVoucher struct { VoucherID int `json:"voucher_id"` VoucherName string `json:"voucher_name"` VoucherType MerchantVoucherType `json:"voucher_type"` VoucherCode string `json:"voucher_code"` Amount MerchantVoucherAmount `json:"amount"` MinimumSpend int `json:"minimum_spend"` ValidThru string `json:"valid_thru"` Tnc string `json:"tnc"` Banner MerchantVoucherBanner `json:"banner"` Status Status `json:"status"` InUseExpiry string `json:"in_use_expiry"` Typename string `json:"__typename"` }
type MerchantVoucherAmount ¶
type MerchantVoucherBanner ¶
type MerchantVoucherType ¶
type NearestWarehouse ¶
type NewVariantChild ¶
type NewVariantChild struct { ProductID string `json:"productID"` Price int `json:"price"` PriceFmt string `json:"priceFmt"` OptionID []int `json:"optionID"` OptionName []string `json:"optionName"` ProductName string `json:"productName"` ProductURL string `json:"productURL"` Picture Picture `json:"picture"` Stock VariantStock `json:"stock"` IsCOD bool `json:"isCOD"` IsWishlist bool `json:"isWishlist"` CampaignInfo ProductCampaign `json:"campaignInfo"` ThematicCampaign ThematicCampaign `json:"thematicCampaign"` Typename string `json:"__typename"` }
type NewVariantOptionData ¶
type NewVariantOptionData struct { ErrorCode int `json:"errorCode"` ParentID string `json:"parentID"` DefaultChild string `json:"defaultChild"` SizeChart string `json:"sizeChart"` TotalStockFmt string `json:"totalStockFmt"` Variants []Variant `json:"variants"` Children []NewVariantChild `json:"children"` Typename string `json:"__typename"` }
type NewVariantOptionsComponent ¶
type NewVariantOptionsComponent struct { Component Data []NewVariantOptionData `json:"data"` Typename string `json:"__typename"` }
type PDPComponentName ¶
type PDPComponentName string
const ( MediaComponentName PDPComponentName = "product_media" TickerInfoComponentName PDPComponentName = "ticker_info" VariantOptionsComponentName PDPComponentName = "variant_options" ProductContentComponentName PDPComponentName = "product_content" NewVariantOptionsComponentName PDPComponentName = "new_variant_options" ProductDetailComponentName PDPComponentName = "product_detail" ObatKerasComponentName PDPComponentName = "obat_keras" ShopCredibilityComponentName PDPComponentName = "shop_credibility" ShipmentComponentName PDPComponentName = "shipment" ShippingComponentName PDPComponentName = "shipping" ShopVoucerComponentName PDPComponentName = "shop_voucher" OfferingComponentName PDPComponentName = "offerings" InstallmentPaylaterComponentName PDPComponentName = "installment_paylater" QRCodeComponentName PDPComponentName = "QRCode" WholesaleComponentName PDPComponentName = "wholesale" ProtectionComponentName PDPComponentName = "protection" ReportComponentName PDPComponentName = "report" ReviewComponentName PDPComponentName = "review" TdnTopadsComponentName PDPComponentName = "tdn_topads" DiscussionFaqComponentName PDPComponentName = "discussion_faq" Pdp1ComponentName PDPComponentName = "pdp_1" Pdp2ComponentName PDPComponentName = "pdp_2" Pdp3ComponentName PDPComponentName = "pdp_3" Pdp4ComponentName PDPComponentName = "pdp_4" )
type PDPListComponents ¶
type PDPListComponents []interface{}
func (*PDPListComponents) UnmarshalJSON ¶
func (p *PDPListComponents) UnmarshalJSON(data []byte) error
type Pagination ¶
type PartnerInfo ¶
type PdpGetData ¶
type PdpGetData struct { Error DevError `json:"error"` CallsError CallsError `json:"callsError"` ProductView string `json:"productView"` WishlistCount string `json:"wishlistCount"` ShopFinishRate ShopFinishRate `json:"shopFinishRate"` ShopInfo ShopInfo `json:"shopInfo"` MerchantVoucher struct { Vouchers []MerchantVoucher `json:"vouchers"` Typename string `json:"__typename"` } `json:"merchantVoucher"` NearestWarehouse []NearestWarehouse `json:"nearestWarehouse"` InstallmentRecommendation struct { Data InstallmentRecommendationData `json:"data"` Typename string `json:"__typename"` } `json:"installmentRecommendation"` ProductWishlistQuery struct { Value bool `json:"value"` Typename string `json:"__typename"` } `json:"productWishlistQuery"` CartRedirection CartRedirection `json:"cartRedirection"` ShopTopChatSpeed struct { MessageResponseTime string `json:"messageResponseTime"` Typename string `json:"__typename"` } `json:"shopTopChatSpeed"` ShopRatingsQuery struct { RatingScore float64 `json:"ratingScore"` Typename string `json:"__typename"` } `json:"shopRatingsQuery"` ShopPackSpeed struct { SpeedFmt string `json:"speedFmt"` Hour int `json:"hour"` Typename string `json:"__typename"` } `json:"shopPackSpeed"` RatesEstimate []RatesEstimate `json:"ratesEstimate"` RestrictionInfo struct { Message string `json:"message"` RestrictionData []interface{} `json:"restrictionData"` Typename string `json:"__typename"` } `json:"restrictionInfo"` Ticker struct { TickerInfo []interface{} `json:"tickerInfo"` Typename string `json:"__typename"` } `json:"ticker"` Name string `json:"name"` Items []interface{} `json:"items"` Typename string `json:"__typename"` } `json:"navBar"` BebasOngkir struct { Products []ProductsBebasOngkir `json:"products"` Typename string `json:"__typename"` } `json:"bebasOngkir"` Typename string `json:"__typename"` }
type PdpGetDataP2Data ¶ added in v1.1.10
type PdpGetDataP2Data struct {
PdpGetData PdpGetData `json:"pdpGetData"`
}
type PdpGetDataP2Resp ¶
type PdpGetDataP2Resp struct {
Data PdpGetDataP2Data `json:"data"`
}
type PdpGetDataP2Var ¶
type PdpGetDataP2Var struct { Affiliate interface{} `json:"affiliate"` ProductID string `json:"productID"` PdpSession string `json:"pdpSession"` DeviceID string `json:"deviceID"` UserLocation *UserLocation `json:"userLocation,omitempty"` Tokonow *Tokonow `json:"tokonow,omitempty"` }
func NewPdpGetDataP2Var ¶ added in v1.1.15
func NewPdpGetDataP2Var(layout PdpGetLayout) *PdpGetDataP2Var
type PdpGetLayout ¶
type PdpGetLayout struct { RequestID string `json:"requestID"` Name string `json:"name"` PdpSession string `json:"pdpSession"` BasicInfo BasicInfo `json:"basicInfo"` Components PDPListComponents `json:"components"` Typename string `json:"__typename"` }
func (*PdpGetLayout) GetDescription ¶ added in v1.1.15
func (layout *PdpGetLayout) GetDescription() (string, error)
func (*PdpGetLayout) GetImages ¶ added in v1.1.15
func (layout *PdpGetLayout) GetImages() ([]string, error)
func (*PdpGetLayout) GetPercentageAmount ¶ added in v1.1.10
func (layout *PdpGetLayout) GetPercentageAmount() (int, error)
func (*PdpGetLayout) GetPrice ¶ added in v1.1.15
func (layout *PdpGetLayout) GetPrice() (int, error)
func (*PdpGetLayout) GetPriceBeforeDiscount ¶ added in v1.1.15
func (layout *PdpGetLayout) GetPriceBeforeDiscount() (int, error)
func (*PdpGetLayout) GetProductName ¶ added in v1.1.10
func (layout *PdpGetLayout) GetProductName() (string, error)
func (*PdpGetLayout) GetStock ¶ added in v1.1.15
func (layout *PdpGetLayout) GetStock() (int, error)
type PdpGetReiewImageQueryResp ¶
type PdpGetReiewImageQueryResp struct { Data struct { ProductrevGetReviewImage ProductrevGetReviewImage `json:"productrevGetReviewImage"` } `json:"data"` }
type PdpGetlayoutData ¶ added in v1.1.10
type PdpGetlayoutData struct {
PdpGetLayout PdpGetLayout `json:"pdpGetLayout"`
}
type PdpGetlayoutQueryResp ¶
type PdpGetlayoutQueryResp struct {
Data PdpGetlayoutData `json:"data"`
}
type PdpGetlayoutQueryVar ¶
type PdpGetlayoutQueryVar struct { ShopDomain string `json:"shopDomain"` ProductKey string `json:"productKey"` LayoutID string `json:"layoutID"` APIVersion int `json:"apiVersion"` Tokonow *Tokonow `json:"tokonow,omitempty"` UserLocation *UserLocation `json:"userLocation,omitempty"` ExtParam string `json:"extParam"` }
func NewPdpGetlayoutQueryVar ¶ added in v1.1.10
func NewPdpGetlayoutQueryVar(uri string) (queryVar *PdpGetlayoutQueryVar, err error)
type PdpShopNoteResp ¶
type PrimaryImage ¶
type ProdDetailComTitle ¶ added in v1.1.9
type ProdDetailComTitle string
const ( KondisiTitle ProdDetailComTitle = "Kondisi" BeratSatuanTitle ProdDetailComTitle = "Berat Satuan" MinPemesananTitle ProdDetailComTitle = "Min. Pemesanan" CategoryTitle ProdDetailComTitle = "Kategori" EtalaseTitle ProdDetailComTitle = "Etalase" DeskripsiTitle ProdDetailComTitle = "Deskripsi" )
type ProductCampaign ¶
type ProductCampaign struct { CampaignID string `json:"campaignID"` CampaignType string `json:"campaignType"` CampaignTypeName string `json:"campaignTypeName"` CampaignIdentifier int `json:"campaignIdentifier"` Background string `json:"background"` OriginalPrice int `json:"originalPrice"` Stock int `json:"stock"` StockSoldPercentage int `json:"stockSoldPercentage"` StartDate string `json:"startDate"` EndDate string `json:"endDate"` EndDateUnix string `json:"endDateUnix"` AppLinks string `json:"appLinks"` IsAppsOnly bool `json:"isAppsOnly"` IsActive bool `json:"isActive"` HideGimmick bool `json:"hideGimmick"` PercentageAmount int `json:"percentageAmount"` DiscountedPrice int `json:"discountedPrice"` OriginalStock int `json:"originalStock"` Threshold int `json:"threshold"` IsCheckImei bool `json:"isCheckImei,omitempty"` DiscountPercentage int `json:"discountPercentage,omitempty"` DiscountPrice int `json:"discountPrice,omitempty"` MinOrder int `json:"minOrder,omitempty"` Typename string `json:"__typename"` }
type ProductContentComponent ¶
type ProductContentComponent struct { Component Data []ProductContentData `json:"data"` Typename string `json:"__typename"` }
type ProductContentData ¶
type ProductContentData struct { Name string `json:"name"` Price ProductPrice `json:"price"` Campaign ProductCampaign `json:"campaign"` ThematicCampaign ThematicCampaign `json:"thematicCampaign"` Stock ProductStock `json:"stock"` Variant ProductVariant `json:"variant"` Wholesale []interface{} `json:"wholesale"` IsCashback IsCashback `json:"isCashback"` IsTradeIn bool `json:"isTradeIn"` IsOS bool `json:"isOS"` IsPowerMerchant bool `json:"isPowerMerchant"` IsWishlist bool `json:"isWishlist"` IsCOD bool `json:"isCOD"` Preorder Preorder `json:"preorder"` Typename string `json:"__typename"` }
type ProductDetailComponent ¶
type ProductDetailComponent struct { Component Data []ProductDetailData `json:"data"` Typename string `json:"__typename"` }
type ProductDetailContent ¶
type ProductDetailData ¶
type ProductDetailData struct { Content []ProductDetailContent `json:"content"` Typename string `json:"__typename"` }
func (*ProductDetailData) GetContent ¶ added in v1.1.9
func (detail *ProductDetailData) GetContent(title ProdDetailComTitle) (*ProductDetailContent, error)
type ProductIdVar ¶
type ProductIdVar struct {
ProductId string `json:"productID"`
}
type ProductLabel ¶
type ProductPrice ¶
type ProductRatingandTopicsResp ¶
type ProductRatingandTopicsResp struct { Data struct { ProductrevGetProductRatingAndTopics ProductrevGetProductRatingAndTopics `json:"productrevGetProductRatingAndTopics"` } `json:"data"` }
type ProductRecommendationWidget ¶
type ProductRecommendationWidget struct { Data []struct { TID string `json:"tID"` Source string `json:"source"` Title string `json:"title"` ForeignTitle string `json:"foreignTitle"` SeeMoreURLLink string `json:"seeMoreUrlLink"` LayoutType string `json:"layoutType"` PageName string `json:"pageName"` WidgetURL string `json:"widgetUrl"` Pagination Pagination `json:"pagination"` Recommendation []Recomendation `json:"recommendation"` Typename string `json:"__typename"` } `json:"data"` Meta struct { Recommendation string `json:"recommendation"` Size int `json:"size"` FailSize int `json:"failSize"` ProcessTime string `json:"processTime"` ExperimentVersion string `json:"experimentVersion"` Typename string `json:"__typename"` } `json:"meta"` Typename string `json:"__typename"` }
type ProductReviewListResp ¶
type ProductReviewListResp struct { Data struct { ProductrevGetProductReviewList ProductrevGetProductReviewList `json:"productrevGetProductReviewList"` } `json:"data"` }
type ProductReviewListVar ¶
type ProductSearch ¶
type ProductSearch struct { ID int64 `json:"id"` Name string `json:"name"` Ads Ads `json:"ads"` Badges []interface{} `json:"badges"` Category int `json:"category"` CategoryBreadcrumb string `json:"categoryBreadcrumb"` CategoryID int `json:"categoryId"` CategoryName string `json:"categoryName"` CountReview int `json:"countReview"` CustomVideoURL string `json:"customVideoURL"` DiscountPercentage int `json:"discountPercentage"` GaKey string `json:"gaKey"` ImageURL string `json:"imageUrl"` LabelGroups []LabelGroups `json:"labelGroups"` OriginalPrice string `json:"originalPrice"` Price string `json:"price"` PriceRange string `json:"priceRange"` Rating int `json:"rating"` RatingAverage string `json:"ratingAverage"` Shop ProductShop `json:"shop"` URL string `json:"url"` Wishlist bool `json:"wishlist"` SourceEngine string `json:"sourceEngine"` Typename string `json:"__typename"` }
type ProductShop ¶
type ProductShop struct { ShopID int `json:"shopId"` Name string `json:"name"` City string `json:"city"` IsOfficial bool `json:"isOfficial"` IsPowerBadge bool `json:"isPowerBadge"` URL string `json:"url,omitempty"` Domain string `json:"domain,omitempty"` Tagline string `json:"tagline,omitempty"` URI string `json:"uri,omitempty"` Badges []ShopBadge `json:"badges,omitempty"` Typename string `json:"__typename"` }
type ProductStock ¶
type ProductTxStats ¶
type ProductTxStats struct { TransactionSuccess int `json:"transactionSuccess,string"` TransactionReject int `json:"transactionReject,string"` CountSold int `json:"countSold,string"` PaymentVerified int `json:"paymentVerified,string"` ItemSoldFmt string `json:"itemSoldFmt"` Typename string `json:"__typename"` }
type ProductVariant ¶
type ProductrevGetProductRatingAndTopics ¶
type ProductrevGetProductRatingAndTopics struct { ProductID string `json:"productID"` Rating Rating `json:"rating"` Topics []Topic `json:"topics"` AvailableFilters AvailableFilter `json:"availableFilters"` Typename string `json:"__typename"` }
type ProductrevGetReviewImage ¶
type ProductrevGetReviewImage struct { List []ReviewImageList `json:"list"` Detail ReviewImageDetail `json:"detail"` HasNext bool `json:"hasNext"` Typename string `json:"__typename"` }
type Products ¶
type Products struct { ID int64 `json:"id"` Name string `json:"name"` URL string `json:"url"` URLApps string `json:"urlApps"` URLMobile string `json:"urlMobile"` ImageURL string `json:"imageURL"` Price string `json:"price"` CountSold int `json:"countSold"` Stock int `json:"stock"` Status string `json:"status"` DiscountedPrice string `json:"discountedPrice"` DiscountPercentage int `json:"discountPercentage"` Position int `json:"position"` Rating float64 `json:"rating"` StockWording StockWording `json:"stockWording"` HideGimmick bool `json:"hideGimmick"` LabelGroups []LabelGroups `json:"labelGroups"` Typename string `json:"__typename"` }
type ProductsBebasOngkir ¶
type Question ¶
type Question struct { QuestionID string `json:"questionID"` Content string `json:"content"` MaskedContent string `json:"maskedContent"` UserName string `json:"userName"` UserThumbnail string `json:"userThumbnail"` UserID string `json:"userID"` CreateTime string `json:"createTime"` CreateTimeFormatted string `json:"createTimeFormatted"` State State `json:"state"` TotalAnswer int `json:"totalAnswer"` Answer Answer `json:"answer"` Typename string `json:"__typename"` }
type RatesEstimate ¶
type RatesEstimate struct { WarehouseID string `json:"warehouseID"` Products []string `json:"products"` Data RatesEstimateData `json:"data"` Bottomsheet Bottomsheet `json:"bottomsheet"` Typename string `json:"__typename"` }
type RatesEstimateData ¶
type RatesEstimateData struct { Destination string `json:"destination"` Title string `json:"title"` Subtitle string `json:"subtitle"` ChipsLabel []string `json:"chipsLabel"` CourierLabel string `json:"courierLabel"` ETAText string `json:"eTAText"` CheapestShippingPrice int `json:"cheapestShippingPrice"` FulfillmentData FulfillmentData `json:"fulfillmentData"` Errors []interface{} `json:"errors"` Typename string `json:"__typename"` }
type RatesEstimateQueryResp ¶ added in v1.0.2
type RatesEstimateQueryResp []struct { Data struct { RatesEstimateV3 RatesEstimateV3 `json:"ratesEstimateV3"` } `json:"data"` }
type RatesEstimateQueryVar ¶ added in v1.0.2
type RatesEstimateQueryVar struct { Weight float64 `json:"weight"` Domain string `json:"domain"` ProductID string `json:"productId"` Origin string `json:"origin"` Destination string `json:"destination"` POTime int `json:"POTime"` IsFulfillment bool `json:"isFulfillment"` DeviceType string `json:"deviceType"` ShopTier int `json:"shopTier"` BoMetadata string `json:"bo_metadata"` FreeShippingFlag int `json:"free_shipping_flag"` WarehouseID string `json:"warehouse_id"` }
weight: 0.25, domain: multiaccesoris, -> shop domain productId: 2248059401, origin: 5637|15810|YHeWJestVbuD66PoGVDnlQaHYJAZ8CG10NtXqKCEcuLjE3IncRxwVBiPSs6Tw6PTDkzUsF9kBXgJqw%3D%3D, -> geolocation PDPGetDataP2 destination: 2935||-8.127172,112.417213, POTime: 0, isFulfillment: false, deviceType: default_v3, shopTier: 3, bo_metadata: "", free_shipping_flag: 0, warehouse_id: 113930
type RatesEstimateV3 ¶ added in v1.0.2
type RatesEstimateV3 struct { Data struct { Address Address `json:"address"` Shop struct { DistrictID int `json:"district_id"` DistrictName string `json:"district_name"` PostalCode string `json:"postal_code"` Origin int `json:"origin"` AddrStreet string `json:"addr_street"` Latitude string `json:"latitude"` Longitude string `json:"longitude"` ProvinceID int `json:"province_id"` CityID int `json:"city_id"` CityName string `json:"city_name"` Typename string `json:"__typename"` } `json:"shop"` Rates struct { ID string `json:"id"` RatesID string `json:"rates_id"` Type string `json:"type"` Services []RatesService `json:"services"` Typename string `json:"__typename"` } `json:"rates"` Texts struct { TextMinPrice string `json:"text_min_price"` TextDestination string `json:"text_destination"` TextEta string `json:"text_eta"` Typename string `json:"__typename"` } `json:"texts"` FreeShipping struct { Flag int `json:"flag"` ShippingPrice string `json:"shipping_price"` EtaText string `json:"eta_text"` ErrorCode int `json:"error_code"` IconURL string `json:"icon_url"` Title string `json:"title"` Typename string `json:"__typename"` } `json:"free_shipping"` TokocabangFrom struct { Title string `json:"title"` Content string `json:"content"` IconURL string `json:"icon_url"` Typename string `json:"__typename"` } `json:"tokocabang_from"` IsBlackbox bool `json:"is_blackbox"` Typename string `json:"__typename"` } `json:"data"` Typename string `json:"__typename"` }
type RatesService ¶ added in v1.0.2
type RatesService struct { ServiceName string `json:"service_name"` ServiceID int `json:"service_id"` ServiceOrder int `json:"service_order"` Status int `json:"status"` RangePrice struct { MinPrice int `json:"min_price"` MaxPrice int `json:"max_price"` Typename string `json:"__typename"` } `json:"range_price"` Texts struct { TextServiceDesc string `json:"text_service_desc"` TextServiceNotes string `json:"text_service_notes"` TextRangePrice string `json:"text_range_price"` TextEtd string `json:"text_etd"` TextPrice string `json:"text_price"` Typename string `json:"__typename"` } `json:"texts"` Products []struct { ShipperName string `json:"shipper_name"` ShipperID int `json:"shipper_id"` ShipperProductID int `json:"shipper_product_id"` ShipperProductName string `json:"shipper_product_name"` ShipperWeight int `json:"shipper_weight"` Price struct { Price int `json:"price"` FormattedPrice string `json:"formatted_price"` Typename string `json:"__typename"` } `json:"price"` Texts struct { TextEtd string `json:"text_etd"` TextRangePrice string `json:"text_range_price"` TextEtaSummarize string `json:"text_eta_summarize"` Typename string `json:"__typename"` } `json:"texts"` Cod struct { IsCodAvailable int `json:"is_cod_available"` Typename string `json:"__typename"` } `json:"cod"` Eta struct { TextEta string `json:"text_eta"` ErrorCode int `json:"error_code"` Typename string `json:"__typename"` } `json:"eta"` Features struct { DynamicPrice struct { TextLabel string `json:"text_label"` Typename string `json:"__typename"` } `json:"dynamic_price"` Typename string `json:"__typename"` } `json:"features"` Typename string `json:"__typename"` } `json:"products"` ServiceBasedShipment struct { IsAvailable bool `json:"is_available"` TextPrice string `json:"text_price"` TextEta string `json:"text_eta"` Typename string `json:"__typename"` } `json:"service_based_shipment"` Cod struct { IsCod int `json:"is_cod"` CodText string `json:"cod_text"` Typename string `json:"__typename"` } `json:"cod"` OrderPriority struct { IsNow bool `json:"is_now"` Typename string `json:"__typename"` } `json:"order_priority"` Etd struct { MinEtd int `json:"min_etd"` MaxEtd int `json:"max_etd"` Typename string `json:"__typename"` } `json:"etd"` Typename string `json:"__typename"` }
type Rating ¶
type Rating struct { PositivePercentageFmt string `json:"positivePercentageFmt"` RatingScore string `json:"ratingScore"` TotalRating int `json:"totalRating"` TotalRatingWithImage int `json:"totalRatingWithImage"` TotalRatingTextAndImage int `json:"totalRatingTextAndImage"` Detail []RatingDetail `json:"detail"` Typename string `json:"__typename"` }
type RatingDetail ¶
type RecentOneMonth ¶
type RecomWidgetResp ¶
type RecomWidgetResp struct { Data struct { ProductRecommendationWidget ProductRecommendationWidget `json:"productRecommendationWidget"` } `json:"data"` }
type RecomWidgetVar ¶
type RecomWidgetVar struct { UserID int `json:"userID"` XDevice string `json:"xDevice"` PageName string `json:"pageName"` Ref string `json:"ref"` ProductIDs string `json:"productIDs"` TokoNow bool `json:"tokoNow"` CategoryIDs string `json:"categoryIDs"` Keyword []interface{} `json:"keyword"` LayoutPageType string `json:"LayoutPageType"` QueryParam string `json:"queryParam"` }
type Recomendation ¶
type Recomendation struct { ProductSlashedPrice string `json:"productSlashedPrice"` SlashedPriceInt int `json:"slashedPriceInt"` ProductDiscountPercentage int `json:"productDiscountPercentage"` ProductReviewCount int `json:"productReviewCount"` IsWishlist bool `json:"isWishlist"` ProductImageURL string `json:"productImageUrl"` IsTopads bool `json:"isTopads"` ClickURL string `json:"clickUrl"` TrackerImageURL string `json:"trackerImageUrl"` ProductURL string `json:"productUrl"` ProductRating int `json:"productRating"` ProductPrice string `json:"productPrice"` PriceInt int `json:"priceInt"` ID int `json:"id"` ProductName string `json:"productName"` CategoryBreadcrumbs string `json:"categoryBreadcrumbs"` RecommendationType string `json:"recommendationType"` Stock int `json:"stock"` DepartmentID int `json:"departmentID"` Shop RecomShop `json:"shop"` ProductLabels []ProductLabel `json:"productLabels"` LabelGroup []LabelGroups `json:"labelGroup"` WholesalePrice []interface{} `json:"wholesalePrice"` Badges []Badge `json:"badges"` Typename string `json:"__typename"` }
type Redirection ¶
type Review ¶
type Review struct { ID string `json:"id"` VariantName string `json:"variantName"` Message string `json:"message"` ProductRating int `json:"productRating"` ReviewCreateTime string `json:"reviewCreateTime"` ReviewCreateTimestamp string `json:"reviewCreateTimestamp"` IsReportable bool `json:"isReportable"` IsAnonymous bool `json:"isAnonymous"` ImageAttachments []ImageAttachment `json:"imageAttachments"` VideoAttachments []interface{} `json:"videoAttachments"` ReviewResponse ReviewResponse `json:"reviewResponse"` User User `json:"user"` LikeDislike LikeDislike `json:"likeDislike"` Stats []ReviewStats `json:"stats"` BadRatingReasonFmt string `json:"badRatingReasonFmt"` Typename string `json:"__typename"` }
type ReviewImageDetail ¶
type ReviewImageDetail struct { Reviews []DetailReview `json:"reviews"` Images []DetailImage `json:"images"` Video []interface{} `json:"video"` MediaCount int `json:"mediaCount"` Typename string `json:"__typename"` }
type ReviewImageList ¶
type ReviewResponse ¶
type ReviewStats ¶
type SearchProductAdParams ¶ added in v1.0.2
type SearchProductAdParams struct { Page int `json:"page"` // 1 Ep string `json:"ep"` // product Item int `json:"item"` // 15 Src string `json:"src"` // directory Device string `json:"device"` // desktop UserId int `json:"user_id"` // 0 MinimumItem int `json:"minimum_item"` // 15 Start int `json:"start"` // 1 NoAutoFill string `json:"no_autofill_range"` // 5-14 Query string `json:"q,omitempty"` Fcity []int `json:"fcity,omitempty"` DepId int `json:"dep_id"` Sort int `json:"ob"` Shipping []int `json:"shipping,omitempty"` Cashback bool `json:"cashbackm,omitempty"` FreeShipping bool `json:"free_shipping,omitempty"` COD bool `json:"cod,omitempty"` IsDiscount bool `json:"is_discount,omitempty"` Bundling bool `json:"bundling,omitempty"` Wholesale bool `json:"wholesale,omitempty"` IsMvcDiscount bool `json:"is_mvc_discount,omitempty"` ShopTier []int `json:"shop_tier,omitempty"` PriceMin int `json:"pmin,omitempty"` PriceMax int `json:"pmax,omitempty"` PreOrder bool `json:"preorder,omitempty"` Condition []int `json:"condition,omitempty"` Rating float64 `json:"rt,omitempty"` }
type SearchProductBanner ¶
type SearchProductChunkHandler ¶ added in v1.1.27
type SearchProductChunkHandler func([]*ProductSearch) error
type SearchProductData ¶
type SearchProductData struct { Banner SearchProductBanner `json:"banner"` BackendFilters string `json:"backendFilters"` IsQuerySafe bool `json:"isQuerySafe"` Ticker Ticker `json:"ticker"` Redirection Redirection `json:"redirection"` Related Related `json:"related"` Suggestion Suggestion `json:"suggestion"` Products SearchProducts `json:"products"` Violation Violation `json:"violation"` Typename string `json:"__typename"` }
type SearchProductQueryResp ¶ added in v1.0.2
type SearchProductQueryResp struct { Data struct { CategoryProducts CategoryProducts `json:"CategoryProducts"` DisplayAdsV3 struct { Data []interface{} `json:"data"` Template []interface{} `json:"template"` Typename string `json:"__typename"` } `json:"displayAdsV3"` } `json:"data"` }
type SearchProductQueryV4Resp ¶
type SearchProductQueryV4Resp struct { Data struct { AceSearchProductV4 struct { Header HeaderSearchProduct `json:"header"` Data SearchProductData `json:"data"` Typename string `json:"__typename"` } `json:"ace_search_product_v4"` } `json:"data"` }
type SearchProductQueryVar ¶ added in v1.0.2
type SearchProductVar ¶ added in v1.0.2
type SearchProductVar struct { Sort string `schema:"ob,omitempty"` Page int `schema:"page"` Rows int `schema:"rows,omitempty"` Device string `schema:"device"` Related bool `schema:"related"` SafeSearch bool `schema:"safe_search"` Scheme string `schema:"scheme"` UserDistrictID string `schema:"user_districtId"` UserCityID string `schema:"user_cityId"` Source string `schema:"source"` TopadsBucket bool `schema:"topads_bucket"` Start int `schema:"start"` PriceMin int `schema:"pmin,omitempty"` PriceMax int `schema:"pmax,omitempty"` Rate []string `schema:"rt,omitempty"` Query string `schema:"q,omitempty"` Fcity []string `schema:"fcity,omitempty"` Condition []string `schema:"condition,omitempty"` ShopTier []string `schema:"shop_tier,omitempty"` CategoryId int `schema:"sc,omitempty"` Identifier string `schema:"identifier,omitempty"` UniqueId string `schema:"unique_id"` Shipping []string `schema:"shipping,omitempty"` PreOrder bool `schema:"preorder,omitempty"` }
func NewGrabSearchProductVar ¶ added in v1.1.24
func NewGrabSearchProductVar(grabTokopedia *legacy.GrabTokopedia) *SearchProductVar
func NewSearchProductVar ¶ added in v1.1.10
func NewSearchProductVar() *SearchProductVar
func (*SearchProductVar) GetQuery ¶ added in v1.1.24
func (v *SearchProductVar) GetQuery() string
type SearchProducts ¶ added in v1.1.27
type SearchProducts []*ProductSearch
func (SearchProducts) Chunks ¶ added in v1.1.31
func (products SearchProducts) Chunks(num int) [][]*ProductSearch
type SearchShop ¶
type SearchShop struct { ID int `json:"id"` Name string `json:"name"` Domain string `json:"domain"` OwnerID int `json:"ownerId"` City string `json:"city"` ShopStatus int `json:"shopStatus"` TagLine string `json:"tagLine"` Desc string `json:"desc"` ReputationScore int `json:"reputationScore"` TotalFave string `json:"totalFave"` IsPowerBadge int `json:"isPowerBadge"` IsPMPro bool `json:"isPMPro"` IsOfficial bool `json:"isOfficial"` URL string `json:"url"` ImageURL string `json:"imageURL"` ReputationImageURL string `json:"reputationImageURL"` ShopLucky string `json:"shopLucky"` Products []ShopProduct `json:"products"` GAKey string `json:"GAKey"` Favorited bool `json:"favorited"` Voucher ShopVoucher `json:"voucher"` Typename string `json:"__typename"` }
type ShipmentInfo ¶
type ShipmentInfo struct { IsAvailable int `json:"isAvailable"` Image string `json:"image"` Name string `json:"name"` Product []ShipmentInfoProduct `json:"product"` Typename string `json:"__typename"` }
type ShipmentInfoProduct ¶
type ShippingLoc ¶
type ShopAssets ¶
type ShopCoreInfoResp ¶
type ShopCoreInfoResp struct { Data struct { ShopInfoByID `json:"shopInfoByID"` } `json:"data"` }
type ShopCoreInfoVar ¶
type ShopFinishRate ¶
type ShopIdStrVar ¶
type ShopIdStrVar struct {
ShopID string `json:"shopID"`
}
type ShopIdVarInt ¶
type ShopIdVarInt struct {
ShopID int64 `json:"shopID"`
}
type ShopInfo ¶
type ShopInfo struct { ShopTier int `json:"shopTier"` BadgeURL string `json:"badgeURL"` ClosedInfo ClosedInfo `json:"closedInfo"` IsOpen int `json:"isOpen"` FavoriteData ShopInfoFavoriteData `json:"favoriteData"` ActiveProduct string `json:"activeProduct"` CreateInfo CreateInfo `json:"createInfo"` ShopAssets ShopAssets `json:"shopAssets"` ShopCore struct { Domain string `json:"domain"` ShopID string `json:"shopID"` Name string `json:"name"` ShopScore int `json:"shopScore"` URL string `json:"url"` OwnerID string `json:"ownerID"` Typename string `json:"__typename"` } `json:"shopCore"` ShopLastActive string `json:"shopLastActive"` Location string `json:"location"` StatusInfo StatusInfo `json:"statusInfo"` IsAllowManage int `json:"isAllowManage"` IsOwner int `json:"isOwner"` OwnerInfo OwnerInfo `json:"ownerInfo"` IsCOD bool `json:"isCOD"` ShopType int `json:"shopType"` TickerData []interface{} `json:"tickerData"` PartnerLabel string `json:"partnerLabel"` Typename string `json:"__typename"` }
type ShopInfoByID ¶
type ShopInfoByID struct { Result []ShopInfoByIDResult `json:"result"` Error Error `json:"error"` Typename string `json:"__typename"` }
type ShopInfoByIDResult ¶
type ShopInfoByIDResult struct { ShopCore ShopCore `json:"shopCore"` CreateInfo CreateInfo `json:"createInfo"` FavoriteData FavoriteData `json:"favoriteData"` ActiveProduct int `json:"activeProduct"` ShopAssets ShopAssets `json:"shopAssets"` Location string `json:"location"` IsAllowManage int `json:"isAllowManage"` BranchLinkDomain string `json:"branchLinkDomain"` IsOpen int `json:"isOpen"` ShipmentInfo []ShipmentInfo `json:"shipmentInfo"` ShippingLoc ShippingLoc `json:"shippingLoc"` ShopStats ShopStats `json:"shopStats"` StatusInfo StatusInfo `json:"statusInfo"` ClosedInfo ClosedInfo `json:"closedInfo"` BbInfo []interface{} `json:"bbInfo"` GoldOS GoldOS `json:"goldOS"` ShopSnippetURL string `json:"shopSnippetURL"` CustomSEO CustomSEO `json:"customSEO"` IsQA bool `json:"isQA"` IsGoApotik bool `json:"isGoApotik"` PartnerInfo []PartnerInfo `json:"partnerInfo"` EpharmacyInfo EpharmacyInfo `json:"epharmacyInfo"` Typename string `json:"__typename"` }
type ShopInfoFavoriteData ¶
type ShopNoteResp ¶
type ShopNoteResp struct { Data struct { ShopNotesByShopID ShopNotesByShopID `json:"shopNotesByShopID"` } `json:"data"` }
type ShopNoteResults ¶
type ShopNoteVar ¶
type ShopNotesByShopID ¶
type ShopNotesByShopID struct { Result []ShopNoteResults `json:"result"` Error Error `json:"error"` Typename string `json:"__typename"` }
type ShopPageGetLayout ¶
type ShopPageGetLayoutV2Resp ¶
type ShopPageGetLayoutV2Resp []struct { Data struct { ShopPageGetLayout ShopPageGetLayout `json:"shopPageGetLayout"` } `json:"data"` }
type ShopPageGetLayoutV2Var ¶
type ShopProduct ¶
type ShopProductData ¶
type ShopProductData struct { Name string `json:"name"` ProductURL string `json:"product_url"` ProductID string `json:"product_id"` Price Price `json:"price"` PrimaryImage PrimaryImage `json:"primary_image"` Flags Flags `json:"flags"` Campaign Campaign `json:"campaign"` Label []Label `json:"label"` LabelGroups []LabelGroups `json:"label_groups"` Badge []Badge `json:"badge"` Stats Stats `json:"stats"` Category Category `json:"category"` Typename string `json:"__typename"` }
type ShopProductResp ¶
type ShopProductResp struct { Data struct { GetShopProduct GetShopProduct `json:"GetShopProduct"` } `json:"data"` }
type ShopProductVar ¶
type ShopProductVar struct { Sid string `json:"sid"` Page int `json:"page"` PerPage int `json:"perPage"` EtalaseID string `json:"etalaseId"` Sort int `json:"sort"` UserDistrictID string `json:"user_districtId"` UserCityID string `json:"user_cityId"` UserLat string `json:"user_lat"` UserLong string `json:"user_long"` }
func NewShopProductVar ¶ added in v1.1.10
func NewShopProductVar(shopId string) *ShopProductVar
type ShopRating ¶
type ShopRating struct { Detail []RatingDetail `json:"detail"` TotalRating int `json:"totalRating"` RatingScore string `json:"ratingScore"` Typename string `json:"__typename"` }
type ShopReputation ¶
type ShopSatisfaction ¶
type ShopSatisfaction struct { RecentOneMonth RecentOneMonth `json:"recentOneMonth"` Typename string `json:"__typename"` }
type ShopSpeedQueryResp ¶
type ShopStatisticQueryData ¶
type ShopStatisticQueryData struct { ShopSatisfaction ShopSatisfaction `json:"shopSatisfaction"` ShopRating ShopRating `json:"shopRating"` ShopReputation []ShopReputation `json:"shopReputation"` }
type ShopStatisticQueryResp ¶
type ShopStatisticQueryResp struct {
Data ShopStatisticQueryData `json:"data"`
}
type ShopStatisticQueryVar ¶
type ShopSuggestion ¶
type ShopVoucher ¶
type ShopVoucher struct { FreeShipping bool `json:"freeShipping"` Cashback VoucherCashback `json:"cashback"` Typename string `json:"__typename"` }
type ShopVoucherQueryResp ¶
type ShopVoucherQueryResp struct { Data struct { GetPublicMerchantVoucherList GetPublicMerchantVoucherList `json:"getPublicMerchantVoucherList"` } `json:"data"` }
type SortProduct ¶
type State ¶
type State struct { IsMasked bool `json:"isMasked"` IsLiked bool `json:"isLiked,omitempty"` AllowLike bool `json:"allowLike,omitempty"` IsYours bool `json:"isYours"` AllowReport bool `json:"allowReport"` AllowDelete bool `json:"allowDelete"` AllowReply bool `json:"allowReply,omitempty"` IsFollowed bool `json:"isFollowed,omitempty"` AllowFollow bool `json:"allowFollow,omitempty"` Typename string `json:"__typename"` }
type Stats ¶
type Stats struct { CountView int `json:"countView,omitempty"` CountReview int `json:"countReview,omitempty"` CountTalk int `json:"countTalk,omitempty"` ReviewCount int `json:"reviewCount,omitempty"` Rating int `json:"rating,omitempty"` AverageRating string `json:"averageRating,omitempty"` Typename string `json:"__typename"` }
type StatusInfo ¶
type StockWording ¶
type Suggestion ¶
type Suggestion struct { CurrentKeyword string `json:"currentKeyword"` Suggestion string `json:"suggestion"` SuggestionCount int `json:"suggestionCount"` Instead string `json:"instead"` InsteadCount int `json:"insteadCount"` Query string `json:"query"` Text string `json:"text"` ComponentID string `json:"componentId"` TrackingOption int `json:"trackingOption"` Typename string `json:"__typename"` }
type ThematicCampaign ¶
type TopadsProductQueryResp ¶
type TopadsProductQueryResp struct { Data struct { DisplayAdsV3 struct { Data []struct { ClickTrackURL string `json:"clickTrackUrl"` ProductWishlistURL string `json:"product_wishlist_url"` Product struct { ID string `json:"id"` Name string `json:"name"` Wishlist bool `json:"wishlist"` Image Image `json:"image"` URL string `json:"url"` RelativeURI string `json:"relative_uri"` Price string `json:"price"` WholeSalePrice []interface{} `json:"wholeSalePrice"` CountTalkFormat string `json:"count_talk_format"` CountReviewFormat string `json:"countReviewFormat"` Category Category `json:"category"` CategoryBreadcrumb string `json:"categoryBreadcrumb"` Preorder bool `json:"preorder"` ProductWholesale bool `json:"product_wholesale"` FreeReturn string `json:"free_return"` IsNewProduct bool `json:"isNewProduct"` Cashback string `json:"cashback"` Rating int `json:"rating"` RatingAverage string `json:"ratingAverage"` TopLabel []interface{} `json:"top_label"` BottomLabel []interface{} `json:"bottomLabel"` LabelGroups []LabelGroups `json:"labelGroups"` Campaign struct { DiscountPercentage int `json:"discountPercentage"` OriginalPrice string `json:"originalPrice"` Typename string `json:"__typename"` } `json:"campaign"` CustomvideoURL string `json:"customvideo_url"` Typename string `json:"__typename"` } `json:"product"` Shop ProductShop `json:"shop"` Tag int `json:"tag"` Typename string `json:"__typename"` } `json:"data"` Header struct { Meta Meta `json:"meta"` Typename string `json:"__typename"` } `json:"header"` Typename string `json:"__typename"` } `json:"displayAdsV3"` } `json:"data"` }
type UserLocation ¶
type VariantCategoryCombinationResp ¶
type VariantCategoryCombinationResp struct { Data struct { GetVariantCategoryCombination GetVariantCategoryCombination `json:"getVariantCategoryCombination"` } `json:"data"` }
type VariantDetail ¶
type VariantDetailUnit ¶
type VariantOption ¶
type VariantStock ¶
type VariantUnitValue ¶
type Violation ¶
type Violation struct { HeaderText string `json:"headerText"` DescriptionText string `json:"descriptionText"` ImageURL string `json:"imageURL"` CtaURL string `json:"ctaURL"` CtaApplink string `json:"ctaApplink"` ButtonText string `json:"buttonText"` ButtonType string `json:"buttonType"` Typename string `json:"__typename"` }
type VoucherCashback ¶
type VoucherType ¶
type Vouchers ¶
type Vouchers struct { Amount Amount `json:"amount"` InUseExpiry string `json:"inUseExpiry"` MinimumSpend int `json:"minimumSpend"` MinimumSpendFormatted string `json:"minimumSpendFormatted"` Owner Owner `json:"owner"` Status Status `json:"status"` ValidThru string `json:"validThru"` VoucherID int `json:"voucherID"` Name string `json:"name"` VoucherCode string `json:"voucherCode"` VoucherType VoucherType `json:"voucherType"` Banner Banner `json:"banner"` Tnc string `json:"tnc"` Typename string `json:"__typename"` }
type WarehouseInfo ¶
type Widget ¶
type Widget struct { WidgetID int `json:"widgetID"` WidgetMasterID int `json:"widgetMasterID"` LayoutOrder int `json:"layoutOrder"` Name string `json:"name"` Type string `json:"type"` Header WidgetHeader `json:"header"` Data []WidgetData `json:"data"` Typename string `json:"__typename"` }
type WidgetData ¶
type WidgetData struct { CampaignID string `json:"campaignID"` Name string `json:"name"` Description string `json:"description"` StartDate string `json:"startDate"` EndDate string `json:"endDate"` StatusCampaign string `json:"statusCampaign"` TimeDescription string `json:"timeDescription"` TimeCounter string `json:"timeCounter"` TotalNotify int `json:"totalNotify"` TotalNotifyWording string `json:"totalNotifyWording"` TotalProduct int `json:"totalProduct"` TotalProductWording string `json:"totalProductWording"` BackgroundGradientColor BackgroundGradientColor `json:"backgroundGradientColor"` DynamicRule DynamicRule `json:"dynamicRule"` Banners []Banners `json:"banners"` Products []Products `json:"products"` Typename string `json:"__typename"` }
type WidgetHeader ¶
type WidgetHeader struct { Ratio string `json:"ratio"` SizeOption string `json:"sizeOption,omitempty"` Title string `json:"title"` Subtitle string `json:"subtitle,omitempty"` CtaText string `json:"ctaText,omitempty"` CtaLink string `json:"ctaLink,omitempty"` Cover string `json:"cover,omitempty"` IsATC int `json:"isATC,omitempty"` IsActive int `json:"isActive,omitempty"` EtalaseID string `json:"etalaseID,omitempty"` IsShowEtalaseName int `json:"isShowEtalaseName,omitempty"` Typename string `json:"__typename"` }
type WidgetRequest ¶
Source Files ¶
- ace_search_shop_model.go
- category_model.go
- discussion_data_by_product_id_model.go
- filter_sort_product_model.go
- get_drogon_annotation_model.go
- header_main_data_model.go
- loc_district_recommendation_model.go
- pdp_get_data_p2_model.go
- pdp_get_layout_model.go
- pdp_get_review_image_query_model.go
- pdp_shop_note_model.go
- product_rating_and_topics_model.go
- product_review_list_model.go
- rates_estimate_model.go
- recom_widget_model.go
- search_product_model.go
- search_product_query_v4_model.go
- shop_core_info_model.go
- shop_detail_model.go
- shop_product_model.go
- shop_speed_query_model.go
- toapads_product_query_model.go
- variant_category_combination.go
Click to show internal directories.
Click to hide internal directories.