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

> Search for flights across airlines including hidden-city ticketing options, and look up airport information by name or code to find the best travel deals. Access Skiplagged's flight inventory and routing data to discover cheaper itineraries and alternative airport combinations.

**Category:** Travel | **Website:** [skiplagged.com/](https://skiplagged.com/) | **Docs:** [parse.bot/marketplace/3bb9c6c3-ec6d-48b3-a229-bc8bf03838ff/skiplagged-com-api](https://parse.bot/marketplace/3bb9c6c3-ec6d-48b3-a229-bc8bf03838ff/skiplagged-com-api)

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

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/credits/skiplagged/`
**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

### Search airports

Search for airports and cities by name or IATA code. Returns matching airports with their codes, city names, labels, and parent codes. Useful for resolving user-typed location names into IATA codes for use in search_flights.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `term` | string | Yes | Search term - airport name, city name, or airport code (e.g. 'New York', 'LAX', 'Chicago') |

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

### Search flights

Search for flight itineraries between two airports on a given date. Returns all available flights including hidden-city itineraries with full segment details, pricing, and duration. Results are sorted by price by default. Polls for additional results automatically. Each itinerary includes segments with airline, timing, and duration; a hidden-city flag when the booked route is longer than the intended destination; and a booking link. Pagination is not supported — the max_results param caps the total returned in one call.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `adults` | string | No | Number of adult passengers. |
| `children` | string | No | Number of child passengers. |
| `depart` | string | No | Departure date in YYYY-MM-DD format. If omitted, defaults to 14 days from today. |
| `from` | string | Yes | Origin airport IATA code (e.g. JFK, ICT, ORD) |
| `max_results` | integer | No | Maximum number of itineraries to return. |
| `return` | string | No | Return date in YYYY-MM-DD format for round-trip searches. Omit for one-way. |
| `sort` | string | No | Sort order for results. |
| `to` | string | Yes | Destination airport IATA code (e.g. LAX, JFK, ORD) |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/skiplagged/search-flights \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"adults":"<string>","children":"<string>","depart":"<string>","from":"<string>","max_results":"<integer>","return":"<string>","sort":"<string>","to":"<string>"}'
```

## Next steps

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