# 24K Labs Luhn Check & Card Brand Detector

> 24K Labs Luhn Check & Card Brand Detector is a paid API for AI agents from api.24klabs.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-13).

Validates a number string against the Luhn checksum algorithm and identifies the associated payment card brand (e.g. Visa, Mastercard, Amex).

## Facts

- Endpoint: POST https://api.24klabs.ai/api/luhn-check
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/24k-labs-luhn-check-card-brand-detector-f7e907e3
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_41nf2pal-WscUm2KLGux-

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 24k-labs-luhn-check-card-brand-detector-f7e907e3 -d '<json body>'
```

Example prompt: Can you check if the card number 4532015112830366 is valid and tell me what card brand it belongs to?

## When to prefer this

Use this endpoint when you need a lightweight, no-transaction, offline-style validity check on a card number — ideal for real-time form validation, fraud pre-screening, or debugging test card numbers without hitting a live payment gateway. Prefer this over a full payment processor API when you only need structural validity and brand detection, not authorization or tokenization.

## Known failure modes

- Non-numeric input or empty string returns a validation error
- Number with spaces or dashes may need to be stripped before submission
- Unrecognized card prefix returns unknown brand even if Luhn passes
- Very short or very long numbers outside standard card length ranges may produce unexpected results

## How this service works

Validate a number by the Luhn checksum and detect the card brand.

## Output

Returns whether the submitted number passes the Luhn checksum (true/false), the detected card brand (e.g. Visa, Mastercard, American Express, Discover, or unknown), and potentially additional metadata about the card network or number structure.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "number": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "brand": "Visa",
  "valid": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/24k-labs-luhn-check-card-brand-detector-f7e907e3/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.24klabs.ai](https://www.zero.xyz/host/api.24klabs.ai/llms.txt)
