# MoneyTools Card Number Luhn Validator

> MoneyTools Card Number Luhn Validator is a paid API for AI agents from tools.moneytools.dev, paid per call via x402, $0.001/call, status unknown (last checked 2026-11-05).

Validates a payment card number using Luhn checksum, identifies the card brand (Visa, Mastercard, Amex, etc.), and checks length correctness, returning only a masked number.

## Facts

- Endpoint: POST https://tools.moneytools.dev/v1/card-check?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-05
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/moneytools-card-number-luhn-validator-b14402fe
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_QP8rr287hgvax_YNSm8bv

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 moneytools-card-number-luhn-validator-b14402fe -d '<json body>'
```

Example prompt: Can you check if the card number 4242 4242 4242 4242 is valid — tell me if it passes the Luhn check, what brand it is, and show me the masked version?

## When to prefer this

Use this endpoint when you need a lightweight, privacy-safe card number check that doesn't store data and returns a masked result — ideal for pre-validation before submitting to a payment processor, testing card inputs, or flagging bad data in a user form. Prefer this over building your own Luhn implementation when you also need brand detection and length validation in one call. The x402 micropayment model makes it cost-effective for low-volume or on-demand use without subscription overhead.

## Known failure modes

- Invalid or malformed card number string returns a failure without charge
- Non-numeric input or missing number field causes a 400-level error
- Free tier exhausted (10/day) with no API key triggers HTTP 402 Payment Required via x402 protocol
- Ambiguous card number that doesn't match any known brand may return unknown brand

## How this service works

Card number checksum (Luhn): Luhn checksum, brand (Visa, Mastercard, Amex, JCB, UnionPay...) and length check; returns only a masked number. Never stored. Free tier 10/day; then $0.001 via x402 (HTTP 402 + PAYMENT-REQUIRED) or X-API-Key credits. Not charged on failure. $0.001 USDC per call via x402 on Base. Run by MoneyTools.

## Output

Returns whether the card number passes the Luhn checksum, the detected card brand (e.g. Visa, Mastercard, Amex, JCB, UnionPay), whether the length is correct for that brand, and a masked version of the card number. The raw number is never stored.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "number": {
   "type": "string",
   "examples": [
    "4242 4242 4242 4242"
   ],
   "description": "card number (test numbers recommended)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/moneytools-card-number-luhn-validator-b14402fe/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from tools.moneytools.dev](https://www.zero.xyz/host/tools.moneytools.dev/llms.txt)
