Skip to content

benighted/mws-js

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

52 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mws-js

Complete Amazon marketplace web services client for Node.js. This project is still a work in progress, not all interfaces are fully tested and working.

Usage

config

loginInfo = {
  locale: 'US',
  merchantId: 'XXXXXXX',
  marketplaceId: 'XXXXXXX',
  accessKeyId: 'XXXXXXX',
  secretAccessKey: 'XXXXX'
}

.js Example

Fetching a product info:

var mws = require('mws-js');
var client = new mws.products.Client(loginInfo);

client.getMatchingProductForId('ASIN', 'B005ISQ7JC', function(res){
  if (res.error) {
    console.error(res.error);
  } else if (res.result) {
    console.log(res.result);
  }
});

Coffee Script example

Fetching a product info:

mws = require equire 'mws-js'
client = new mws.products.Client(loginInfo)

client.getMatchingProductForId 'ASIN', ASIN_ID , (res) =>
	if res.error
		console.error res.error
	else if res.result
		console.log util.inspect(res.result,false,10)

You can have a look at test directory for more examples.

About

Complete Amazon marketplace web services client for Node.js.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • CoffeeScript 99.5%
  • JavaScript 0.5%