Face Swap Plus API-Referenz
Gesichtertausch mit automatischem Hautton-Abgleich
Mit einem einzigen PopNow-API-Schlüssel rufst du Face Swap Plus aus deinem eigenen Code auf. Hier findest du die Modell-IDs, jedes Eingabefeld, die Kosten pro Anfrage in Credits und eine Anfrage, die du direkt ins Terminal kopieren kannst.
Die Parameterbeschreibungen stammen aus dem Eingabeschema des Modells und sind nur auf Englisch verfügbar.
Auf einen Blick
- Hersteller
- PopNow
- Ergebnis
- Bild
- Ab
- 24 Credits pro Bild ($0.24)
- Typische Dauer
- etwa 31 s
- Modell-IDs
1 Credit = 0,01 $. Bei Annahme reserviert ein Task den höchstmöglichen Betrag und rechnet am Ende den tatsächlichen Verbrauch ab, auf ganze Credits aufgerundet; der Rest wird freigegeben. Fehlgeschlagene Tasks kosten nichts. Den genauen Betrag vorab liefert POST /api/v1/jobs/quote.
Gesichtertausch
popnow/face-swap-v1-plus/edit
Preis
| Option | Credits (pro Bild) | US-Dollar |
|---|---|---|
Standard | 24 | $0.24 |
Parameter
| Feld | Typ | Standardwert | Erlaubt | Bedeutung |
|---|---|---|---|---|
image_urlPflicht | string | — | — | Target image. The face of the person in this image is the one that gets replaced. |
reference_image_urlPflicht | string | — | — | Reference face image. The facial identity from this image is transferred onto the target. |
promptOptional | string | — | bis zu 200 Zeichen | Optional short note guiding one subtle attribute of the result, such as an accessory, an expression or a different hairstyle. |
output_formatOptional | string | jpeg | png, jpeg, webp | File format of the returned image. |
output_qualityOptional | integer | 95 | 10 bis 100 | Requested image quality for the result, from 10 to 100. |
seedOptional | integer | — | 0 bis 2147483647 | Random seed; reuse it to keep two runs over the same image pair comparable. |
Beispielanfrage
Diese Anfrage läuft so, wie sie ist; weggelassene Felder behalten ihren Standardwert. Leg deinen Schlüssel vorher in POPNOW_API_KEY ab.
Das Beispiel nutzt in image_url, reference_image_url Beispieldateien von PopNow. Ersetze sie durch eigene öffentliche HTTPS-Links, Uploads oder gespeicherte Assets.
curl -X POST "https://api.popnow.ai/api/v1/jobs/createTask?wait=60" \
-H "Authorization: Bearer $POPNOW_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"model": "popnow/face-swap-v1-plus/edit",
"input": {
"prompt": "Change the orange jacket to deep forest green and add soft golden-hour light; keep the face, pose and background unchanged",
"image_url": "https://media.popnow.ai/influencer/examples/marco.webp",
"reference_image_url": "https://media.popnow.ai/influencer/examples/ava.webp"
}
}'Die Antwort enthält sofort eine taskId. Das Ergebnis holst du mit GET /api/v1/jobs/recordInfo ab – oder du gibst callBackUrl mit und wirst benachrichtigt.
curl "https://api.popnow.ai/api/v1/jobs/recordInfo?taskId=TASK_ID_FROM_CREATE_TASK" \
-H "Authorization: Bearer $POPNOW_API_KEY"
