# Username Profanity API

> Username Profanity flags offensive or inappropriate usernames before they reach your database. Send any candidate handle to receive a clear true or false profanity check result; paid plans add the matched words and categories, reserved-name and contact-detail checks, a masked version of the username and a single allowed verdict.

**Endpoint:** `GET https://api.apiverve.com/v1/usernameprofanity`  
**Category:** Data Validation  
**Cost:** 2 credits per call  
**Canonical page:** https://apiverve.com/marketplace/usernameprofanity

## Overview

A username moderation API for sign-up forms. Username Profanity Checker analyses the username as a whole, split on underscores, separators and camelCase, and collapsed when it is letter-spaced, so decorated and leetspeak profanity is caught without flagging real names. Paid plans return the matched words and their categories, whether it impersonates a reserved name such as admin or support, any email, URL or phone number it contains, the username with the offending part masked, and isAllowed, one verdict that combines all of them.

## Authentication

Every call carries your key in an `x-api-key` header. The same key works across the whole
APIVerve catalog — there are no per-API subscriptions. Responses always use the same three
top-level keys: `status`, `error`, and `data`.

## Example request

```bash
curl "https://api.apiverve.com/v1/usernameprofanity?username=b00bs" \
  -H "x-api-key: YOUR_API_KEY"
```

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `username` | string | Yes | The username to check if it is inappropriate or profane |

## Response fields

- `username` — string · The username that was analyzed for profanity
- `isProfane` — boolean · Whether the username contains profane or inappropriate content
- `matchedWords` — array · The root words matched, after undoing leetspeak, separators and letter-spacing (e.g. xX_sh1t_Xx gives shit) · (premium)
- `categories` — array · Categories of the matched words: slur, sexual, insult, obscene, hate (extremist terms) or childSafety · (premium)
- `isReserved` — boolean · Whether the username poses as staff or the system, such as admin, Adm1n, support_team or noreply · (premium)
- `reservedTerm` — object · The reserved term it claims, or null · (premium)
- `contactInfo` — array · Contact details hidden in the username: email, url or phone · (premium)
- `censored` — string · The username with each matched word masked after its first character (unchanged when clean) · (premium)
- `isAllowed` — boolean · True when the username is not profane, not a reserved name and contains no contact details · (premium)

## Sample response

```json
{
  "status": "ok",
  "error": null,
  "data": {
    "username": "b00bs",
    "isProfane": true,
    "matchedWords": [
      "boob"
    ],
    "categories": [
      "sexual"
    ],
    "isReserved": false,
    "reservedTerm": null,
    "contactInfo": [],
    "censored": "b***s",
    "isAllowed": false
  }
}
```

## Use cases

- **Account Registration Screen** — When visitors submit a signup form, frontend forms check the handle and prompt the user for an alternative if flagged.
- **Multiplayer Gamertag Moderation** — Game servers inspect player handles during character creation to reject offensive gamertags before letting players join public lobbies.
- **Community Profile Updates** — To stop disruptive members from renaming accounts to slurs, community moderators automatically block profane handle changes across social feeds.
- **Event Badge Printing** — Event organizers screen attendee display names before printing badges or rendering leaderboards to prevent objectionable text on public screens.

## SDKs

- **npm** — `npm install @apiverve/usernameprofanity` (https://www.npmjs.com/package/@apiverve/usernameprofanity)
- **PyPI** — `pip install apiverve-usernameprofanity` (https://pypi.org/project/apiverve-usernameprofanity/)
- **NuGet** — `dotnet add package APIVerve.API.UsernameProfanity` (https://www.nuget.org/packages/APIVerve.API.UsernameProfanity)
- **Source** — https://github.com/apiverve/usernameprofanity-api

## More

- Full reference: https://docs.apiverve.com/ref/usernameprofanity
- Get an API key: https://dashboard.apiverve.com
- Full catalog: https://apiverve.com/marketplace
