Test in the sandbox

The Phosra sandbox is an evaluation environment seeded with a demo family and synthetic reference providers. It exists so you can exercise a representative integration — connect a platform, set up a family, enforce a policy, sign a request — before you ever provision a key. This guide is the map: what is seeded, what is open, and how to get yourself onto the synthetic sandbox registry.

Response bodies below are examples of synthetic sandbox fixtures. Secret-bearing values are redacted.

The base URL

bash
export SANDBOX="https://phosra-api-sandbox-production.up.railway.app"

Nothing you do in the sandbox touches a real family or production data. There is no documented URL-and-key swap to production today; production credentials, hosted routing, and receipt infrastructure remain roadmap.

What's already seeded

ThingValueUse it for
Demo familyMia, Leo, Ava (children)The connect ceremony shares these three profiles
Reference provider (configured)did:ocss:looplineRun the full OAuth connect flow end-to-end
Reference provider (unconfigured)did:ocss:courierTest the 404 provider connect config not available branch
Sandbox registry entriesSynthetic records, including self-registered test identitiesVerify signatures and exercise proposed tier fields
Reference platform recordsSynthetic names and capability fixturesExercise discovery and filtering code
  1. 1
    Confirm the sandbox is up

    The /health endpoint needs no key and is the fastest liveness check:

    bash
    curl -s "$SANDBOX/health"
    # → {"status":"ok"}

  2. 2
    Read the signed Trust List

    The sandbox Trust List is a signed test artifact containing synthetic identities and tier fields. It is served at a well-known path and the entire document is Ed25519-signed by the sandbox root key. Verifying it demonstrates the mechanism; it does not prove accreditation.

    bash
    curl -s "$SANDBOX/.well-known/ocss/trust-list" \
      | jq '{alg, key_id, entries: (.document | fromjson | .entries | length)}'

    Real response (200):

    json
    {
      "alg": "ed25519",
      "key_id": "root-sandbox-2026-06",
      "entries": 135
    }

    The entries count is a live, growing number — every self-registration (below) adds an entry, so expect a value at or above the one shown here. Verify the signature and each entry's tier rather than asserting on the total.

    The top-level object wraps a signed document: { "document": "…", "key_id": "…", "alg": "ed25519", "sig": "…" }. Parse document (itself JSON) to read the entries array — each entry carries a did, an entity name, its published jwks signing keys, and a synthetic tier field. The @openchildsafety/ocss SDK verifies the signature and resolves keys for you.

  3. 3
    Self-register a provisional DID

    You do not need anyone's approval to start testing signed flows. Post your DID and a raw Ed25519 public key (base64url, unpadded) to POST /api/v1/advisors/self-register, and the census adds you to the sandbox Trust List at the provisional tier.

    First, mint a keypair and extract the raw 32-byte public key:

    bash
    # Generate an Ed25519 private key
    openssl genpkey -algorithm ed25519 -out sandbox-key.pem
     
    # Extract the raw public key as base64url (unpadded)
    PUB=$(openssl pkey -in sandbox-key.pem -pubout -outform DER \
      | tail -c 32 | base64 | tr '+/' '-_' | tr -d '=')
    echo "$PUB"

    Then register:

    bash
    curl -s -X POST "$SANDBOX/api/v1/advisors/self-register" \
      -H "Content-Type: application/json" \
      -d "{
        \"did\": \"did:ocss:dx-demo\",
        \"public_key_b64url\": \"$PUB\",
        \"roles\": [\"provider\"]
      }"

    Real response (200):

    json
    {
      "advisor_id": "fa97e1eb-1348-44c0-8954-2dec1df08d5c",
      "did": "did:ocss:dx-demo",
      "key_id": "did:ocss:dx-demo#2026-07",
      "kid": "2026-07",
      "published_key_x": "1NDtvUgkYV6h6XzR3y-FgAdKmqQ-i7XiWen7joyJYgA",
      "trust_tier": "provisional"
    }

    You are now on the sandbox Trust List. The key_id (did#kid) is what you sign your requests with; the census publishes your public key so counterparties can verify you.

    provisional is enough to test the signed flow in the sandbox. The other tier values are synthetic fixtures; no public production accreditation flow is claimed. See the design-partner and production roadmap.

The sandbox host

Everything partner-facing points at one host — the same base URL used throughout these guides. It's open, seeded, and requires no key:

HostBacks
https://phosra-api-sandbox-production.up.railway.appThe public synthetic evaluation host used throughout these guides

Now build something