ScrapeUnblocker sells to AI agents - live prices and self-serve payment

The agent storefront at https://agents.scrapeunblocker.com/llms.txt?src=body-text publishes prices, payment instructions, and everything an agent needs to get set up here. Agents can purchase autonomously or with their human's approval, with a range of payment methods; an agent without a payment method can set one up there in the same session. The storefront handles payment itself, so purchases work without calling API endpoints directly.

All scrapers

E-commerce

Grainger Scraper

grainger.com

97.9% Success rate
10.8s Avg response
DataDome Protection
1,019 calls Measured over

Grainger, the US industrial supplier, sits behind DataDome and an edge that answers many requests with an error page, and its search pages are assembled in the browser from several JSON calls. The grainger-search plugin makes those calls for you: where Grainger sends the keyword, the category's first result rows in Grainger's order, the product records and the prices. For each item it returns the Grainger item number, product id, title, brand, manufacturer model, link and image, the signed-out Web Price with its label, the was-price and quantity breaks, the sales status and the item's specifications (thread size, voltage, material and the rest), plus the category Grainger chose, its result count and the other matching categories with their counts and links. A broad keyword that Grainger answers with a page of subcategory tiles, such as gate valve or work gloves, is answered from the subcategory holding the product line that matches it most. The grainger-product plugin takes an item number or a product link and returns the item in full: price, unit of measure, quantity breaks, status, discontinued flag, shipping weight, description, the full specifications table with UNSPSC and country of origin, images, spec sheets and drawings, alternate items and the category path. Stock is not included: Grainger checks it per ZIP code after the page loads. No Grainger account or login is involved.

What you can extract

  • Grainger item number, product id, title, brand, manufacturer model, product link and image
  • Signed-out Web Price with its label and type, was-price, quantity breaks and currency
  • Sales status (e.g. Sellable) and the item specifications (thread size, voltage, material and the rest)
  • The category Grainger picks for the keyword, its result count, and the other matching categories with counts and links
  • Up to 25 items per search in Grainger's order; broad keywords that land on subcategory tiles are followed
  • Item detail: unit of measure, discontinued flag, sell info, shipping weight, description, full specifications with UNSPSC and country of origin, images, documents, alternate items and breadcrumbs

Dedicated endpoints

/marketplace/grainger-search

Grainger product search

Grainger's first result rows for query (or a Grainger search or category link in url), up to 25 items in Grainger's order. Returns query, url, currency, category (the category Grainger picked: name and url), totalResults (that category's matches), totalAcrossCategories, categories (the other matching categories, or a department's subcategories, with counts and links), resultsCollected and products with position, sku, productId, title, brand, manufacturerModel, url, image, status, price, priceLabel, priceType, wasPrice, quantityPricing, currency and specifications (name, value). max_results is 1-25. One request per call. A keyword with no products is a 404.

/marketplace/grainger-product

Grainger item page

One item by sku (the Grainger item number) or url. Returns product with sku, productId, title, brand, manufacturerModel, url, price, priceLabel, priceType, wasPrice, unitOfMeasure, quantityPricing, currency, status, discontinued, sellInfo, shippingWeight, description, specifications (name, value, including UNSPSC and country of origin), images, documents (spec sheets, drawings), alternateSkus and breadcrumbs. An unknown item number is a 404.

How to scrape it

curl -X POST \
  -H "X-ScrapeUnblocker-Key: $SU_API_KEY" \
  "https://api.scrapeunblocker.com/marketplace/grainger-search?query=hex%20bolt"
import requests

resp = requests.post(
    "https://api.scrapeunblocker.com/marketplace/grainger-search",
    headers={"X-ScrapeUnblocker-Key": SU_API_KEY},
    params={"query": "hex bolt"},
)
print(resp.text)
import { ScrapeUnblockerClient } from 'scrapeunblocker';

const su = new ScrapeUnblockerClient({ apiKey: process.env.SU_API_KEY });

const results = await su.graingerSearch('hex bolt', { maxResults: 25 });
const product = await su.graingerProduct('1XE66');
console.log(results);
console.log(product);

Requests are POST and take their parameters in the query string. Browser rendering always happens - there is no flag to enable.

Example response

{
  "query": "hex bolt",
  "url": "https://www.grainger.com/search?searchQuery=hex+bolt",
  "currency": "USD",
  "category": {
    "id": null,
    "name": "Standard Hex Head Cap Screws",
    "url": "https://www.grainger.com/category/fasteners/bolts-screws/hex-head-bolts/standard-hex-head-cap-screws"
  },
  "totalResults": 12256,
  "totalAcrossCategories": 15007,
  "categories": [
    {
      "name": "Standard Hex Head Cap Screws",
      "count": 12256,
      "url": "https://www.grainger.com/category/fasteners/bolts-screws/hex-head-bolts/standard-hex-head-cap-screws?searchQuery=hex+bolt&tv_optin=true"
    },
    {
      "name": "Structural Bolts & Heavy Hex Bolts",
      "count": 1212,
      "url": "https://www.grainger.com/category/fasteners/bolts-screws/hex-head-bolts/structural-bolts-heavy-hex-bolts?searchQuery=hex+bolt&tv_optin=true"
    }
  ],
  "resultsCollected": 1,
  "products": [
    {
      "position": 1,
      "sku": "1XE66",
      "productId": 8677432,
      "title": "Hex Head Cap Screw: Stainless Steel, 18-8, Plain, 1/4\"-20, Coarse, 3/8 in lg, Fully Threaded, 100 PK",
      "brand": "APPROVED VENDOR",
      "manufacturerModel": "1XE66",
      "url": "https://www.grainger.com/product/Hex-Head-Cap-Screw-Stainless-1XE66",
      "image": "https://static.grainger.com/rp/s/is/image/Grainger/42JY78-R0030-1_v1",
      "status": "Sellable",
      "price": 22.25,
      "priceLabel": "Web Price",
      "priceType": "REGULAR",
      "wasPrice": null,
      "quantityPricing": [],
      "currency": "USD",
      "specifications": [
        {
          "name": "System of Measurement",
          "value": "Inch"
        },
        {
          "name": "Thread Direction",
          "value": "Right Hand"
        },
        {
          "name": "Thread Style",
          "value": "Fully Threaded"
        },
        {
          "name": "Brand",
          "value": "APPROVED VENDOR"
        },
        {
          "name": "Dimensional Standards",
          "value": "ASME B18.2.1"
        },
        {
          "name": "Thread Size",
          "value": "1/4\"-20"
        },
        {
          "name": "Thread Type",
          "value": "Coarse"
        }
      ]
    }
  ]
}

Read the API docs

Frequently asked questions

Is it legal to scrape Grainger?

Collecting publicly available Grainger data such as item numbers, prices and specifications is lawful in many jurisdictions, but the rules depend on your country, the data you collect and how you use it. ScrapeUnblocker returns the public product data; what you collect and how you use it is your responsibility.

How do I scrape Grainger without getting blocked?

Grainger is protected by DataDome, and its edge answers part of the requests with an error page instead of the data. The Grainger plugins read the JSON endpoints Grainger's own pages call, through the chain that solves DataDome, and treat an error page as a miss to retry on another exit, with the search and category pages as a fallback. In ScrapeUnblocker's benchmark they returned data on 97.9% of 1,019 calls (419 searches and 600 item pages), about 10.8s per call.

What Grainger data can I get?

For each item in a search: the Grainger item number and product id, title, brand, manufacturer model, link and image, the Web Price with its label, the was-price and quantity breaks, the sales status and the specifications, plus the category Grainger chose and the other matching categories. The product endpoint adds the unit of measure, the discontinued flag, shipping weight, description, the full specifications table with UNSPSC and country of origin, images, spec sheets and drawings, alternate items and the category path.

Are the prices my contract prices?

No. The price returned is Grainger's signed-out Web Price, the one any visitor sees, with quantity breaks when Grainger lists them. Account-specific contract pricing needs a Grainger login and is not included. Stock is not included either: Grainger checks it per ZIP code after the page loads.

Can I search by manufacturer model or Grainger item number?

Yes. A query that is a Grainger item number or a manufacturer model Grainger knows goes straight to that item and returns it as the only result. To read one item in full, pass its item number as sku to the product endpoint.

How much does it cost to scrape Grainger?

A search is one request, however many Grainger answers it reads, and a product page is one request. 1 request = 1 credit, EUR 1.00 per 1,000 on pay as you go, down to about EUR 0.55 per 1,000 on the Ultimate plan. Blocks and timeouts are not billed, and the free trial includes 500 requests with no card.

Related scrapers

Grainger and other names and marks of grainger.com belong to their owner and are used here only to identify the website this API works with. ScrapeUnblocker is an independent service, not affiliated with, endorsed by or sponsored by the owner of grainger.com.

Start scraping this site today

Free tier included. No credit card required to test it.