npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

walmart

v0.0.4

Published

Walmart API wrapper

Downloads

12

Readme

Walmart Open API

This is a wrapper library around the WalmartLabs Developer Library. To access this library you will need a developer key.

Installation

To install the library:

% npm install walmart --save

Usage

First include the library:

var walmart = require('walmart')(apiKey);

The apiKey is the API key that you got from WalmartLabs when you registered.

Once you have the walmart object you can make these requests.

This is a promise based library, so requests will look like this:

walmart.getItem(10449075).then(function(item) {
  console.log(item.product.productAttributes.productName);
});

The then function is called when the item data is returned.

You can see more examples in examples/simple.js.

walmart.getItem(itemID)

This returns the item information for a specific product based on it's WalmartLabs product ID.

walmart.getItemByUPC(upcCode)

Returns the product by the upcCode, the barcode on a product is the UPC so you should send that directly to the API.

walmart.search(term, extras)

Returns a list of products that match the search term.

walmart.taxonomy()

Returns our category taxonomy.

recommendations(itemID)

Returns recommended products based on the item ID.

walmart.reviews(itemID)

Returns customer reviews for the specific WalmartLabs Item ID.

walmart.stores.byPosition(lat, lon)

Returns a list of stores by the specified GPS latitude and longitude.

walmart.stores.byCity(city)

Returns a list of stores by the specified city name.

walmart.stores.byZip(zip)

Returns a list of stores by the specified zip code.

walmart.stores.search(store, query, extras)

Returns a list of products that match the query in the specified store.

walmart.feeds.items(categoryId)

Returns an array of items on the specified category.

walmart.feeds.bestSellers(categoryId)

Returns an array of items of the best-sellers on the specified category.

walmart.feeds.preOrder()

Returns an array of items of the available pre-orders.

walmart.feeds.rollback(categoryId)

Returns an array of items of the rollbacks on the specified category.

walmart.feeds.clearance(categoryId)

Returns an array of items of the clearance items on the specified category.

walmart.feeds.specialBuy(categoryId)

Returns an array of items of the special buy items on the specified category.

walmart.feeds.valueOfTheDay(categoryId)

Returns an array of items of the value of the day items on the specified category.

walmart.feeds.trending(categoryId)

Returns an array of items of the trending items on the specified category.