Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var SiteIds = map[string]int{
"US": 0,
"GB": 3,
"SG": 216,
"FR": 71,
"FRBE": 0,
"FRCA": 0,
"MY": 207,
"NL": 146,
"AT": 16,
"AU": 15,
"CH": 193,
"DE": 77,
"ENCA": 0,
"ES": 186,
"HK": 201,
"IE": 205,
"IN": 203,
"IT": 101,
"MOTOR": 0,
"NLBE": 0,
"PH": 211,
"PL": 212,
}
SiteIds site IDs
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Domain string Debug bool Warnings bool Errors bool URI string DevID string AppID string CertID string Token string SiteID int Version int HTTPS bool Timeout int TrackingID string TrackingPartnerCode string RequestEncoding string ResponseEncoding string }
Config data
type Connection ¶
type Connection interface { Execute(req Request) (Response, error) BuildRequestHeader() map[string]string BuildRequestData() string }
Connection interface
type EbayResponse ¶
type EbayResponse struct { EBayTime string `xml:"EBayTime"` Timestamp time.Time `xml:"Timestamp"` Ack string `xml:"Ack"` Build string `xml:"Build"` Version string `xml:"Version"` Error ResponseErrors `xml:"Errors"` }
EbayResponse data
func (EbayResponse) Acknowledge ¶
func (r EbayResponse) Acknowledge() string
Acknowledge return acknowledge info
func (EbayResponse) Failure ¶
func (r EbayResponse) Failure() bool
Failure return true if failure, otherwise false
func (EbayResponse) ResponseErrors ¶
func (r EbayResponse) ResponseErrors() Errors
ResponseErrors return response errors
func (EbayResponse) Success ¶
func (r EbayResponse) Success() bool
Success return true if success, otherwise false
func (EbayResponse) Warning ¶
func (r EbayResponse) Warning() bool
Warning return true if warning, otherwise false
type Request ¶
type Request interface { Name() string BodyXML() string ParseResponse(content []byte) (Response, error) }
Request interface
type Response ¶
type Response interface { Success() bool Failure() bool Acknowledge() string Warning() bool ResponseErrors() Errors }
Response interface
type ResponseError ¶
type ResponseError struct { Code string `xml:"Code"` ErrorClass string `xml:"ErrorClass"` ShortMessage string `xml:"ShortMessage"` LongMessage string `xml:"LongMessage"` ErrorCode string `xml:"ErrorCode"` SeverityCode string `xml:"SeverityCode"` Severity string `xml:"Severity"` Line string `xml:"Line"` Column string `xml:"Column"` ErrorClassification string `xml:"ErrorClassification"` }
ResponseError data
func (ResponseError) Error ¶
func (err ResponseError) Error() string
type ResponseErrors ¶
type ResponseErrors struct {
Items []ResponseError `xml:"Error"`
}
ResponseErrors data
func (ResponseErrors) Error ¶
func (err ResponseErrors) Error() string
type Shopping ¶
Shopping object
func (*Shopping) BuildRequestData ¶
BuildRequestData build the request data
func (*Shopping) BuildRequestHeader ¶
BuildRequestHeader build the request header
type Trading ¶
Trading object
func (*Trading) BuildRequestData ¶
BuildRequestData build the request data
func (*Trading) BuildRequestHeader ¶
BuildRequestHeader build the request header
Click to show internal directories.
Click to hide internal directories.