Developers & data
Use HempLookup’s public data API to retrieve published strain records without extracting fields from the page layout. Human strain pages remain the canonical references. The API is read-only for public clients and requires no API key.
Start here
- Discover the endpoints, or read the OpenAPI specification.
- Resolve a strain name. A response can be resolved, ambiguous or not_found. Do not combine ambiguous matches or assume every similar name is an alias.
- Follow a match’s
entity_urlto its full record. Numeric record URLs remain stable across slug changes. - Cite the record’s
canonical_urlwhen linking readers to HempLookup. Follow its internal human links for related strains.
Read the Zombie Haze example record · JSON Schema
Fetch one record
GET https://hemplookup.com/wp-json/hemplookup/v2/strains/16017
GET https://hemplookup.com/wp-json/hemplookup/v2/strains/by-slug/zombie-haze
GET https://hemplookup.com/wp-json/hemplookup/v2/resolve?name=Zombie%20Haze
The record includes identity and aliases, classification, cannabinoid ranges, lineage, sensory descriptors, reported effects, editorial sections, photographs, evidence references and explicit uncertainties. The _links object points to related representations and documentation. Field evidence IDs correspond to entries in evidence.
Read values accurately
- Null is unknown. A missing measurement is not zero. An empty list means no terms are recorded in that field; it does not establish the absence of a trait.
- Percentages have a scope. Cannabinoid ranges are published strain-profile figures, not laboratory results for a particular flower, grower, harvest or batch.
- Classification is conventional. Indica/sativa labels and proportions do not establish measured genetics, chemistry or a predictable experience.
- Lineage can be unresolved. Preserve
lineage.status, its description and uncertainties. Do not turn disputed parentage into a definitive cross. Releases with the same name may differ. - Effects are reported experiences. Tags are subjective descriptions, not clinical findings or a treatment recommendation. Flavor and aroma tags are not a terpene assay.
- Evidence dates describe source checks. They are not harvest dates, independent genetic verification dates or a guarantee that every statement was checked on that date.
data_status and editorial_version distinguish upgraded editorial records from legacy records while the directory upgrade proceeds. Legacy records have no v3 editorial sections in this contract. Structured annotations may be pending independently of the editorial version. Public access does not imply independent verification.
Browse or synchronize the directory
GET /wp-json/hemplookup/v2/strains?limit=100
GET /wp-json/hemplookup/v2/strains?q=blue&limit=25
GET /wp-json/hemplookup/v2/strains?type=sativa-dominant-hybrid
GET /wp-json/hemplookup/v2/strains?updated_after=2026-11-01T00%3A00%3A00Z
The default page size is 25 and the maximum is 100. Collection responses contain concise records, ordered by numeric ID. Follow pagination.next unchanged until it is null. It carries the cursor and current query filters. Fetch individual entity_url values when full records are needed. The q filter searches titles; exact aliases belong in the resolver.
updated_after and as_of filter the WordPress post-content modification time. The response’s as_of is a change watermark, not a historical database snapshot. A record edited during a paginated run can move beyond that watermark. After an initial scan, query again from its starting watermark with a small overlap and deduplicate by ID. These filters do not constitute a complete change feed for independent metadata, media or deletion changes. Periodically reconcile the public collection and revalidate cached full records.
Caching and responsible requests
Responses supply ETag and cache headers. Send a stored ETag in If-None-Match; an unchanged response returns 304. Cache records, use bounded pagination and avoid repeated parallel scans. On 429 or temporary server errors, honor Retry-After when supplied and retry with backoff. There is no unlimited-throughput service commitment.
fetch('https://hemplookup.com/wp-json/hemplookup/v2/strains/16017')
.then(response => {
if (!response.ok) throw new Error(`HTTP ${response.status}`);
return response.json();
})
.then(record => console.log(record.name, record.canonical_url));
Invalid inputs return 400. Unavailable, unpublished or password-protected records return 404. Name resolution can return 200 with status: "not_found"; check that field. Public clients cannot use these endpoints to edit the directory. Cross-origin GET access is supported.
Editorial text, photographs and rights
Editorial sections reflect the published profile’s paragraphs and links. Evidence references help distinguish reported facts from editorial interpretation. Do not silently discard uncertainty notes when reusing a value.
Photograph records link to the image credits register, where authorship and available license information are maintained. Public image URLs do not grant redistribution rights. Image rights remain separate from access to the data; check each credit and any license conditions. This API does not grant a blanket open-data or image license.
Search and answer-engine discovery
Human profiles provide readable HTML, internal navigation and structured data describing an informational strain directory. Each strain page advertises its JSON representation with an alternate link. The sitemap supports URL discovery. An optional llms.txt points tools to this documentation and the API.
No special JSON format, schema or llms.txt file guarantees inclusion or citation in search engines or AI answers. Normal crawling and indexing still matter. This API gives integrations a clear data contract; it does not change robots.txt permissions or training preferences.
Versioning
This is contract v2, with schema_version: "2.0". Clients should tolerate additional fields. Breaking field or semantic changes require a new major route version. Existing v1 reference URLs remain available and link to the v2 strain record. The sources and methodology page explains the reference’s editorial scope.