Versions in this module Expand all Collapse all v0 v0.2.0 May 25, 2026 Changes in this version + type AddItemParams struct + AttributeList []ItemAttribute + Brand *ItemBrand + CategoryID int64 + Condition string + Description string + Dimension *Dimension + Image ItemImage + ItemName string + ItemSKU string + ItemStatus string + LogisticInfo []LogisticInfo + NormalStock *int + OriginalPrice float64 + PreOrder *ItemPreOrder + Weight float64 + type AddressListResult struct + AddressList []LogisticsAddress + ShowPickupAddress bool + type Attribute struct + AttributeID int64 + AttributeUnit []string + AttributeValueList []AttributeValue + DateFormatType string + DisplayAttributeName string + FormatType string + InputType string + InputValidationType string + IsMandatory bool + OriginalAttributeName string + type AttributeParentBrand struct + ParentBrandID int64 + type AttributeParentValue struct + ParentAttributeID int64 + ParentValueID int64 + type AttributeValue struct + DisplayValueName string + OriginalValueName string + ParentAttributeList []AttributeParentValue + ParentBrandList []AttributeParentBrand + ValueID int64 + ValueUnit string + type AttributesResult struct + AttributeList []Attribute + type Brand struct + BrandID int64 + DisplayBrandName string + OriginalBrandName string + type BrandListParams struct + CategoryID int64 + Offset int + PageSize int + Status int + type BrandListResult struct + BrandList []Brand + HasNextPage bool + InputType string + IsMandatory bool + NextOffset int + type BuyerInvoiceInfo struct + Error string + InvoiceDetail json.RawMessage + InvoiceType string + IsRequestable bool + OrderSN string + type CancelItem struct + ItemID int64 + ModelID int64 + type Category struct + CategoryID int64 + DisplayCategoryName string + HasChildren bool + OriginalCategoryName string + ParentCategoryID int64 + type CategoryRecommendResult struct + CategoryID []int64 + type CategoryResult struct + CategoryList []Category + type ChannelListResult struct + LogisticsChannelList []LogisticsChannel type Client + func (c *Client) AddItem(ctx context.Context, p AddItemParams) (*ItemResult, error) + func (c *Client) AddItemRaw(ctx context.Context, body any) (*ItemResult, error) + func (c *Client) AddModel(ctx context.Context, itemID int64, models []ModelInit) ([]ModelInfo, error) + func (c *Client) CancelOrder(ctx context.Context, orderSN, reason string, items []CancelItem) (int64, error) + func (c *Client) CategoryRecommend(ctx context.Context, itemName string) (*CategoryRecommendResult, error) + func (c *Client) ConfirmReturn(ctx context.Context, returnSN string) error + func (c *Client) CreateShippingDocument(ctx context.Context, orders []CreateShippingDocumentOrder) (*CreateShippingDocumentResult, error) + func (c *Client) DeleteItem(ctx context.Context, itemID int64) error + func (c *Client) DeleteModel(ctx context.Context, itemID, modelID int64) error + func (c *Client) DisputeReturn(ctx context.Context, p DisputeReturnParams) error + func (c *Client) DownloadShippingDocument(ctx context.Context, orders []ShippingDocumentOrder, ...) ([]byte, error) + func (c *Client) GetAddressList(ctx context.Context) (*AddressListResult, error) + func (c *Client) GetAttributes(ctx context.Context, categoryID int64, language string) (*AttributesResult, error) + func (c *Client) GetBrandList(ctx context.Context, p BrandListParams) (*BrandListResult, error) + func (c *Client) GetBuyerInvoiceInfo(ctx context.Context, orderSNList []string) ([]BuyerInvoiceInfo, error) + func (c *Client) GetCategory(ctx context.Context, language string) (*CategoryResult, error) + func (c *Client) GetChannelList(ctx context.Context) (*ChannelListResult, error) + func (c *Client) GetEscrowDetail(ctx context.Context, orderSN string) (*EscrowDetail, error) + func (c *Client) GetEscrowList(ctx context.Context, p EscrowListParams) (*EscrowListResult, error) + func (c *Client) GetItemExtraInfo(ctx context.Context, itemIDs []int64) (*ItemExtraInfoResult, error) + func (c *Client) GetItemLimit(ctx context.Context, categoryID int64) (*ItemLimit, error) + func (c *Client) GetMassShippingParameter(ctx context.Context, orderSNList []string) (*MassShippingParameter, error) + func (c *Client) GetModelList(ctx context.Context, itemID int64) (*ModelListResult, error) + func (c *Client) GetPaymentMethodList(ctx context.Context) (*PaymentMethodListResult, error) + func (c *Client) GetPayoutDetail(ctx context.Context, p PayoutDetailParams) (*PayoutDetailResult, error) + func (c *Client) GetReturnDetail(ctx context.Context, returnSN string) (*ReturnInfo, error) + func (c *Client) GetReturnList(ctx context.Context, p ReturnListParams) (*ReturnListResult, error) + func (c *Client) GetShipmentList(ctx context.Context, cursor string, pageSize int) (*ShipmentListResult, error) + func (c *Client) GetShippingDocumentParameter(ctx context.Context, orders []ShippingDocumentOrder) (*ShippingDocumentParameterResult, error) + func (c *Client) GetShippingDocumentResult(ctx context.Context, orders []GetShippingDocumentResultOrder) (*ShippingDocumentResult, error) + func (c *Client) GetShippingParameter(ctx context.Context, orderSN string) (*ShippingParameter, error) + func (c *Client) GetTrackingInfo(ctx context.Context, orderSN string) (*TrackingInfo, error) + func (c *Client) GetTrackingNumber(ctx context.Context, orderSN string) (string, error) + func (c *Client) GetWalletTransactionList(ctx context.Context, p WalletTransactionParams) (*WalletTransactionResult, error) + func (c *Client) HandleBuyerCancellation(ctx context.Context, orderSN, operation string) (int64, error) + func (c *Client) InitTierVariation(ctx context.Context, itemID int64, tiers []TierVariation, models []ModelInit) (*ModelListResult, error) + func (c *Client) QueryReturnProof(ctx context.Context, returnSN string) (*ReturnProof, error) + func (c *Client) SetNote(ctx context.Context, orderSN, note string) error + func (c *Client) ShipOrder(ctx context.Context, p ShipOrderParams) error + func (c *Client) UnlistItem(ctx context.Context, items []UnlistEntry) (*UnlistItemResult, error) + func (c *Client) UpdateItem(ctx context.Context, p UpdateItemParams) (*ItemResult, error) + func (c *Client) UpdateItemRaw(ctx context.Context, body any) (*ItemResult, error) + func (c *Client) UpdateModel(ctx context.Context, itemID int64, models []ModelUpdate) error + func (c *Client) UpdatePrice(ctx context.Context, itemID int64, prices []PriceUpdate) (*UpdatePriceResult, error) + func (c *Client) UpdateStock(ctx context.Context, itemID int64, stock []StockUpdate) (*UpdateStockResult, error) + func (c *Client) UpdateTierVariation(ctx context.Context, itemID int64, tiers []TierVariation) error + type CreateShippingDocumentEntry struct + FailError string + FailMessage string + OrderSN string + PackageNumber string + type CreateShippingDocumentOrder struct + OrderSN string + PackageNumber string + ShippingDocumentType string + TrackingNumber string + type CreateShippingDocumentResult struct + ResultList []CreateShippingDocumentEntry + type Dimension struct + PackageHeight int + PackageLength int + PackageWidth int + type DisputeReturnParams struct + DisputeReason string + DisputeTextReason string + Email string + Images []string + ReturnSN string + type EscrowDetail struct + BuyerUserName string + OrderIncome OrderIncome + OrderSN string + ReturnOrderSNList []string + type EscrowListItem struct + EscrowReleaseTime int64 + OrderSN string + PayoutAmount float64 + type EscrowListParams struct + PageNo int + PageSize int + ReleaseTimeFrom int64 + ReleaseTimeTo int64 + type EscrowListResult struct + EscrowList []EscrowListItem + More bool + type GetShippingDocumentResultOrder struct + OrderSN string + PackageNumber string + ShippingDocumentType string + type ItemAttribute struct + AttributeID int64 + AttributeValueList []ItemAttributeValue + type ItemAttributeValue struct + OriginalValueName string + ValueID int64 + ValueUnit string + type ItemBrand struct + BrandID int64 + OriginalBrandName string + type ItemExtraInfo struct + CommentCount int + ItemID int64 + Likes int + RatingStar struct{ ... } + Sale int + Views int + type ItemExtraInfoResult struct + ItemList []ItemExtraInfo + type ItemImage struct + ImageIDList []string + ImageURLList []string + type ItemLimit struct + ItemImageMax int + ItemImageMin int + ItemNameMax int + ItemNameMin int + PriceLimit PriceLimit + StockLimit int + type ItemPreOrder struct + DaysToShip *int + IsPreOrder bool + type ItemResult struct + CreateTime int64 + ItemID int64 + ItemStatus string + UpdateTime int64 + type LogisticInfo struct + Enabled bool + IsFree bool + LogisticID int64 + ShippingFee float64 + SizeID int64 + type LogisticsAddress struct + Address string + AddressFlag []string + AddressID int64 + AddressType []string + City string + District string + Region string + State string + Town string + Zipcode string + type LogisticsChannel struct + CODEnabled bool + Enabled bool + FeeType string + ItemMaxDimension LogisticsDimension + LogisticsChannelID int64 + LogisticsChannelName string + Preferred bool + SizeList []LogisticsSize + VolumeLimit LogisticsVolumeLimit + WeightLimit LogisticsWeightLimit + type LogisticsDimension struct + Height float64 + Length float64 + Unit string + Width float64 + type LogisticsSize struct + DefaultPrice float64 + Name string + SizeID string + type LogisticsVolumeLimit struct + ItemMaxVolume float64 + ItemMinVolume float64 + type LogisticsWeightLimit struct + ItemMaxWeight float64 + ItemMinWeight float64 + type MassShippingParameter struct + InfoNeeded ShippingInfoNeeded + type ModelInfo struct + ModelID int64 + ModelSKU string + PriceInfo []PriceInfo + PromotionID int64 + StockInfo []ModelStockInfo + TierIndex []int + type ModelInit struct + ModelSKU string + NormalStock int + OriginalPrice float64 + TierIndex []int + type ModelListResult struct + Model []ModelInfo + TierVariation []TierVariation + type ModelStockInfo struct + CurrentStock int + NormalStock int + ReservedStock int + StockLocationID string + StockType int + type ModelUpdate struct + ModelID int64 + ModelSKU string + type OrderIncome struct + ActualShippingFee float64 + BuyerPaidShippingFee float64 + BuyerTotalAmount float64 + Coins float64 + CommissionFee float64 + EscrowAmount float64 + OriginalPrice float64 + SellerDiscount float64 + SellerReturnRefund float64 + SellerTransactionFee float64 + ServiceFee float64 + ShopeeDiscount float64 + ShopeeShippingRebate float64 + VoucherFromSeller float64 + VoucherFromShopee float64 + type PaymentMethod struct + PaymentMethodName string + type PaymentMethodListResult struct + PaymentMethodList []PaymentMethod + type PayoutDetailItem struct + Currency string + PayoutAmount float64 + PayoutTime int64 + type PayoutDetailParams struct + PageNo int + PageSize int + PayoutTimeFrom int64 + PayoutTimeTo int64 + type PayoutDetailResult struct + More bool + PayoutList []PayoutDetailItem + type PriceFailure struct + FailedReason string + ModelID int64 + type PriceLimit struct + MaxLimit float64 + MinLimit float64 + type PriceSuccess struct + ModelID int64 + OriginalPrice float64 + type PriceUpdate struct + ModelID int64 + OriginalPrice float64 + type ReturnInfo struct + CreateTime int64 + Currency string + DueDate int64 + Item []ReturnItem + OrderSN string + Reason string + RefundAmount float64 + ReturnSN string + ReturnStatus string + TextReason string + TrackingNumber string + UpdateTime int64 + User *ReturnUser + type ReturnItem struct + ItemID int64 + ItemName string + ItemPrice float64 + ItemSKU string + ModelID int64 + ModelSKU string + QuantityPurchased int + type ReturnListParams struct + CreateTimeFrom int64 + CreateTimeTo int64 + PageNo int + PageSize int + ReturnStatus string + type ReturnListResult struct + More bool + Return []ReturnInfo + type ReturnProof struct + PhotoList []string + VideoList []string + type ReturnUser struct + Email string + Portrait string + Username string + type ShipDropoff struct + BranchID int64 + SenderRealName string + Slug string + TrackingNumber string + type ShipOrderParams struct + Dropoff *ShipDropoff + OrderSN string + PackageNumber string + Pickup *ShipPickup + type ShipPickup struct + AddressID int64 + PickupTimeID string + TrackingNumber string + type ShipmentListResult struct + More bool + NextCursor string + OrderList []ShipmentOrder + type ShipmentOrder struct + OrderSN string + PackageNumber string + type ShippingDocumentOrder struct + OrderSN string + PackageNumber string + type ShippingDocumentParameter struct + FailError string + FailMessage string + OrderSN string + PackageNumber string + SelectableShippingDocumentType []string + SuggestShippingDocumentType string + type ShippingDocumentParameterResult struct + ResultList []ShippingDocumentParameter + type ShippingDocumentResult struct + ResultList []ShippingDocumentResultEntry + type ShippingDocumentResultEntry struct + FailError string + FailMessage string + OrderSN string + PackageNumber string + Status string + type ShippingInfoNeeded struct + Dropoff []string + NonIntegrated []string + Pickup []string + type ShippingParameter struct + Dropoff json.RawMessage + InfoNeeded ShippingInfoNeeded + Pickup json.RawMessage + type StockFailure struct + FailedReason string + ModelID int64 + type StockSuccess struct + ModelID int64 + NormalStock int + type StockUpdate struct + ModelID int64 + NormalStock int + type TierVariation struct + Name string + OptionList []TierVariationOption + type TierVariationOption struct + Image *TierVariationOptionImage + Option string + type TierVariationOptionImage struct + ImageID string + ImageURL string + type TrackingEvent struct + Description string + LogisticsStatus string + UpdateTime int64 + type TrackingInfo struct + LogisticsStatus string + OrderSN string + TrackingInfo []TrackingEvent + type UnlistEntry struct + ItemID int64 + Unlist bool + type UnlistFailure struct + FailedReason string + ItemID int64 + type UnlistItemResult struct + FailureList []UnlistFailure + SuccessList []UnlistSuccess + type UnlistSuccess struct + ItemID int64 + Unlist bool + type UpdateItemParams struct + AttributeList []ItemAttribute + Brand *ItemBrand + CategoryID int64 + Condition string + Description string + Dimension *Dimension + Image *ItemImage + ItemID int64 + ItemName string + ItemSKU string + LogisticInfo []LogisticInfo + PreOrder *ItemPreOrder + Weight float64 + type UpdatePriceResult struct + FailureList []PriceFailure + SuccessList []PriceSuccess + type UpdateStockResult struct + FailureList []StockFailure + SuccessList []StockSuccess + type WalletTransaction struct + Amount float64 + CreateTime int64 + CurrentBalance float64 + OrderSN string + Reason string + Status string + TransactionID int64 + TransactionType string + WalletType string + type WalletTransactionParams struct + CreateTimeFrom int64 + CreateTimeTo int64 + PageNo int + PageSize int + TransactionType string + WalletType string + type WalletTransactionResult struct + More bool + TransactionList []WalletTransaction v0.1.0 May 25, 2026 Changes in this version + type APIError struct + Err string + Message string + RequestID string + func (e *APIError) Error() string + type Client struct + func NewClient(cfg Config) *Client + func (c *Client) AuthURL(redirectURL string) string + func (c *Client) GetAccessToken(ctx context.Context, code string, shopID int64) (*TokenResponse, error) + func (c *Client) GetItemBaseInfo(ctx context.Context, itemIDs []int64) (*ItemBaseInfoResult, error) + func (c *Client) GetItemList(ctx context.Context, p ItemListParams) (*ItemListResult, error) + func (c *Client) GetOrderDetail(ctx context.Context, orderSNList []string, optionalFields ...string) (*OrderDetailResult, error) + func (c *Client) GetOrderList(ctx context.Context, p OrderListParams) (*OrderListResult, error) + func (c *Client) GetShopInfo(ctx context.Context) (*ShopInfo, error) + func (c *Client) RefreshAccessToken(ctx context.Context, refreshToken string, shopID int64) (*TokenResponse, error) + func (c *Client) SetAccessToken(token string) + func (c *Client) SetShopID(shopID int64) + func (c *Client) ShopID() int64 + type Config struct + AccessToken string + BaseURL string + HTTPClient *http.Client + PartnerID int64 + PartnerKey string + Region Region + ShopID int64 + type ItemBaseInfo struct + CategoryID int64 + CreateTime int64 + Description string + ItemID int64 + ItemName string + ItemSKU string + ItemStatus string + PriceInfo []PriceInfo + StockInfoV2 json.RawMessage + UpdateTime int64 + Weight string + type ItemBaseInfoResult struct + ItemList []ItemBaseInfo + type ItemListEntry struct + ItemID int64 + ItemStatus string + UpdateTime int64 + type ItemListParams struct + ItemStatus string + Offset int + PageSize int + type ItemListResult struct + HasNextPage bool + Item []ItemListEntry + NextOffset int + TotalCount int + type OrderDetail struct + BuyerUserID int64 + BuyerUsername string + CreateTime int64 + Currency string + ItemList []OrderItem + OrderSN string + OrderStatus string + PaymentMethod string + Region string + ShippingCarrier string + TotalAmount float64 + UpdateTime int64 + type OrderDetailResult struct + OrderList []OrderDetail + type OrderItem struct + ItemID int64 + ItemName string + ItemSKU string + ModelDiscountedPrice float64 + ModelID int64 + ModelName string + ModelOriginalPrice float64 + ModelQuantityPurchased int + type OrderListItem struct + OrderSN string + type OrderListParams struct + Cursor string + OrderStatus string + PageSize int + TimeFrom int64 + TimeRangeField string + TimeTo int64 + type OrderListResult struct + More bool + NextCursor string + OrderList []OrderListItem + type PriceInfo struct + Currency string + CurrentPrice float64 + OriginalPrice float64 + type Region int + const RegionChina + const RegionChinaSandbox + const RegionGlobal + const RegionSandbox + type ShopInfo struct + AuthTime int64 + ExpireTime int64 + IsCB bool + IsSIP bool + MerchantID int64 + Region string + ShopName string + Status string + type TokenResponse struct + AccessToken string + ExpireIn int64 + RefreshToken string