Developers

Mask sensitive data before your AI request leaves.

Use NeutralAI Gateway as a server-side control point for prompt masking, API-key authenticated calls, and integration patterns that fit regulated AI workflows.

Mask request
curl -X POST "https://api.neutralai.co.uk/v1/shield/mask" \
  -H "Content-Type: application/json" \
  -H "x-api-key: nai_live_your_key" \
  -d '{
    "prompt": "My email is john@acme.com",
    "reversible": true
  }'
Response
{
  "status": "ok",
  "masked_text": "My email is <EMAIL_ADDRESS_demo_01>"
}

Quickstart

Three steps to a masked prompt.

1

Get an API key

Create a sandbox account and generate a scoped API key for server-side calls.

2

Call the masking endpoint

Send prompt text to the gateway with an x-api-key header. Keep keys out of browsers and public repos.

3

Forward sanitized text

Use the masked output in your LLM request, workflow, or internal review process.

SDKs

Python and Node SDKs are prepared for publication.

The gateway repo contains Python and Node SDK clients. Public package publication is still in progress, so this page keeps install guidance API-first until the registry release is confirmed.

Public package names are reserved, but registry install commands are intentionally withheld until publication checks pass.

Python preview

Python client shape
from neutralai_sdk import NeutralAIClient

client = NeutralAIClient(
    base_url="https://api.neutralai.co.uk",
    api_key="nai_live_your_key",
)

result = client.mask(
    "My email is john@acme.com",
    reversible=True,
)

print(result.masked_text)

Node preview

Node client shape
import { NeutralAIClient } from "neutralai-node-sdk";

const client = new NeutralAIClient({
  baseUrl: "https://api.neutralai.co.uk",
  apiKey: "nai_live_your_key",
});

const result = await client.mask({
  prompt: "My email is john@acme.com",
  reversible: true,
});

console.log(result.maskedText);

Authentication

Keep API keys server-side.

API calls use the x-api-key header. Treat keys as backend secrets, rotate them through the app, and avoid logging prompts or credentials.

Get your free API key

Integration examples

LangChain integration

Mask user or document context before it enters a chain, then pass sanitized text into the model step.

OpenAI SDK wrapper

Wrap chat completion calls so sensitive fields are removed before requests leave your trust boundary.

Browser extension

Use the managed extension path for browser-based AI usage where teams need policy before prompt egress.

Direct API

Call the masking endpoint from backend services, internal tools, and agent workflows using API-key auth.

Ready for a sandbox key

Start with the masking API, then layer SDKs as they publish.

The direct API path is the safest integration baseline today: one endpoint, explicit auth, and sanitized output ready for downstream AI workflows.

Get your free API key