Choose your integration path

There are five ways to integrate with Phosra. They are not tiers of the same product — each one exists for a different job. Pick the row that matches what you are building; every path has a copy-paste quickstart that runs against the live sandbox with no account.

This page replaces reading Architecture, Partner Integration Overview, and SDK Overview end-to-end just to figure out where to begin.

Start with one question

What are you doing with child-safety rules?

The five paths at a glance

PathPackageBest forYou writeFirst call effortStart here
Provider@phosra/link 0.6.1 public; Golden 0.7.10 private candidateParental-control vendors evaluating rule and consent flowsTypeScriptDesign-partner beta for a bounded pilotProvider candidate reference →
Platform@phosra/gatekeeper 0.7.0 public; Golden 0.8.7 private candidateApps, OSes, routers, schools that enforce rulesTypeScriptGolden path not publicly availablePlatform candidate reference →
Direct RESTnone — plain JSON over HTTPSAny language, quick scripts, backendscurl / Python / Go / any5 minQuickstart →
MCP server@phosra/mcp 0.4.0AI agents & assistants (Claude, GPT, MCP clients)agent config~5 minMCP Server →
OCSS protocol SDK@openchildsafety/ocss 0.1.5Anyone who wants the open crypto primitives, provider-neutralTypeScriptvariesProtocol SDK →

The public versions above are verified against npm and installable today. The Golden Link 0.7.10, Gatekeeper 0.8.7, and OCSS 0.1.6 artifacts are private evaluation candidates, not public install targets. Hosted routing, production credentials, and a production receipt rail remain roadmap. The native iOS and Android enforcement SDKs are distributed privately (not on npm/Maven yet) — see iOS SDK / Android SDK.

How the paths relate

Most of the paths are complementary, not alternatives. The target architecture may combine two:

  • A Provider app (@phosra/link) writes rules → a future hosted router distributes them → a Platform (@phosra/gatekeeper) enforces them. The public sandbox models this flow with synthetic parties.
  • Direct REST and the MCP server are two different front doors to the same control-plane API. Pick REST for code, MCP for agents.
  • The OCSS protocol SDK sits underneath both @phosra/link and @phosra/gatekeeper — they re-export its signing and verification primitives. Use it directly only if you want the raw protocol with no Phosra-specific helpers.
mermaid
flowchart LR
  P["Provider app<br/>@phosra/link"] -->|writes signed rules| C["Target hosted router<br/>(roadmap)"]
  C -->|distributes signed profile| G["Platform<br/>@phosra/gatekeeper"]
  R["Direct REST / MCP"] -.->|manage families & policies| C
  O["@openchildsafety/ocss<br/>(crypto primitives)"] -.->|sign / verify| P
  O -.->|sign / verify| G

Not sure yet? Try the fastest path first

The Direct REST path returns a sandbox 201 in one call with no account and no key. Run it to create a disposable synthetic family, child, policy, and rules, then decide which SDK to evaluate:

bash
curl -X POST https://phosra-api-sandbox-production.up.railway.app/api/v1/setup/quick \
  -H "Content-Type: application/json" \
  -d '{"child_name":"Emma","birth_date":"2016-03-15","strictness":"recommended"}'

Real response from the sandbox (trimmed):

json
{
  "family": { "id": "7e1e2a77-1c5c-436d-9fc7-0d3b5bf4fc90", "name": "Emma's Family" },
  "child":  { "id": "65e1f14f-9d0a-491c-9108-bd6223a59778", "name": "Emma", "birth_date": "2016-03-15T00:00:00Z" },
  "policy": { "id": "8fd80f2d-6c29-4dcb-bcd1-a4794f8ded4e", "name": "Emma's Protection Policy", "status": "active" },
  "rules":  [ /* age-appropriate rules for a preteen */ ]
}

The full zero-to-enforcement version of this call — in curl, TypeScript, Python, and Go — lives in the Quickstart. Every tab is copy-paste and runs against the same open sandbox.

Decision checklist

Still torn between two paths? Match the strongest statement below:

  • "A parent needs to authorize me before I can act."Provider (@phosra/link) — it runs the consent ceremony and signs your rule-write directives.
  • "I need to block or allow content on a device, in real time, offline-safe."Platform (@phosra/gatekeeper) — it verifies the signed profile once and decides locally with isAllowed(), fail-closed, zero per-decision network calls.
  • "I just need to script family/policy setup from my backend."Direct REST — no SDK, any language.
  • "An LLM agent should drive this."MCP server.
  • "I want the open standard's crypto, and I might swap providers later."OCSS protocol SDK — identical across every OCSS-conformant implementation.

Next steps