# Leaked Private AI API Token? Revoke It Quickly

> Private AI API token exposed in code or logs? Revoke it, check the requests it served and rotate it. Step-by-step guide for privacy teams.

Source: https://leakwatch.net/secrets/privateai-api-token

---

[LeakWatch](/)

[Product](/product)[Live feed](/leaks)[Guides](/secrets)[Blog](/blog)[Free scan](/)

1.  [Home](/)
2.  [Secrets](/secrets)
3.  PrivateAI API Token

AI · Secret guide

# Leaked PrivateAI API Token: what to do in the first hour

High severityDetected onlyLast verified November 5, 2026 · 5 min read

A Private AI API token authenticates requests to a service that detects and redacts personal information in text, such as names, contact details and identifiers. The service is often placed in front of other systems so that sensitive data is masked before it reaches a language model or a log. A leaked token is therefore a double concern: someone can use it to run requests against your account, and the content your team sends through the service may include the very data it was meant to protect. Revoke the token first, then look at what was processed.

[Check your GitHub account for leaked secrets — free](/)

Provider

PrivateAI

Severity

High

Impact

SaaS account access and billing

Checked live by LeakWatch

No

## What a Private AI API token looks like

Private AI tokens are short random strings of lower-case letters and digits, about 32 characters in the form the rule expects. They have no public prefix, so they are recognized by their context. The value is normally stored in a variable whose name contains `private_ai`, `private-ai` or `privateai`, in a configuration file or in a hosting provider’s settings:

```text
PRIVATE_AI_API_KEY=<32-character value, masked as XXXX…>
```

Because the value looks like many other random strings, the name next to it matters. A value under a generic name, such as a plain `token` setting, is less likely to be reported, so check any file that calls a redaction or anonymization API. We could not confirm the exact format of the token from the vendor’s documentation during this review, so the description above reflects the rule and common practice.

## How Private AI tokens get leaked

-   **Pipeline configuration.** A data pipeline or a gateway configuration committed to a repository, with the token next to other service settings.
-   **Browser applications.** A redaction call made from front-end code, which exposes the token to anyone who opens the page.
-   **Logs.** A request logger that records headers, so the authorization value is stored in a log file that is shared or archived.
-   **Notebooks.** A data-science notebook that calls the service, with the token typed into a cell and saved when the notebook is shared.
-   **Shared examples.** A snippet pasted into a support thread or a forum to show a redaction call, with the real token left in.

## What to do in the first hour

1.  **Revoke the token.** Sign in to the Private AI account and remove the token from the account’s key settings. If you cannot find the key screen, ask the account administrator. Do this before you clean the repository.
2.  **Create a replacement** for each service that needs one, and store it in a secret manager or an environment variable. Confirm that a test request succeeds before you switch production traffic.
3.  **Review the requests.** Check the usage history for the period since the token may have been exposed. Look for volumes that do not match your normal traffic, for calls at unusual hours and for requests from sources you do not recognize.
4.  **Assess the data.** Think about what the token was used to process. If it covered text with personal information, your privacy obligations may apply. Involve the people responsible for data protection in your organization, and keep a record of what you found.
5.  **Check the other secrets** in the same file. Pipelines that handle sensitive data often hold keys for storage, databases and language model providers, so rotate those as well. The order of steps is in [I accidentally pushed an API key to GitHub](/blog/i-accidentally-pushed-an-api-key-to-github).
6.  **Clean the repository** after the rotation: remove the value from the files, add the file to `.gitignore` and decide whether to rewrite history. Old clones still hold the value.

Not sure what else leaked? [Run a free scan](/).

[Not sure what else leaked? Run a free scan.](/)

## Revoke it at Private AI

Sign in to Private AI and open the account settings, then the section where API keys or tokens are listed. Remove the leaked token and create a new one for the service that needs it. We did not find Private AI’s own developer documentation during this review, so we could not confirm the menu path, the revocation steps or whether a token can be regenerated in place. Check the labels in the dashboard, and if the key is not where you expect, contact the vendor’s support team before you assume it is gone.

## How LeakWatch detects it

The rule is called PrivateAI API Token. It looks for a name that contains `privateai`, `private_ai` or `private-ai`, optionally followed by a short label, a separator and then a value of exactly 32 lower-case letters or digits. The name must be close to the value, so a 32-character string under an unrelated name is not reported. The severity is **high**, with the impact class for SaaS services. **This type is not checked live**: LeakWatch does not send the value to Private AI.

LeakWatch detects this format but does **not** check it live: it can tell you the key is exposed, not whether it still works. Assume it does until you have revoked it.

## FAQ

If the token only redacts data, why is a leak serious?

Because the token can still be used to run requests, and those requests can carry sensitive text. Redaction is also a sign of what your system handles, so an attacker learns where the sensitive data flows.

Does a leak mean my data was exposed?

Not necessarily. A leaked token shows that someone could have used it. Check the usage history and the logs of the services that called the redaction API before you decide what happened.

Should I change how the service is called?

Yes, if the token was in front-end code or a shared notebook. Move the call to the server, read the token from a secret store, and avoid logging authorization headers.

## Related

-   [OpenAI API key](/secrets/openai-api-key)
-   [Mistral API Key](/secrets/mistral-api-key)
-   [Cohere API Token](/secrets/cohere-api-token)
-   [I accidentally pushed an API key to GitHub](/blog/i-accidentally-pushed-an-api-key-to-github)
-   [Which vendors leak most this week](/leaks/trends)
-   [All secret guides](/secrets)

[Get alerted next time a secret leaks — create a free account](/)

LeakWatch is not affiliated with PrivateAI.

![Gabriel Diyan, founder of LeakWatch](/brand/Photo-Gabriel-Diyan.webp)

Gabriel Diyan (0xCr0c0)

Cybersecurity student, founder of LeakWatch. I built and run the scanner described here — the detection patterns, the false-positive classifier and the provider validators are mine. [More about who I am](/about).

[GitHub](https://github.com/Leakwatch-Scan) · [X](https://x.com/LeakwatchScan) · [LinkedIn](https://www.linkedin.com/in/gabriel-diyan-80a378375) · [GitHub (personal)](https://github.com/crocogab)

LeakWatch

Secrets leak into public commits every minute. This watches the forges for yours. Built and run by [Gabriel Diyan](/about), a cybersecurity student — [why LeakWatch exists](/about).

Scan

-   [Product](/product)
-   [Live feed](/leaks)
-   [Trends](/leaks/trends)
-   [API docs](/docs)
-   [CI/CD](/docs?tab=ci)

Read

-   [Blog](/blog)
-   [Secret guides](/secrets)
-   [Changelog](/changelog)
-   [About](/about)

Verify

-   [Security](/security)
-   [Privacy](/privacy)
-   [Terms](/terms)
-   [Legal](/legal)
-   [Contact](/contact)
-   [Status](https://status.leakwatch.net)

© 2026 LeakWatch

[GitHub](https://github.com/Leakwatch-Scan)[X](https://x.com/LeakwatchScan)
