# Doctoralia — 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.

> Find healthcare specialists in Brazil with their profiles, contact details, Instagram handles, pricing, and patient reviews all in one place. Search and discover doctors by specialty with autocomplete suggestions to quickly locate the right professional for your needs.

**Category:** Healthcare | **Website:** [doctoralia.com.br/](https://doctoralia.com.br/) | **Docs:** [parse.bot/marketplace/cf32883b-56e8-4657-b9ff-00a5ede5366c/doctoralia-com-br-api](https://parse.bot/marketplace/cf32883b-56e8-4657-b9ff-00a5ede5366c/doctoralia-com-br-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/doctoralia/`
**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 specialist phone

Retrieve the full phone number(s) for a specific address. The address_id can be obtained from search_specialists results (each doctor entry includes an address_id field).

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `address_id` | string | Yes | Address ID from search_specialists results. |

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

### Get specialist profile

Get the full profile of a specialist including Instagram handle and booking data (services, prices, addresses, insurances). Requires the specialist's profile URL or path. The booking_data object contains detailed service options with pricing, accepted insurances, and address info.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `url` | string | Yes | Full URL or path of the specialist profile page (e.g., 'https://www.doctoralia.com.br/lahis-salden/dermatologista/sao-paulo'). |

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

### Get specialist reviews

Get paginated patient reviews for a specific doctor. Returns HTML content of reviews along with total count and page size. The doctor_id can be obtained from search_specialists results.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `doctor_id` | string | Yes | Doctor ID from search_specialists results. |
| `page` | integer | No | Page number for pagination. |

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

### Search autocomplete

Autocomplete search for specialties, doctors, or facilities using Algolia. Returns matching hits with metadata including URLs, ratings, and specializations. Useful for discovering valid specialty slugs and doctor profile URLs.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `index` | string | No | Algolia index to search. |
| `query` | string | Yes | Search query text (e.g., 'dermatologista', 'psiquiatra'). |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/doctoralia/search-autocomplete \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"index":"<string>","query":"<string>"}'
```

### Search specialists

Search for healthcare specialists by specialty and city. Returns paginated results with doctor summaries including ratings, review counts, and addresses. Each result carries a doctor_id and address_id for drilling into phone numbers and reviews via separate endpoints.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `city` | string | Yes | City slug (e.g., 'sao-paulo', 'belo-horizonte', 'rio-de-janeiro'). |
| `page` | integer | No | Page number for pagination. |
| `specialty` | string | Yes | Specialty slug (e.g., 'dermatologista', 'psiquiatra', 'dentista'). |

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

## 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.