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

> Plan trips across Dutch trains, buses, trams, metros, and ferries by searching for locations and getting detailed journey information including travel times and costs. Find the best routes through the Netherlands' public transport network with real-time trip planning.

**Category:** Travel | **Website:** [9292.nl/](https://9292.nl/) | **Docs:** [parse.bot/marketplace/8a47a013-b1d9-4d4d-adad-0d91de56f5ea/9292-nl-api](https://parse.bot/marketplace/8a47a013-b1d9-4d4d-adad-0d91de56f5ea/9292-nl-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/9292/`
**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 journey details

Get detailed journey information for a specific trip, including individual legs with departure/arrival stations, platforms, intermediate stops, transport modes, and fare breakdowns. The journey_id is obtained from plan_trip results.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `journey_id` | string | Yes | Opaque journey identifier obtained from plan_trip results. |

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

### Plan trip

Plan a trip between two locations on the Dutch public transport network. Returns multiple route options with departure/arrival times, duration, price, transport modes, and operators. Each result includes a journey_id that can be used with get_journey_details for full leg-by-leg breakdown.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `date_time` | string | No | ISO 8601 UTC datetime for departure or arrival (e.g. '2026-07-18T08:00:00.000Z'). Defaults to current time + 5 minutes. |
| `extra_interchange_time` | integer | No | Extra minutes to allow for transfers between vehicles. |
| `from` | string | Yes | Origin location ID (e.g. 'station-amsterdam-centraal'). Obtain from search_locations. |
| `request_type` | string | No | Whether date_time refers to departure or arrival time. |
| `results` | integer | No | Number of trip options to return (1-15). |
| `to` | string | Yes | Destination location ID (e.g. 'station-rotterdam-centraal'). Obtain from search_locations. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/9292/plan-trip \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"date_time":"<string>","extra_interchange_time":"<integer>","from":"<string>","request_type":"<string>","results":"<integer>","to":"<string>"}'
```

### Search locations

Search for public transport locations (stations, stops, addresses) by free-text query. Returns matching locations with their unique IDs, which are used as inputs to plan_trip. Results are ranked by relevance to the query.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `limit` | integer | No | Maximum number of results to return (1-50). |
| `query` | string | Yes | Free-text search query for a location name, station, stop, or address. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/9292/search-locations \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"limit":"<integer>","query":"<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.