c# - 亚马逊 MWS C# 产品 GetCompetitivePricingForSKU 抛出异常

标签 c# amazon-mws

当我尝试为产品索取有竞争力的价格时,我总是得到一个

MarketplaceWebServiceProductsException

Message 是空的,TargetSite 给我

T 调用[T](MWSClientCsRuntime.IMwsRequestType1[T], MWSClientCsRuntime.IMwsObject)

这是我正在运行的代码

        MarketplaceWebServiceProducts.MarketplaceWebServiceProducts service = new MarketplaceWebServiceProductsClient (config.MWS_AccessKeyId, config.MWS_secretKey);

        SellerSKUListType list = new SellerSKUListType ();

        List<String> SKUList = new List<String> ();
        SKUList.Add (SKU);

        list.SellerSKU = SKUList;

        GetCompetitivePricingForSKURequest request = new GetCompetitivePricingForSKURequest ();

        request.MarketplaceId = config.MWS_MarketPlaceId;
        request.SellerId = config.MWS_SellerId;
        request.SellerSKUList = list;

        GetCompetitivePricingForSKUResponse response = service.GetCompetitivePricingForSKU (request);

最佳答案

您是否尝试指定应用程序名称和应用程序版本?

var config = new MarketplaceWebServiceProductsConfig();
config.ServiceURL = "https://mws.amazonservices.com/Products/2011-10-01";
config.SetUserAgent(ApplicationName, ApplicationVersion);

var service = new MarketplaceWebServiceProductsClient(ApplicationName, ApplicationVersion, MWSaccessKey, MWSsecretKey, config);

关于c# - 亚马逊 MWS C# 产品 GetCompetitivePricingForSKU 抛出异常,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25181347/

相关文章:

php - 同一台服务器上的两个 PHP 应用程序之间的通信?

c# - 通过反射排除接口(interface)实现成员

c# - 为什么我不能访问 DelegateCommand 的执行委托(delegate)中的实例属性?

c# - 亚马逊 MWS 的产品 Feed

delphi - 额外的 HTTP header 会影响 MWS Feed API 提交吗?

amazon-sqs - Amazon SQS 队列未接收消息

C# SQLite 参数化选择使用 LIKE

c# - 如何从 Controller 获取角色名称到 Custom AuthorizeAttribute 类?

c# - 如何在 MVVM 中启动非模态对话框?