🔄

Face Swap API

active

AI-powered face swapping tool. Replace faces in images with natural-looking results.

WaveSpeedtool3 credits/call
Provider
WaveSpeed
Pricing
~$0.006 per swap (3 credits)
Speed
3–8 seconds
Output
image

Quick Start

Send a request to the Face Swap API:

bash
curl -X POST https://apiin.one/api/v1/images/tools/face-swap \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "face-swap",
  "image": "https://example.com/target-photo.jpg",
  "face_image": "https://example.com/source-face.jpg",
  "target_index": 0,
  "output_format": "png"
}'

API Endpoint

POST/api/v1/images/tools/face-swap
Send a POST request with your API key to generate content using Face Swap.

Headers

HeaderTypErforderlichBeschreibung
AuthorizationstringErforderlichBearer YOUR_API_KEY
Content-TypestringErforderlichapplication/json

Body Parameters

ParameterTypErforderlichBeschreibung
modelstringErforderlichModel identifier: "face-swap"
imagestringErforderlichURL of the target image (the body/scene to modify)
face_imagestringErforderlichURL of the source face image (the face to swap in)
target_indexnumberOptionalFace index in target image if multiple faces (0–10) (Standard: 0)
output_formatstringOptionalOutput format: "png", "jpg", or "webp" (Standard: png)

Example Request

json
{
  "model": "face-swap",
  "image": "https://example.com/target-photo.jpg",
  "face_image": "https://example.com/source-face.jpg",
  "target_index": 0,
  "output_format": "png"
}

Example Response

Successful task creation response.

{
  "code": 200,
  "message": "success",
  "data": {
    "task_id": "n33xxxx_faceswap",
    "status": "IN_PROGRESS"
  }
}

Check Task Status

For asynchronous tasks, poll the status endpoint to check when your task is complete:

GET/api/v1/tasks/{task_id}
Returns the current status of a generation task. Poll until status is 'completed' or 'failed'.
bash
curl https://apiin.one/api/v1/tasks/task_abc123 \
  -H "Authorization: Bearer aio_your_key"

Use Cases

  • Create personalized marketing imagery
  • Build virtual try-on features for e-commerce
  • Generate personalized content at scale
  • Integrate face swap into photo editing apps

API Tester

Test the Face Swap API directly from your browser:

API-PlaygroundPOST

Error Codes

{
  "error": {
    "code": 400,
    "message": "Invalid parameters",
    "type": "invalid_request"
  }
}

Frequently Asked Questions

How much does Face Swap cost?

Only 3 credits per swap (~$0.006). One of the cheapest tools available.

How natural are the results?

The AI produces seamless results with proper lighting, skin tone, and angle matching.

Why Use Face Swap Through API in One?

1Extremely affordable at 3 credits per swap
2Natural-looking results with AI blending
3No account needed with WaveSpeed
4Fast processing time

Ready to use Face Swap?

Get Your API Key →