# Rescuegroups — 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 adoptable animals across rescue organizations by species, breed, location, and other criteria, then view detailed profiles with photos and contact information. Find the perfect pet match and connect directly with rescue organizations to start the adoption process.

**Category:** Other | **Website:** [rescuegroups.org/](https://rescuegroups.org/) | **Docs:** [parse.bot/marketplace/d2bf3178-ce8b-44c8-a8a0-09dfefbeb4f0/rescuegroups-org-api](https://parse.bot/marketplace/d2bf3178-ce8b-44c8-a8a0-09dfefbeb4f0/rescuegroups-org-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/rescuegroups/`
**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 animal details

Retrieve full details for a specific animal by ID, including description, organization info, photos, breed, age, sex, status, and location. The animal_id comes from search_available_animals results.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `animal_id` | string | Yes | Unique numeric identifier for the animal (from search_available_animals results). |

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

### Get breeds

Retrieve the complete list of valid breed IDs and names that can be used to filter animal searches via the breed parameter on search_available_animals.

**Estimated cost:** Metered

_No parameters required._

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

### Search available animals

Search for available/adoptable animals with filters for breed, sex, location, and distance. Can filter for animals needing foster care. Returns paginated results with animal summaries including name, breed, basic info, distance, and photo. Each result carries an animal ID suitable for get_animal_details.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `breed` | string | No | Breed ID to filter by (use get_breeds endpoint to retrieve valid IDs). |
| `distance` | integer | No | Search radius in miles from the specified location. |
| `location` | string | No | ZIP/Postal code to search near. |
| `needs_foster` | boolean | No | When true, filters for animals needing foster homes only. |
| `page` | integer | No | Page number of results. |
| `sex` | string | No | Sex of the animal: Male, Female, or omit for either. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/rescuegroups/search-available-animals \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"breed":"<string>","distance":"<integer>","location":"<string>","needs_foster":"<boolean>","page":"<integer>","sex":"<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.