Référence API de Pose Changer
Change la pose d'après une courte description ou une photo de pose
Une seule clé API PopNow suffit pour appeler Pose Changer depuis votre code. Vous trouverez ici les identifiants de modèle à envoyer, chaque champ d’entrée accepté, le coût d’une requête en USD et une requête à coller telle quelle dans un terminal.
Les descriptions des paramètres proviennent du schéma d’entrée du modèle et ne sont disponibles qu’en anglais.
En bref
- Éditeur
- PopNow
- Résultat
- Image
- À partir de
- $0.03 USD par image
- Durée habituelle
- environ 15 s
- Identifiants de modèle
Les prix sont affichés en USD et les frais sont déduits de votre solde PopNow. Le montant maximal est réservé à la réception de la tâche, puis la consommation réelle est facturée à la fin et le solde libéré. Les tâches en échec ne sont pas facturées. Obtenez un devis exact avant de lancer avec POST /api/v1/jobs/quote.
Changer la pose
popnow/pose-changer-v1/edit
Prix
| Option | USD |
|---|---|
Par défaut | $0.03 par image |
Paramètres
| Champ | Type | Valeur par défaut | Valeurs admises | Rôle |
|---|---|---|---|---|
image_urlObligatoire | string | — | — | The person to re-pose, full body visible: JPEG, PNG or WebP, up to 10 MB. |
reference_image_urlObligatoire | string | — | — | A photo of the pose to copy; only the pose is used. JPEG, PNG or WebP, up to 10 MB. |
promptFacultatif | string | — | jusqu’à 5 000 caractères | Optional full pose-transfer prompt sent verbatim (refer to image_url as image 1 and reference_image_url as image 2). Leave blank to use the default AnyPose transfer template. |
aspect_ratioFacultatif | string | — | 1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 21:9, 9:21 | Optional output aspect ratio. Leave it empty to keep the shape of the photo. |
output_formatFacultatif | string | jpeg | jpeg, png, webp | File format of the returned image. |
seedFacultatif | integer | — | de 0 à 2147483647 | Random seed for controlled comparisons. |
Exemple de requête
Cette requête fonctionne telle quelle ; les champs omis gardent leur valeur par défaut. Placez d’abord votre clé dans POPNOW_API_KEY.
L’exemple utilise des fichiers d’exemple PopNow dans image_url, reference_image_url. Remplacez-les par vos propres liens HTTPS publics, fichiers envoyés ou ressources enregistrées.
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/pose-changer-v1/edit",
"input": {
"prompt": "Make the person in image 1 do the exact same pose of the person in image 2. Changing the style and background of the image of the person in image 1 is undesirable, so don'\''t do it. The new pose should be pixel accurate to the pose we are trying to copy. The position of the arms and head and legs should be the same as the pose we are trying to copy. Change the field of view and angle to match exactly image 2. Head tilt and eye gaze pose should match the person in image 2. Remove the background of image 2, and replace it with the background of image 1.",
"image_url": "https://media.popnow.ai/influencer/examples/marco.webp",
"reference_image_url": "https://media.popnow.ai/influencer/examples/ava.webp"
}
}'La réponse contient tout de suite un taskId. Récupérez le résultat avec GET /api/v1/jobs/recordInfo, ou ajoutez callBackUrl pour être prévenu.
curl "https://api.popnow.ai/api/v1/jobs/recordInfo?taskId=TASK_ID_FROM_CREATE_TASK" \
-H "Authorization: Bearer $POPNOW_API_KEY"
