bhushankummar / amazon-mws

Amazon MWS NodeJS Wrapper
MIT License
197 stars 78 forks source link

Cannot read property 'createUrlData' of undefined @\node_modules\amazon-mws\lib\AmazonMwsMethod.js:33:28 #131

Closed waleedewicantech closed 4 years ago

waleedewicantech commented 4 years ago

tried the getReport example of your github. still getting the error

bhushankummar commented 4 years ago

@waleedewicantech Kindly share with you codebase which throws the error.

bhushankummar commented 4 years ago
const ReportId = '20633058890018394';

const reportRequest = async () => {
    try {
        const response: any = await amazonMws.reports.search({
            Version: '2009-01-01',
            Action: 'GetReport',
            SellerId: account.sellerId,
            MWSAuthToken: account.mwsAuthToken,
            ReportId: ReportId
        });
        console.log(JSON.stringify(response, null, 2));
        fs.writeFileSync('test.json', JSON.stringify(response, null, 2), 'utf8');
    } catch (error) {
        console.log('error ', error);
    }
};

@waleedewicantech This working as expected fine. I am closing this issue as of now. Please feel free to open if you still getting this error.