# GET /iban/check: $0.001 per call

Validate an IBAN before you pay: check digits (mod-97), the right length for its country, SEPA membership, and the bank code, branch and account parts (UK: sort code and account number). Pass ?iban=GB82WEST12345698765432 (spaces fine). Format check only: it can't confirm the account exists or its owner.

- **Price:** $0.001 in USDC, the same on Base, Solana, Polygon, Arbitrum. Failed calls are never charged.
- **Free trial:** yes, 20 free calls a day from Claude, Cursor or any MCP client ([set-up](/mcp/setup)).
- **Answers cached for:** not cached
- **Data sources:** computed locally (ISO 13616 / SWIFT IBAN Registry lengths)
- **Lane:** Company financials & money ([OpenAPI](/openapi/finance.json))
- **Live health:** [status page](/status)

## Free sample

See an answer for the demo input first, free (no payment, 10 a minute): [https://aayatai.com/sample/iban-check](/sample/iban-check). It is a stored real answer when we have one, otherwise an example marked `"kind": "illustrative"`.

```bash
curl "https://aayatai.com/sample/iban-check"
```

## 1. See the price (free)

Call it without paying: you get `402 Payment Required` and a `PAYMENT-REQUIRED` header with the exact price and where to pay.

```bash
curl -i "https://aayatai.com/iban/check?iban=GB82+WEST+1234+5698+7654+32"
```

## 2. Pay and call (TypeScript)

```bash
npm install @x402/fetch @x402/evm viem
```

```ts
import { wrapFetchWithPaymentFromConfig } from "@x402/fetch";
import { ExactEvmScheme } from "@x402/evm";
import { privateKeyToAccount } from "viem/accounts";

// A wallet used only by your agent, holding a little USDC on Base.
const account = privateKeyToAccount(process.env.WALLET_PRIVATE_KEY as `0x${string}`);
const pay = wrapFetchWithPaymentFromConfig(fetch, {
  schemes: [{ network: "eip155:8453", client: new ExactEvmScheme(account) }],
});

const res = await pay("https://aayatai.com/iban/check?iban=GB82+WEST+1234+5698+7654+32");
console.log(await res.json());
```

## 3. Or as an MCP tool

```ts
// MCP server: https://aayatai.com/mcp (Streamable HTTP). With the x402 MCP client (see /start):
const result = await client.callTool("iban-check", {"iban":"GB82 WEST 1234 5698 7654 32"});
```

## Inputs

- `iban` **(required)** (string): The IBAN, with or without spaces.

Bad inputs are rejected with HTTP 400 before any payment is asked for.

## Example answer

Example only: the shape of an answer, with placeholder addresses and made-up figures. It is not data about any real token or wallet; call the service (or its free sample) for real results.

```json
{
  "iban": "GB82 WEST 1234 5698 7654 32",
  "valid": true,
  "country": "GB",
  "countryKnown": true,
  "lengthOk": true,
  "expectedLength": 22,
  "checksumOk": true,
  "electronic": "GB82WEST12345698765432",
  "print": "GB82 WEST 1234 5698 7654 32",
  "bankCode": "WEST",
  "branchCode": "123456",
  "accountNumber": "98765432",
  "sepa": true,
  "problems": [],
  "note": "UK: sort code 12-34-56, account 98765432. Checks the format and check digits only: it cannot tell whether the account exists, is open, or who holds it."
}
```

## Related

- [GET /us/company/financials](/services/us-company-financials) ($0.01): Headline financials of any SEC-registered company by ticker, CIK or name, as filed: revenue, gross/operating/net income, EPS, assets, liabilities, equity, cash,
- [GET /us/company/filings](/services/us-company-filings) ($0.005): Latest SEC filings of any US-registered company by ticker, CIK or name: 10-K, 10-Q, 8-K (items spelled out, e.g.
- [GET /us/filings/search](/services/us-filings-search) ($0.005): Search the full text of SEC filings since 2001 for a word or "exact phrase": which companies mentioned it, in which 10-K, 10-Q, 8-K (items spelled out), S-1 or 
- [GET /convert/crypto](/services/crypto-convert) ($0.001): Convert between crypto and fiat at live rates: BTC, ETH, SOL, USDC and hundreds more against USD, GBP, EUR and 150+ currencies, either way, or crypto to crypto.
- [GET /vat/calc](/services/vat-calc) ($0.001): Invoice-ready VAT maths: add VAT to net amounts or take it out of gross ones, per line and in total, rounded to the penny the way HMRC allows, with the amounts 

New here? [Getting started in 60 seconds](/start). All services: [Aayat AI](/).