# Leafly — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Browse and search Leafly's cannabis catalog. Look up strains by effect, flavor, terpene, or medical use. Find dispensaries near any location, explore their menus and product details, and search across strains, brands, dispensaries, and articles.

**Category:** Healthcare | **Website:** [leafly.com/](https://leafly.com/) | **Docs:** [parse.bot/marketplace/6905fb61-1298-431a-8062-06f02770a831/leafly-com-api](https://parse.bot/marketplace/6905fb61-1298-431a-8062-06f02770a831/leafly-com-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_dispensary_detail

Get full details for a specific dispensary by slug. Returns comprehensive information including address, phone, hours, weekly schedule, delivery/pickup configuration, photos, ratings, and description.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | Dispensary slug identifier (e.g., 'purple-star-md'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/get_dispensary_detail \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"slug":"<string>"}'
```

### get_dispensary_menu

Get the product menu for a specific dispensary. Returns menu items with product details including name, price, product category, THC/CBD content, strain information, brand, and variant pricing. Paginated; each item includes full dispensary and strain data inline.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `lat` | string | No | Latitude for location context. |
| `lon` | string | No | Longitude for location context. |
| `skip` | integer | No | Number of results to skip for pagination. |
| `slug` | string | Yes | Dispensary slug identifier (e.g., 'purple-star-md'). |
| `take` | integer | No | Number of results to return. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/get_dispensary_menu \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"lat":"<string>","lon":"<string>","skip":"<integer>","slug":"<string>","take":"<integer>"}'
```

### get_product_detail

Get detailed information for a specific product from a dispensary menu. Returns the full product object, the dispensary details, and a list of similar items from the same dispensary. Requires store_slug, product_id (the menuItemId from get_dispensary_menu), and product_slug (URL-style slug derived from the product name).

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `product_id` | string | Yes | Menu item ID from get_dispensary_menu results (the menuItemId field). |
| `product_slug` | string | Yes | URL-style slug derived from the product name (lowercase, hyphen-separated). |
| `store_slug` | string | Yes | Dispensary slug identifier (e.g., 'purple-star-md'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/get_product_detail \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"product_id":"<string>","product_slug":"<string>","store_slug":"<string>"}'
```

### get_strain_detail

Get detailed information for a specific strain by slug. Returns the full strain profile including description, effects with scores/votes, terpenes, cannabinoid percentiles, flavors, grow info, parent/child strains, and a list of recent user reviews. A separate round-trip from list_strains; use when the summary is insufficient.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | Strain slug identifier (e.g., 'blue-dream', 'wedding-cake', 'hash-burger'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/get_strain_detail \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"slug":"<string>"}'
```

### list_brands

List cannabis brands with pagination. Returns brand objects with id, slug, name, description, logo URL, tagline, and available countries.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `skip` | integer | No | Number of results to skip for pagination. |
| `take` | integer | No | Number of results to return. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/list_brands \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"skip":"<integer>","take":"<integer>"}'
```

### list_dispensaries

List dispensaries near a geographic location. Returns dispensary summaries including name, slug, address, rating, review count, open status, distance, and fulfillment options. Results are ordered by proximity.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `lat` | string | No | Latitude of search center (decimal degrees as string). |
| `lon` | string | No | Longitude of search center (decimal degrees as string). |
| `skip` | integer | No | Number of results to skip for pagination. |
| `take` | integer | No | Number of results to return. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/list_dispensaries \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"lat":"<string>","lon":"<string>","skip":"<integer>","take":"<integer>"}'
```

### list_strains

List cannabis strains with pagination and optional filters. Returns an array of strain objects (with name, slug, category, effects, terpenes, cannabinoids, ratings) and a total count. Filters narrow results server-side; omitting all filters returns the default popular strains. Each strain object includes rich detail for display without a detail fetch.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `effect` | string | No | Filter by effect (e.g., 'creative', 'relaxed', 'euphoric', 'sleepy', 'happy', 'energetic', 'focused'). |
| `flavor` | string | No | Filter by flavor (e.g., 'berry', 'citrus', 'earthy', 'sweet', 'pine'). |
| `helps_with` | string | No | Filter by medical symptom (e.g., 'pain', 'stress', 'anxiety', 'insomnia', 'depression'). |
| `skip` | integer | No | Number of results to skip for pagination. |
| `strain_type` | string | No | Filter by strain type: 'indica', 'sativa', or 'hybrid'. |
| `take` | integer | No | Number of results to return per page. |
| `terpene` | string | No | Filter by terpene (e.g., 'myrcene', 'limonene', 'caryophyllene', 'pinene', 'linalool'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/list_strains \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"effect":"<string>","flavor":"<string>","helps_with":"<string>","skip":"<integer>","strain_type":"<string>","take":"<integer>","terpene":"<string>"}'
```

### search_site

Global search across the Leafly site. Returns results grouped by type: strains, brands, dispensaries, menu items, and articles. Each category returns objects shaped the same as their respective list endpoints.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `query` | string | Yes | Search keyword. |
| `skip` | integer | No | Number of results to skip for pagination. |
| `take` | integer | No | Number of results to return per category. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/search_site \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query":"<string>","skip":"<integer>","take":"<integer>"}'
```

### search_strains

Search for cannabis strains by keyword. Returns matching strain objects with the same shape as list_strains results. Searches against strain name and aliases.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `query` | string | Yes | Search keyword to match against strain names. |
| `skip` | integer | No | Number of results to skip for pagination. |
| `take` | integer | No | Number of results to return. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-leafly-com-api-6905fb61/search_strains \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query":"<string>","skip":"<integer>","take":"<integer>"}'
```
