1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
const axios = require('axios');
const api_key = "YOUR API-KEY";
const url = "https://api.segmind.com/v1/faceswap-hyperface-by-facefusion";
const data = {
"source_image": "https://segmind-resources.s3.amazonaws.com/input/239704fa-c11a-4a80-a124-c61c30de07c0-hyperswap-source.jpg",
"target_image": "https://segmind-resources.s3.amazonaws.com/input/d4966189-937c-42e1-b047-9d11ebb81feb-hyperswap-target.jpg",
"model_name": "hyperswap_1c",
"output_format": "webp",
"output_quality": 70
};
(async function() {
try {
const response = await axios.post(url, data, { headers: { 'x-api-key': api_key } });
console.log(response.data);
} catch (error) {
console.error('Error:', error.response.data);
}
})();Input URL or base64 string of the face image. Recommended for high-quality source images.
URL or base64 string of the target image. Best if it has clear facial details.
Select the model variant; choose 1a for speed, 1c for quality.
Allowed values:
Choose output format; JPEG for compatibility, PNG for lossless quality.
Allowed values:
Set image quality; 70 for web, 95 for print.
min : 10,
max : 100
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Hyperswap is a next-generation AI face swapping model built for creators, developers, and production teams who need fast, accurate, and natural-looking identity transfer in images. Developed by the team behind FaceFusion, Hyperswap specializes exclusively in high-quality face replacement, preserving the target image’s lighting, angles, and expressions while seamlessly transferring the identity from a source face.
Engineered for both speed and fidelity, Hyperswap makes professional-grade face swapping accessible for entertainment, marketing, virtual production, and large-scale automated workflows.
Entertainment & Media: Produce concept previews, create alternate character versions, generate social media face swap content, or mock up scenes quickly and realistically.
Marketing & Advertising: Localize campaigns, test creative variations with different faces, or generate personalized promotional assets at scale.
Virtual Production & Gaming: Quickly create face-swapped character variants, populate worlds with diverse identities, or prototype avatar ideas.
Automation & Batch Workflows: Efficiently process large volumes of images using Hyperswap_1a for speed or 1b/1c for refined quality.
Hyperswap works on image inputs, not text prompts. For best results:
Higher output quality increases processing time. For large batches, hyperswap_1a with quality 80 is ideal; reserve 1c and higher-quality settings for final assets or high-visibility images.
How is Hyperswap different from FaceFusion? FaceFusion is the framework and engine, while Hyperswap is the specialized face swap model designed exclusively for identity transfer with high accuracy and speed-quality variants.
What’s the difference between hyperswap_1a, 1b, and 1c?
Does Hyperswap do face enhancement or beautification? No. Hyperswap is strictly a face swapping model and does not alter or enhance facial features beyond identity transfer.
Can I use Hyperswap with partially obscured faces? It works best with clear, visible faces. Heavy occlusion (masks, hair, strong shadows) may reduce accuracy.
What output format should I choose?
Does Hyperswap work with multiple faces in one image? Hyperswap swaps the most prominent detected face. For multi-face swaps, process each face separately for full control.