Skip to main content
GET
/
api
/
open
/
v3
/
faceswap
/
result
/
listbyids
Get Faceswap Result List
curl --request GET \
  --url https://openapi.akool.com/api/open/v3/faceswap/result/listbyids \
  --header 'x-api-key: <api-key>'
import requests

url = "https://openapi.akool.com/api/open/v3/faceswap/result/listbyids"

headers = {"x-api-key": "<api-key>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};

fetch('https://openapi.akool.com/api/open/v3/faceswap/result/listbyids', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://openapi.akool.com/api/open/v3/faceswap/result/listbyids",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://openapi.akool.com/api/open/v3/faceswap/result/listbyids"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("x-api-key", "<api-key>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://openapi.akool.com/api/open/v3/faceswap/result/listbyids")
.header("x-api-key", "<api-key>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://openapi.akool.com/api/open/v3/faceswap/result/listbyids")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'

response = http.request(request)
puts response.read_body
{
  "code": 1000,
  "msg": "OK",
  "data": {
    "result": [
      {
        "faceswap_type": 123,
        "faceswap_quality": 123,
        "deduction_status": 123,
        "image": 123,
        "video_duration": 123,
        "deduction_duration": 123,
        "update_time": 123,
        "_id": "<string>",
        "userId": "<string>",
        "uid": 123,
        "url": "<string>",
        "createdAt": "2023-11-07T05:31:56Z"
      }
    ]
  }
}

Important Notes

Faceswap Status

StatusDescription
1In Queue
2Processing
3Success
4Failed

Authorizations

x-api-key
string
header
required

Your API Key used for request authorization. If both Authorization and x-api-key have values, Authorization will be used first and x-api-key will be discarded.

Query Parameters

_ids
string
required

Result IDs are strings separated by commas

Response

200 - application/json

List of faceswap results

code
integer
required

Interface returns business status code (1000: success)

Example:

1000

msg
string
required

Interface returns status information

Example:

"OK"

data
object