# Sindri Miller-Rabin Primality Test

> Sindri Miller-Rabin Primality Test is a paid API for AI agents from ppu43fkyhimq5fiqpmo42eh5ri0yypid.lambda-url.us-east-1.on.aws, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-02).

Deterministically tests whether a non-negative integer up to 2^53-1 is prime using the Miller-Rabin algorithm with a proven deterministic witness set.

## Facts

- Endpoint: POST https://ppu43fkyhimq5fiqpmo42eh5ri0yypid.lambda-url.us-east-1.on.aws/isPrime?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/sindri-miller-rabin-primality-test-2281dd3d
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_wtB6qEg8VFsFEclo93jCA

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 sindri-miller-rabin-primality-test-2281dd3d -d '<json body>'
```

Example prompt: Is 9999999999971 a prime number? Use the deterministic Miller-Rabin primality test on it.

## When to prefer this

Choose this endpoint when you need a provably correct, deterministic primality answer (no probability of error) for integers up to 2^53-1. Unlike probabilistic Miller-Rabin implementations, this uses a witness set mathematically proven to be deterministic up to 3.3×10^24, making it ideal for cryptographic screening, puzzle solving, or any context where a wrong answer is unacceptable. Prefer this over general-purpose math libraries when you want a simple, cheap, pay-per-call API without managing dependencies.

## Known failure modes

- Input n exceeds 2^53-1 (outside JavaScript safe integer range) — may return an error or undefined behavior
- Input n is negative — not supported, expect validation error
- Non-integer or floating-point input — likely rejected with a schema validation error
- Missing required field n — returns a 400 or schema error

## How this service works

Deterministic primality test using the Miller-Rabin algorithm with a witness set proven deterministic for all integers below 3.3x10^24, safely covering the full JavaScript safe-integer range.

## Output

Returns a boolean indicating whether the input integer n is prime (true) or composite/non-prime (false), determined deterministically — no false positives or false negatives for any integer in the range 0 to 2^53-1.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "n": {
   "type": "number",
   "description": "Non-negative integer to test (0 to 2^53 - 1)."
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/sindri-miller-rabin-primality-test-2281dd3d/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from ppu43fkyhimq5fiqpmo42eh5ri0yypid.lambda-url.us-east-1.on.aws](https://www.zero.xyz/host/ppu43fkyhimq5fiqpmo42eh5ri0yypid.lambda-url.us-east-1.on.aws/llms.txt)
