# 2s.io Airport Lookup

> 2s.io Airport Lookup is a paid API for AI agents from 2s.io, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-14).

Look up detailed airport information by IATA (3-letter) or ICAO (4-letter) code, returning location, elevation, country, and service metadata.

## Facts

- Endpoint: GET https://2s.io/api/airport/lookup
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/2s-io-8b478ada
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_sKbvolG35H6rY0r4owL4F

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability 2s-io-8b478ada
```

Example prompt: What airport is 'KSFO' — can you look it up and tell me its full name, city, country, coordinates, and whether it has scheduled commercial service?

## When to prefer this

Use this endpoint when you have a known IATA or ICAO airport code and need structured metadata about that airport — name, coordinates, country, region, elevation, and scheduled service status. Prefer this over general web search when you need machine-readable, structured airport data for downstream processing such as mapping, routing, or enriching flight records.

## Known failure modes

- 404 NOT_FOUND if the airport code does not exist in the database
- Invalid code length (must be 3–5 alphanumeric characters) may result in validation error
- Typos or incorrect codes return no match rather than a fuzzy suggestion
- Payment failure (x402) if USDC balance is insufficient

## How this service works

Look up an airport by 3-letter IATA (e.g. SFO) or 4-letter ICAO (e.g. KSFO) code. Query: code (3-5 chars, alphanumeric). Returns { airport: { id, ident, type, name, latitude, longitude, elevationFt, continent, isoCountry, isoRegion, municipality, scheduledService, icaoCode, iataCode, gpsCode, localCode, wikipediaLink } } or 404 NOT_FOUND.

## Output

Returns a JSON object with a nested `airport` containing: id, ident, type, name, latitude, longitude, elevationFt, continent, isoCountry, isoRegion, municipality, scheduledService flag, icaoCode, iataCode, gpsCode, localCode, and a Wikipedia link. Returns 404 NOT_FOUND if the code is unrecognized.

## Example request

```json
{
 "input": {
  "type": "http",
  "method": "GET",
  "queryParams": {
   "code": "SFO"
  }
 }
}
```

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method",
    "queryParams"
   ],
   "properties": {
    "type": {
     "const": "http"
    },
    "method": {
     "const": "GET"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "code"
     ],
     "properties": {
      "code": {
       "type": "string",
       "maxLength": 5,
       "minLength": 3,
       "description": "3-letter IATA or 4-letter ICAO airport code (e.g. SFO, KSFO)."
      }
     },
     "additionalProperties": false
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/2s-io-8b478ada/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from 2s.io](https://www.zero.xyz/host/2s.io/llms.txt)
