product reads a product page into one object with its variants, prices and stock. menu reads a restaurant menu into sections of items with prices. The shape is fixed, so the same code works on every shop and every menu.
Read a product
Get an API key in the Quickstart. This request reads a book page of a shop.Read the response
data.product holds the product. This real response is cut in the description.
A field the page does not state is left out.
Read a menu
Send"menu" the same way. data.menu holds:
Options
Limits and errors
- When the page is not a product page,
productis left out ofdataanddata.warningsays why. The same holds formenuon a page that is not a menu. The $3 is not charged. - The model reads the first 50,000 characters of the page’s Markdown.
Price
$4 per 1,000 pages for each of the two: $1 for the page and $3 for `product` or `menu` when it returns something. Asking for both on one page is $7 per 1,000 pages when both return something.Related
- JSON fills any fields you describe.
- Pre-built parsers read the data of shopping sites directly.
- Images lists every image on a page.
- Change tracking tells you when a price changes.