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

documenu

v1.1.0

Published

Package to easily use Documenu API. US restaurant menu API With Over 600,000 Restaurants: www.Documenu.com

Downloads

9

Readme

documenu-npm

Documenu is an that API provides access to a Database of over 600,000 US Restaurant Menus with over 50,000,000 individual menu items. https://documenu.com

This package is intended to make it easier to interact with the API when using NodeJS

Install

npm install -S documenu

Configure

In order to use this API you need an API key. You can get it here: Get API Key

const Documenu = require('documenu')
Documenu.configure('YOUR-API-KEY')

API

Restaurants

let result = await Documenu.Restaurants.getByState('NY');
Documenu.Restaurants.getByState('NY')
.then(res=> {
	console.log(res);
});

Menu Items

const params = {
	"lat": "40.68919",
	"distance": "1",
	"lon": "-73.992378",
	"page": "1"
}
let result = await Documenu.MenuItems.searchGeo(params)
Documenu.Restaurants.MenuItems.searchGeo(params)
.then(res=> {
	console.log(res);
});

View More Code Examples Here: Git With Code Examples

Available resources and methods

Restaurants

  • get(restaurantid)
    • restaurantid : string
  • getMenuItems(restaurantid,params)
    • restaurantid : string
    • Params (Optional)
      • size | number | Data Size of Results
      • page | number | Page Through Results
  • searchFields(params)
    • Params (Optional)
      • exact | Boolean | Search for exact match to terms
      • restaurant_name | string | Data Size of Results
      • restaurant_phone | string | Search By Phone Number
      • restaurant_website | string | Search By Website
      • address | string | Search By Address
      • state | string | Search By State Code
      • zip_code | number | Search By Zip Code
      • size | number | Data Size of Results
      • page | number | Page Through Results
      • fullmenu | Boolean | include full menus
  • searchGeo(params)
    • Params (Required)
      • lat | number | Latitude of search area
      • lon | number | Longitude of search area
      • distance | number | Search Area radius (in miles)
    • Params (Optional)
      • size | number | Data Size of Results
      • page | number | Page Through Results
      • fullmenu | Boolean | include full menus
  • getByState(state,params)
    • state : string
    • Params (Optional)
      • size | number | Data Size of Results
      • page | number | Page Through Results
      • fullmenu | Boolean | include full menus
  • getByZipCode(zip,params)
    • zip : string
    • Params (Optional)
      • size | number | Data Size of Results
      • page | number | Page Through Results
      • fullmenu | Boolean | include full menus
  • geoBoundingBox(params)
    • Params (Required)
      • top_left | string | Top Left coordinates of Bounding Box in lat,lon
      • bottom_right | string | Bottom Right coordinates of Bounding Box in lat,lon
    • Params (Optional)
      • size | number | Data Size of Results
      • page | number | Page Through Results
      • fullmenu | Boolean | include full menus
  • withinTravelRadius(params)
    • Params (Required)
      • lat | number | Latitude of search area
      • lon | number | Longitude of search area
      • minutes | number | Number of minutes
      • mode | string | Mode of Transport (walking or driving)
    • Params (Optional)
      • size | number | Data Size of Results
      • page | number | Page Through Results
      • fullmenu | Boolean | include full menus
  • withinGeoPolygon(points,params)
    • points: Array of points in [[lat,lon]] format
    • Params (Optional)
      • size | number | Data Size of Results
      • page | number | Page Through Results
      • fullmenu | Boolean | include full menus

MenuItems

  • get(itemid)
    • itemid : string
  • searchGeo(params)
    • Params (Required)
      • lat | number | Latitude of search area
      • lon | number | Longitude of search area
      • distance | number | Search Area radius (in miles)
    • Params (Optional)
      • size | number | Data Size of Results
      • page | number | Page Through Results

API Docs

View API Docs here: https://documenu.com/docs

For Support Email [email protected]