Developers

Partner API.

Verified genotype compatibility for churches, marriage registries, matrimony apps and employer wellness programmes — with a signed answer your own systems can check.

Overview

The Partner API answers one question: can these two people have a child with sickle cell disease? It works from verified genotype certificates, never from something a person typed in.

Three things shape the design: a partner can only ask about two people who each produced a code, the answer never contains a genotype, and every answer is signed so you can prove later that we said it.

API key auth

One header, hashed at rest

Two-sided

Both people opt in with a code

Signed

Digitally signed, verifiable offline

Base URL: https://genotrust.app/api

Quickstart

Three calls and you have an answer.

1 · request a key

Keys are issued by us after a short review — sandbox first, then production. No self-service signup, because every key can run checks against real people.

Open the request form
2 · run a check
curl -X POST https://genotrust.app/api/v1/compatibility-checks \
  -H "X-API-Key: gvp_live_..." \
  -H "Content-Type: application/json" \
  -d '{"code_a":"GVP-1A2B3C4D","code_b":"GVP-9F8E7D6C"}'
3 · read the answer
{
  "id": "0f0c8b7e-...",
  "result": "compatible",
  "outcome": "no_scd_risk",
  "severity": "low",
  "scd_risk": 0,
  "carrier_risk": 0.5,
  "explanation": "No sickle cell disease risk for a child. There is a 50% chance a child would be a carrier (AS or AC), which usually causes no health problems.",
  "created_at": "2026-10-25T09:00:00.000Z",
  "expires_at": "2027-01-23T09:00:00.000Z",
  "signature": { "claim": { "...": "..." }, "value": "base64…", "key_id": "gv-prod-1" }
}

Authentication

Send your key in an X-API-Key header on every call. Keys look like gvp_live_… and are stored as SHA-256 hashes — we cannot recover a lost key, we can only issue a new one.

http
X-API-Key: gvp_live_a1b2c3d4e5f6...

Treat it as a server-side secret. Do not put it in a web page, a mobile app bundle, or a public repository: a leaked key can run checks, and every check is billed to you.

Compatibility codes

These are the person-facing endpoints. They are for your own app or portal if you are helping someone produce a code; they use the person's Genotrust login, not your API key.

POST/api/compatibility-codes
request
{ "label": "Grace Chapel premarital class", "max_uses": 20, "days": 90 }
response
{
  "id": "…",
  "code": "GVP-1A2B3C4D",
  "label": "Grace Chapel premarital class",
  "max_uses": 20,
  "uses": 0,
  "expires_at": "2027-01-23T09:00:00+00:00"
}
GET/api/compatibility-codes

Lists the person's codes with use counts and revoked state.

DELETE/api/compatibility-codes/{id}

Revokes a code immediately. If either code is revoked, a check fails.

Create a check

POST/api/v1/compatibility-checks

Both codes are required. Order does not matter — the answer is symmetric.

request
{ "code_a": "GVP-1A2B3C4D", "code_b": "GVP-9F8E7D6C" }
FieldTypeMeaning
iduuidUse it to re-read this answer
resultenumcompatible · needs_counselling · not_compatible
outcomeenumGranular clinical outcome code
severityenumlow · moderate · high
scd_risknumber0–1 chance of a child with sickle cell disease
carrier_risknumber0–1 chance of a child who is a carrier
explanationstringPlain-language sentence you can show a person
created_atISO dateWhen the check ran
expires_atISO dateWhen the signed assertion stops being current
signatureobjectclaim, value (base64), key_id — see Verifying offline

Re-read a check

GET/api/v1/compatibility-checks/{id}

Returns the same body. Scoped to the key that created it — another partner's key cannot read your checks. Answers do not change once issued; re-reading is for your own records, not for polling.

Result values

compatible

No sickle cell disease risk for a child. A carrier outcome is possible and normal.

needs_counselling

No sickle cell disease risk, but another haemoglobinopathy (such as HbCC) is possible. Refer for genetic counselling.

not_compatible

Sickle cell disease is possible. Refer for genetic counselling — this is a probability, not a diagnosis.

Show the explanation alongside any result. A bare “not compatible” without it is how people end up misreading a probability as a verdict.

Errors & limits

StatuscodeMeaning
403api_key_invalidMissing, unknown or malformed key
403api_key_revokedKey has been revoked
403rate_limited600 checks/hour per key exceeded
400check_rejectedSame person twice, revoked, expired, or use limit reached
404check_unavailableA code is unknown, or somebody lacks a valid certificate
404not_foundNo check with that id for your key

check_unavailable is intentionally vague. A partner must not be able to probe whether a particular code or person exists.

Rate limit: 600 checks per hour per key. Ask support if you need a higher ceiling.

Verifying offline

Every answer is digitally signed with the same key that signs genotype certificates. Fetch the public key once, and you can prove a stored answer came from us years later — even if our API is down or the check has expired.

public keys
curl https://genotrust.app/.well-known/genotrust-keys.json

{
  "keys": [
    { "kty": "OKP", "crv": "Ed25519", "x": "DYUxVyxeUtmmO_Z-...", "kid": "gv-prod-1", "use": "sig", "alg": "EdDSA" }
  ]
}

Canonical bytes are JSON.stringify of the claim, with this fixed key order and claims keys sorted ascending:

text
v, typ, iss, sub, iat, exp, key_id, claims
node
import { createPublicKey, verify } from 'node:crypto';

const jwks = await (await fetch('https://genotrust.app/.well-known/genotrust-keys.json')).json();
const jwk = jwks.keys.find((k) => k.kid === claim.key_id);
const pub = createPublicKey({ key: jwk, format: 'jwk' });

const ordered = {
  v: claim.v, typ: claim.typ, iss: claim.iss, sub: claim.sub,
  iat: claim.iat, exp: claim.exp, key_id: claim.key_id,
  claims: Object.fromEntries(
    Object.entries(claim.claims).sort(([a], [b]) => (a < b ? -1 : a > b ? 1 : 0)),
  ),
};

const ok = verify(
  null,
  Buffer.from(JSON.stringify(ordered), 'utf8'),
  pub,
  Buffer.from(signature.value, 'base64'),
);
browser (no app, no login)
const jwk = await (await fetch('https://genotrust.app/.well-known/genotrust-keys.json')).json();
const key = await crypto.subtle.importKey('jwk', jwk.keys[0], { name: 'Ed25519' }, false, ['verify']);

const ok = await crypto.subtle.verify(
  'Ed25519',
  key,
  Uint8Array.from(atob(signature.value), (c) => c.charCodeAt(0)),
  new TextEncoder().encode(JSON.stringify(ordered)),
);

GET /v1/self-test returns { "ok": true } when the published key matches the signing key — a cheap uptime and key-rotation check for your own monitoring.

Privacy & audit

What a check response will never contain:

  • Either genotype (AA, AS, SS, AC, SC)
  • Either person's name, phone number, email or NIN
  • Either person's user id
  • The allele distribution the risk was computed from

Every check writes an audit entry (partner_check.run) and a row in partner_checks, which is what billing is based on. The person can see that a code was used, because their use counter moves.

Under the NDPA, the people involved can request access, correction or deletion of their data at any time. Codes you hold stop working when they are revoked.

Versioning

The version is in the path (/v1). Additive changes — new fields, new enum values — can ship inside v1; we will never remove or rename a field there without a new version. Signed claims carry their own v and a fixed key order, so new claim types do not break old verifiers.

Current

v1 — released 25 October 2026. Two-sided compatibility checks, signed answers, published keys.

Need a key?

Tell us about your organisation and how you run genotype checks today. We issue sandbox keys quickly and production keys after a short review.