Digi-Key API

Shopping / OAuth Advanced HTTPS
Varies by plan (check documentation)

Overview

The Digi-Key API provides real-time access to pricing, inventory, and detailed specifications for millions of electronic components sold by Digi-Key. You can programmatically check stock levels, get datasheets, and even place orders directly through the API. It is especially useful for engineers and procurement teams building automated sourcing or BOM (Bill of Materials) tools.

💡

Beginner Tip

Digi-Key uses OAuth 2.0, so you will need to complete the authorization flow and obtain an access token before making any API calls. Start with the Product Search endpoint using a part number to verify your setup before building more complex integrations.

Available Data

Digi-Key data via REST API
JSON-formatted response data
Requires OAuth authentication

Example Response

JSON Response
{
  "status": "success",
  "data": {
    "result": "Data from Digi-Key",
    "description": "Retrieve price and inventory of electronic components as well as place orders",
    "timestamp": "2025-01-15T10:00:00Z"
  }
}

Field Reference

DigiKeyPartNumber Digi-Key catalog number for the component, used for ordering
ManufacturerPartNumber The part number assigned by the original manufacturer
UnitPrice Price per single unit in USD based on the lowest quantity break
QuantityAvailable Number of units currently in stock and available to ship
ProductDescription Technical description of the component including key specifications
Datasheet URL link to the manufacturer PDF datasheet for the component

Implementation Example

const url = "https://www.digikey.com/en/resources/api-solutions";
// Replace headers or query params with the values required by this API.
const response = await fetch(url, {
  headers: {
  "Authorization": "Bearer YOUR_API_KEY"
  }
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

401 Unauthorized The access token is expired or the client credentials are incorrect
Refresh your OAuth access token using the refresh token flow and verify your Client ID and Client Secret are correct
404 Not Found The part number does not exist in Digi-Key's catalog
Verify the exact manufacturer part number or Digi-Key part number; try using the Product Search endpoint instead of exact lookup
400 Bad Request on locale headers Missing required locale headers in the request
Include X-DIGIKEY-Locale-Site, X-DIGIKEY-Locale-Language, and X-DIGIKEY-Locale-Currency headers in every request

Matrix Score Breakdown

🌐 Reachability 30/30
⚡ Speed 5/20
🔒 Security 15/15
🛠 Developer XP 3/20
✓ Reliability 10/15

Partially tested on Apr 5, 2026

Technical Specifications

Auth OAuth
HTTPS REQUIRED
CORS UNKNOWN
Category Shopping
Difficulty Advanced
Verified: 2026-04-04

Similar APIs

View All →