Back to Home
LgdHub Developer API Documentation
Integrate live lab-grown diamond inventories and bidding pipelines into your B2B applications.
The LgdHub REST API allows verified merchants and software developers to programmatically upload inventories, query live listings, check certificate data, and submit bids. Our API uses JSON payloads, standard HTTP response codes, and Bearer token authentication.
1. Authentication
To request an API key, register a developer account in our register screen, navigate to the Developer Tab, and generate a key. Include this key in the header of all HTTP requests:
Authorization: Bearer YOUR_API_KEY
2. Diamond Search Endpoint
GET
https://api.lgdhub.com/v1/diamondsQueries our central database for active CVD/HPHT diamond sheets. Use query parameters like shape, carat_min, color, and clarity.
Example Node.js request:
const axios = require('axios');
axios.get('https://api.lgdhub.com/v1/diamonds', {
params: {
shape: 'Oval',
carat_min: 1.5,
color: 'E',
clarity: 'VVS2'
},
headers: {
'Authorization': 'Bearer lgd_live_prod_59c878e12c5b'
}
})
.then(response => {
console.log(`Found ${response.data.total_results} diamonds.`);
})
.catch(error => {
console.error(error);
});