Alectura sits between your product and its model providers. Every request gets the policy its customer requires: where it’s processed, which models see it, what’s kept, what’s redacted, and what happens when an account turns abusive.
import os
from google import genai
client = genai.Client(
api_key=os.environ["ALECTURA_API_KEY"],
http_options={
"base_url": "https://us.gateway.alecturalabs.com/gemini",
"headers": {
"Alectura-Organization": "initech",
"Alectura-User": "user_42",
"Alectura-Plan": "pro",
},
},
)
response = client.models.generate_content(
model="gemini-3.5-flash",
contents="Say hello in French.",
)
print(response.text)
The base URL and the key: the whole integration
Who the request is for, in your own identifiers
Why
Two gaps stand between an AI product and enterprise scale.
Neither is about model quality.
01 · Control
Each customer wants its own answers
Enterprise buyers want a say in how their data meets a model: which region processes it, which models may see it, whether anything is kept, and what is redacted. Each asks for something different, and most products can give one answer for everyone.
Alectura gives each of your customers its own policy.
02 · Abuse
A free tier is a token supply
Accounts on free and cheap plans get farmed, wrapped in adapters and resold as someone else’s tokens, and much of what flows through is content you don’t want your name on. Signup checks can’t see it: it shows only across the requests themselves.
Alectura watches users across requests, and stops them.
Both sit at the same place in your architecture: where your servers call a model provider. That’s where Alectura runs.
How it works
One hop, 16 steps.
Every request runs the same pipeline, compiled from the policies that match it. Everything before the provider happens in memory, so the provider is the only network hop, and the budget for it all is 3 ms at the median for bodies up to 256 KB.
Your serversAlecturaOpenAI · Anthropic · Bedrock · Gemini · OpenRouter
01SuspensionRefuses an organization or user you have suspended.
02ServedRefuses a model no connection serves, suggesting the nearest one you allow.
03LimitsHolds rate, token and spend limits, and reserves the request’s estimate.
04UninspectedRefuses content nothing can inspect, such as an image, where the policy says to.
05Tool callsChecks each tool call in the answer against the tools and arguments you allow, and cuts the answer before your app gets a call you don’t.
06SecretsRedacts keys and credentials before anything leaves.
07Your own patternsFinds your regexes and word lists, such as ticket ids or code names, and redacts or blocks them.
08PseudonymizeSwaps personal data for pseudonyms, and restores it in the response.
09InjectionChecks for prompt injection alongside the provider call, and cuts it if it fires.
10Illegal contentJudges requests for help with a crime, tool results included, and blocks them before the provider sees them.
11Harmful contentJudges hate, harassment, self-harm, sexual content and violence in the request and the answer, and blocks or cuts it where you say.
12System prompt leakCompares the answer with your system prompt as it streams, and cuts an answer that repeats it.
13GroundingChecks each sentence of the answer against your system prompt, your users’ messages and tool results, and records the ones they do not support.
14RetentionDecides what the record keeps, and tells OpenAI not to store the response.
15Safety IDGives the provider a keyed hash of your user where its API takes one, so it acts on one user, not you.
16RouteChecks the model is allowed, then picks a region and connection, falling back to the next connection if one fails.
On the way back, the steps run in reverse over the stream: pseudonyms are restored as text arrives, and a stream an injection check stops ends in the provider’s own error format, so your error handling already works.
Policy per customer
Your customers set the terms. Alectura keeps them.
A policy matches requests by organization, user or plan, and every policy that matches applies. Guardrails, limits and retention take the strictest value any of them sets. Regions, models and connections are lists that start from the request: a policy can keep only some of one or remove some, and add a region or a connection, but no policy’s add brings back what another kept out.
Each request records the policies that matched it at their versions, what each detector found and what it did, and what nothing could inspect. A verdict never claims more than its coverage.
Refusals are recorded too, from the moment the key is known.
Records are kept 400 days, whatever the content’s retention.
With zero retention, a record keeps verdicts, counts and keyed hashes: no content.
Each region runs a full copy of Alectura. An environment is pinned to one when it’s created: its requests are routed, processed and stored there, and leave only for a provider its policy allows.
US
United States
AWS us-east-1, N. Virginia
us.gateway.alecturalabs.com
EU
European Union
AWS eu-west-1, Ireland
eu.gateway.alecturalabs.com
AU
Australia
AWS ap-southeast-2, Sydney
au.gateway.alecturalabs.com
Your keys, your contracts
Alectura doesn’t resell inference.
Requests go to your own provider accounts, on your own keys, so the prices, zero-retention terms and regional commitments you negotiated stay in force.
A connection is a credential, an endpoint and its region, with the provider’s data terms declared: whether it retains, and whether it trains.
An enterprise customer can bring its own provider account, and its requests stay on it unless its policy lets them fall back to yours.
Credentials are stored sealed, and no API ever returns them.
Make your product enterprise AI ready.
Create an environment, connect a provider, and change two lines.