---
title: "Classify speaker gender (file upload)"
method: POST
path: "/gender-detection/classify/upload"
tags: ["Gender Detection"]
---

# Classify speaker gender (file upload)

`POST /gender-detection/classify/upload`

Classify the gender of the speaker from an uploaded audio file. Accepts audio files in WAV, MP3, FLAC, OGG, and other common formats.

## Headers

- `x-api-key` string, required

## Response `200`

Successful classification

- ModelGenderClassificationResponse — Gender classification result
  - `predicted_gender` 'female' | 'male', required — Predicted gender of the speaker
  - `confidence` number, required — Confidence score (0.0 to 1.0)
  - `prediction` object — Full prediction scores for both genders
    - `female` number — Probability of female speaker
    - `male` number — Probability of male speaker
  - `duration_seconds` number — Duration of the audio in seconds
  - `processing_time_ms` number — Processing time in milliseconds

## Other responses

- `400` — Bad request
- `401` — Unauthorized — invalid or missing API key
- `500` — Internal server error

---

[API](https://skmtc.dev/deepdub-ai/apis/deepdub-api.md) · [All operations](https://skmtc.dev/deepdub-ai/apis/deepdub-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/deepdub-ai/deepdub-api/revisions/903a930c3849/schema)
