---
title: "Extract names and infer gender from multiple usernames"
method: POST
path: "/api/username/multi/country"
tags: ["Gender inference"]
---

# Extract names and infer gender from multiple usernames

`POST /api/username/multi/country`

## Request

- Base URL: `https://api.genderapi.io`
- URL: `https://api.genderapi.io/api/username/multi/country`
- Auth: HTTP bearer

Canonical documentation: https://www.genderapi.io/docs-gender-from-username-multiple

## Request body

- object
  - `data` object[], required
    - `username` string, required
    - `country` string: ISO 3166-1 alpha-2 country code used as regional context.
    - `id` union: Caller record identifier.
      - string
      - integer

## Response `200`

Application response. Inspect status before reading result fields; live verification observed validation and authentication errors inside HTTP 200 responses.

- union
  - BatchLookupResponse
    - `status` true, required
    - `used_credits` integer: Credits consumed for processed records.
    - `remaining_credits` integer
    - `expires` integer: Package expiration as a UNIX timestamp.
    - `duration` string
    - `names` object[], required: Contains a result for every processed input, including unresolved results with gender "null". Live verification observed that a malformed entry missing the required name was omitted while valid entries were processed.
      - `name` string
      - `q` string: Original submitted value.
      - `gender` 'male' | 'female' | 'null': Probabilistic result. An unresolved input is returned as the literal string "null", not JSON null.
      - `country` string: ISO 3166-1 alpha-2 country code used as regional context.
      - `total_names` integer
      - `probability` integer
      - `id` union: Caller record identifier.
        - string
        - integer
  - Error
    - `status` false, required
    - `errno` 50 | 90 | 91 | 92 | 93 | 94 | 99, required
    - `errmsg` string, required

## Other responses

- `400`: Request rejected. Branch on errno rather than errmsg text.
- `401`: Request rejected. Branch on errno rather than errmsg text.
- `403`: Request rejected. Branch on errno rather than errmsg text.
- `404`: Authentication rejected by a gender-inference handler. Current backend compatibility behavior uses HTTP 404 with an Error body for this branch.
- `429`: Request rejected. Branch on errno rather than errmsg text.

---

[API](https://skmtc.dev/genderapi/apis/genderapi-public-api.md) · [All operations](https://skmtc.dev/genderapi/apis/genderapi-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/genderapi/apis/genderapi-public-api/revisions/800e7a9d2a0e?raw)
