Beispiel #1
0
        /// <summary>
        /// call GeteBayDetails to get eBay details for a given site
        /// </summary>
        /// <returns>generic object</returns>
        protected override object callApi()
        {
            GeteBayDetailsCall api = new GeteBayDetailsCall(context);
            DetailNameCodeTypeCollection dns = this.getDetailsNames();
            api.GeteBayDetails(dns);

            return api.ApiResponse;
        }
		//get eBay Details
		public static GeteBayDetailsResponseType GetShippingServices(ApiContext apiContext)
		{
				GeteBayDetailsCall api = new GeteBayDetailsCall(apiContext);
				DetailNameCodeTypeCollection names=new DetailNameCodeTypeCollection();
				names.Add(DetailNameCodeType.ShippingLocationDetails);
				names.Add(DetailNameCodeType.ShippingServiceDetails);
				api.GeteBayDetails(null);
				return api.ApiResponse;
		}
Beispiel #3
0
        /// <summary>
        /// get last update time from site
        /// </summary>
        /// <returns>string</returns>
        protected override string getLastUpdateTime()
        {
            GeteBayDetailsCall api = new GeteBayDetailsCall(context);
            //set output selector
            api.ApiRequest.OutputSelector = new StringCollection(new String[] { "UpdateTime" });

            //execute call
            DetailNameCodeTypeCollection dns = this.getDetailsNames();
            api.GeteBayDetails(dns);

            DateTime updateTime = api.ApiResponse.UpdateTime;

            return updateTime.ToString("yyyy-MM-dd-hh-mm-ss");
        }
Beispiel #4
0
        private GeteBayDetailsResponseType makeApiCall(DetailNameCodeTypeCollection detailNames, SiteCodeType site)
        {
            SiteCodeType savedSite = _site;
            _apiContext.Site = site;
            GeteBayDetailsCall api = new GeteBayDetailsCall(_apiContext);
            DetailLevelCodeTypeCollection detailLevels = new DetailLevelCodeTypeCollection( new DetailLevelCodeType[] {DetailLevelCodeType.ReturnAll});
            api.DetailLevelList = detailLevels;
            api.GeteBayDetails(detailNames);
            _apiContext.Site = savedSite;

            return api.ApiResponse;
        }