jlevers / selling-partner-api

A PHP client library for Amazon's Selling Partner API

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

"PhpOffice\PhpSpreadsheet\IOFactory" not found

Lollichkeit opened this issue · comments

Problem description:

Am i doing something wrong?

Error:

"PhpOffice\PhpSpreadsheet\IOFactory" not found

Code

$apiInstance = new SellingPartnerApi\Api\ReportsV20210630Api($this->Sconfig);
$result = $apiInstance->getReports(['GET_V2_SETTLEMENT_REPORT_DATA_FLAT_FILE_V2'],['CANCELLED','DONE','FATAL'],[$this->marketplace_id['de']]);
$document = $apiInstance->getReportDocument('amzn...');
$reportType = ReportType::GET_V2_SETTLEMENT_REPORT_DATA_FLAT_FILE_V2;
$docToDownload = new SellingPartnerApi\Document($document, $reportType);
$contents = $docToDownload->download();
$data = $docToDownload->getData();
print_r($data);