# Yellowpages (Canada) — Wrapped API

> **You are on:** `https://api.beta.paywithlocus.com/api` | [llms.txt](https://beta.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.

> Search for businesses across Canada and retrieve detailed information including contact details, ratings, reviews, and website data. Supports keyword and location-based discovery of local businesses for research, analysis, and data enrichment use cases.

**Category:** Business Directories | **Website:** [yellowpages.ca/](https://yellowpages.ca/) | **Docs:** [parse.bot/marketplace/bd821d21-6409-4511-8a2a-f89718bf21a5/yellowpages-ca-api](https://parse.bot/marketplace/bd821d21-6409-4511-8a2a-f89718bf21a5/yellowpages-ca-api)

Pay-per-use API proxy for Locus Pro. Each call burns credits from your workspace balance.

## Access

**Base URL:** `https://api.beta.paywithlocus.com/api/wrapped/credits/yellowpages-canada/`
**Auth:** `Authorization: Bearer <LOCUS_CREDITS_SECRET_KEY>` (an `lcr_` secret key or a scoped `lcac_` agent credential)
**Required header:** `Idempotency-Key: <fresh UUID per call>`. A retry with the same key replays the stored result without a new charge.
**Response:** the provider response after any endpoint-specific normalization. `X-Locus-Credits-Charged` carries the charge and `X-Locus-Credits-Balance` the remaining balance. Insufficient credits return `402` before the provider is called.
**Pricing:** estimated costs below are USD. Locus debits the credit equivalent at your workspace rate.

Full call contract: https://docs.paywithlocus.com/api-reference/introduction

> Using a Pay With Locus wallet key (`claw_` prefix)? Wallet routes are documented separately: https://docs.paywithlocus.com/wrapped-apis/for-agents

## Endpoints

### Get all business leads with website

Filter the first page of search results for a given keyword and location to return only businesses that include a website URL. Useful for quickly identifying businesses with an online presence. Internally calls search_businesses page 1 and filters.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `keyword` | string | Yes | Business keyword to search for (e.g. 'restaurants', 'dentists', 'plumbers'). |
| `location` | string | Yes | Location to search in, formatted as city and province code (e.g. 'Toronto ON', 'Vancouver BC'). |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/yellowpages-canada/get-all-business-leads-with-website \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"keyword":"<string>","location":"<string>"}'
```

### Get business details

Retrieve full details for a specific business by its path. Returns name, address, phone, website, business hours, rating summary with sub-ratings, social links, photos, and categorized detail sections. The path is obtained from search_businesses results.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `path` | string | Yes | The path to the business page, as returned in the 'path' field from search_businesses results (e.g. '/bus/Ontario/Toronto/Bardi-s-Steak-House/156059.html?what=restaurants&where=Toronto+ON&useContext=true'). |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/yellowpages-canada/get-business-details \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"path":"<string>"}'
```

### Get business reviews

Retrieve customer reviews for a business. Returns written reviews with author, date, body text, and rating. Businesses that have only ratings but no written reviews will return an empty reviews array.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `path` | string | Yes | The path to the business page, as returned in the 'path' field from search_businesses results. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/yellowpages-canada/get-business-reviews \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"path":"<string>"}'
```

### Search businesses

Full-text search across Yellow Pages Canada by keyword and location. Returns paginated business listings (up to 35 per page) with contact info, ratings, and categories. Pagination advances via the page parameter. Each result includes a path suitable for drilling into details or reviews.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `keyword` | string | Yes | Business keyword to search for (e.g. 'restaurants', 'dentists', 'plumbers'). |
| `location` | string | Yes | Location to search in, formatted as city and province code (e.g. 'Toronto ON', 'Vancouver BC', 'Calgary AB'). |
| `page` | integer | No | Page number for pagination. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/yellowpages-canada/search-businesses \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"keyword":"<string>","location":"<string>","page":"<integer>"}'
```

## Next steps

- [All wrapped API providers](https://beta.paywithlocus.com/wapi/index.md): pick another provider.
- [Find and call tools](https://beta.paywithlocus.com/agent/tools.md): price ceilings, async results, and errors.
- [Credits and billing](https://beta.paywithlocus.com/agent/billing.md): what a call costs and how to add credits.
- [Agent docs index](https://beta.paywithlocus.com/agent/index.md): every Locus agent page.