{"openapi":"3.1.0","info":{"title":"Redact API","version":"1.0.0","description":"Detect and redact personally identifiable information (PII) in free text. It finds email addresses, phone numbers, credit-card numbers (Luhn-validated to cut false positives), IPv4 and IPv6 addresses, US Social Security numbers and IBANs, and masks each one — with a per-type label like [EMAIL], a fixed replacement string, or a single character repeated to the original length. A detect endpoint returns every match with its type and position without changing the text. Perfect for scrubbing logs and support transcripts, sanitising data before sharing or sending to a third party, and privacy and compliance pre-checks. Pure local computation — text never leaves the server, no key, no third party, instant; up to 200,000 characters via POST. Live, nothing stored. 3 endpoints. Regex-based and best-effort — review before relying on it for legal compliance. Distinct from sentiment, profanity and general text tooling.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/redact-api","description":"oanor gateway"}],"tags":[{"name":"Redact"},{"name":"Meta"}],"components":{"securitySchemes":{"oanorKey":{"type":"apiKey","in":"header","name":"x-oanor-key","description":"Get your key at https://www.oanor.com/developer/keys"}}},"security":[{"oanorKey":[]}],"paths":{"/v1/detect":{"get":{"operationId":"get_v1_detect","tags":["Redact"],"summary":"Detect PII in text","description":"","parameters":[{"name":"text","in":"query","required":true,"description":"Text to scan","schema":{"type":"string"},"example":"Contact john.doe@example.com or call +1 (555) 123-4567."},{"name":"types","in":"query","required":false,"description":"Optional type filter","schema":{"type":"string"}}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"total":2,"counts":{"email":1,"phone":1},"matches":[{"end":28,"type":"email","start":8,"value":"john.doe@example.com"},{"end":54,"type":"phone","start":37,"value":"+1 (555) 123-4567"}]},"meta":{"timestamp":"2026-06-03T09:25:09.330Z","request_id":"9e35543d-206a-46ca-9437-e393f806c55f"},"status":"ok","message":"Detect PII in text","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/redact":{"get":{"operationId":"get_v1_redact","tags":["Redact"],"summary":"Redact PII in text","description":"","parameters":[{"name":"text","in":"query","required":true,"description":"Text to redact","schema":{"type":"string"},"example":"Contact john.doe@example.com or call +1 (555) 123-4567."},{"name":"types","in":"query","required":false,"description":"Comma list e.g. email,phone (default all)","schema":{"type":"string"}},{"name":"mask","in":"query","required":false,"description":"Label, string, or single char","schema":{"type":"string"}}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"counts":{"email":1,"phone":1},"redacted":"Contact [EMAIL] or call [PHONE].","total_redacted":2},"meta":{"timestamp":"2026-06-03T09:25:09.435Z","request_id":"425f6f82-e8b5-479f-a9ef-40cbbc946c13"},"status":"ok","message":"Redact PII in text","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/meta":{"get":{"operationId":"get_v1_meta","tags":["Meta"],"summary":"Spec","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"name":"Redact API","notes":"Types: email, phone, credit_card, ssn, ipv4, ipv6, iban (use 'ip' for both v4 and v6). Regex-based and best-effort — review before relying on it for compliance. Nothing is stored.","version":"v1","endpoints":[{"path":"/v1/redact","params":{"mask":"a label, a string, or a single char to repeat","text":"the text (required)","types":"comma list e.g. email,phone (default all)"},"returns":"the redacted text and per-type counts"},{"path":"/v1/detect","params":{"text":"the text (required)","types":"optional filter"},"returns":"the matches with their positions, without masking"},{"path":"/v1/meta","params":[],"returns":"this document"}],"description":"Detect and redact personally identifiable information (PII) in free text — email addresses, phone numbers, credit-card numbers (Luhn-validated), IPv4/IPv6 addresses, US Social Security numbers and IBANs. Mask them with a per-type label, a fixed string or a repeated character, or just detect them with positions. Pure local, no key — text never leaves the server."},"meta":{"timestamp":"2026-06-03T09:25:09.539Z","request_id":"d261beca-42e3-44fb-adfc-e9037649be80"},"status":"ok","message":"Meta","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}}},"x-oanor-pricing":[{"slug":"free","name":"Free","price_cents_month":0,"monthly_call_quota":1195,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":235,"monthly_call_quota":10350,"rps_limit":8,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":2225,"monthly_call_quota":154500,"rps_limit":20,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":6025,"monthly_call_quota":815000,"rps_limit":50,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/redact-api"}