简体   繁体   English

如何为Amazon MWS报告API设置报告类型

[英]How do I set report type for Amazon MWS report api

I have ordered this Transaction report from Amazon seller central because one can't request from Report's API. 我已从Amazon卖方中心订购了此交易报告,因为无法从Report的API请求。 Now I am trying to download this report using report api which is working fine, But now I am trying to set the report type to "_GET_DATE_RANGE_FINANCIAL_TRANSACTION_DATA_" so that I get requested report list for only this type of report. 现在,我尝试使用工作正常的报告api下载此报告,但是现在,我尝试将报告类型设置为“ _GET_DATE_RANGE_FINANCIAL_TRANSACTION_DATA_”,以便仅获得此报告类型的报告列表。 I am using the code below but it's giving me this error 我正在使用下面的代码,但它给了我这个错误

"Fatal error: Call to a member function getType() on a non-object in /AmazonAPI/ReportsAPIClass/src/MarketplaceWebService/Client.php on line 1605" “致命错误:在第1605行的/AmazonAPI/ReportsAPIClass/src/MarketplaceWebService/Client.php中的非对象上调用成员函数getType()”

$config = array(
            'ServiceURL' => $serviceURL,
            'ProxyHost' => null,
            'ProxyPort' => -1,
            'MaxErrorRetry' => 3,
        );
        $service = new MarketplaceWebService_Client(
        $AWS_ACCESS_KEY_ID, $AWS_SECRET_ACCESS_KEY, $config, $APPLICATION_NAME, $APPLICATION_VERSION);

        //===========================GETS REPORT ID     
        $request_report_list = new MarketplaceWebService_Model_GetReportListRequest();
        $request_report_list->setMerchant($MERCHANT_ID);
        $request_report_list->setAcknowledged(false);
        $request_report_list->setMarketplace($MARKETPLACE_ID);
        $request_report_list->setReportTypeList(array("TypeList" => "_GET_DATE_RANGE_FINANCIAL_TRANSACTION_DATA_"));

you have to create a class of type typelist and send as parameter 您必须创建一个类型为typelist的类并作为参数发送

$TypeList = new MarketplaceWebService_Model_TypeList();
$TypeList->setType('_GET_DATE_RANGE_FINANCIAL_TRANSACTION_DATA_');
$request_report_list->setReportTypeList($TypeList);

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何使用Amazon MWS Report API获取图像URL? - How to get image url using amazon mws report api? 未能使用亚马逊MWS Reports API获取财务交易报告 - Failing to get Financial Transaction report using Amazon MWS Reports API 无法从Amazon MWS Reports API请求_GET_AMAZON_FULFILLED_SHIPMENTS_DATA_报告 - Unable to request _GET_AMAZON_FULFILLED_SHIPMENTS_DATA_ report from Amazon MWS Reports API 无法从Amazon MWS Reports API请求_GET_SELLER_FEEDBACK_DATA_报告? - Unable to request _GET_SELLER_FEEDBACK_DATA_ report from Amazon MWS Reports API? Amazon MWS(PHP)-报告请求API函数返回没有数据,没有引发错误 - Amazon MWS (PHP) - Report Request API functions return without data, no error thrown 在fgetcsv循环之后什么也没有发生。 尝试从Amazon MWS API的制表符分隔的报告中保存数据 - Nothing happening after the fgetcsv loop. Trying to save data from a tab delimitted report from amazon mws api 亚马逊MWS Scratchpad API - Amazon MWS Scratchpad API MWS Amazon PHP API GetFulfillmentPreviewItemList:不清楚如何设置多个SKU的列表 - MWS Amazon PHP API GetFulfillmentPreviewItemList: unclear how to set a list with more than one sku Amazon MWS API返回SignatureDoesNotMatch - Amazon MWS API returning SignatureDoesNotMatch 亚马逊MWS API上的GetMyPriceForASIN无法正常工作 - GetMyPriceForASIN on Amazon MWS API not working
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM