Skip to main content
Piloterr
Back to library

Grainger Search API

Search Grainger US or Canada by keyword, category URL or SKU. Returns product listings, category branches and suggestions via browser rendering.

Active2 credits = 1 requestGET/v2/grainger/search

Endpoint Overview

Detailed documentation, pricing, and usage examples.

OverviewLink to Overview

The Grainger Search endpoint searches Grainger US (grainger.com) or Canada (grainger.ca) by keyword, category URL or path.

It returns product listings when available, plus category branches and suggested products. Browser rendering is used because Grainger pages need JavaScript and scroll to load listings.

Costs 2 credits per call.

QuickstartLink to Quickstart

GET https://api.piloterr.com/v2/grainger/search?query=carolina
GET https://api.piloterr.com/v2/grainger/search?query=carolina&region=ca
GET https://api.piloterr.com/v2/grainger/search?query=https://www.grainger.com/category/abrasives
GET https://api.piloterr.com/v2/grainger/search?query=3FRU1

ParametersLink to Parameters

Parameter Type Required Description
query string yes Keyword, search/category URL, category path, or SKU
region string no com (default, USD) or ca (CAD). Detected from a full URL
return_page_source boolean no Return rendered HTML instead of JSON (default: false)

RegionsLink to Regions

region Host Currency
com www.grainger.com USD
ca www.grainger.ca CAD

Response fieldsLink to Response fields

Field Type Description
region string com or ca
query string Search keyword when present in the URL
url string Resolved page URL
total_results number Product count when available
results array Product listings (sku, title, url, price, currency)
categories array Category branches (title, url) when the page shows them
suggested_products array Suggested products when there is no direct match
no_results boolean true when the page reports an empty search

Empty values are omitted from the JSON response.

Error codesLink to Error codes

Code Meaning
400 Empty or invalid query
404 Rendered page has no usable data
500 Rendering failed

Related APIs

Expand your data capabilities with these complementary tools.

Ready to get started?

Your web scraping API is one click away. Start with +500 credits, no infrastructure to set up, no proxies to manage, and no credit card required.

  • +500 credits
  • No credit card required
  • All endpoints included