Image Verifier
이미지 검증기 API
두 이미지를 비교하고 유사도를 분석합니다
POST
/
v3
/
modules
/
match
/
image
Compare two images
curl --request POST \
--url https://api.argosidentity.com/v3/modules/match/image \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"imageSet": {
"originalImage": "base64_encoded_image_1",
"compareImage": "base64_encoded_image_2"
}
}
'import requests
url = "https://api.argosidentity.com/v3/modules/match/image"
payload = { "imageSet": {
"originalImage": "base64_encoded_image_1",
"compareImage": "base64_encoded_image_2"
} }
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
imageSet: {
originalImage: 'base64_encoded_image_1',
compareImage: 'base64_encoded_image_2'
}
})
};
fetch('https://api.argosidentity.com/v3/modules/match/image', 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://api.argosidentity.com/v3/modules/match/image",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'imageSet' => [
'originalImage' => 'base64_encoded_image_1',
'compareImage' => 'base64_encoded_image_2'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.argosidentity.com/v3/modules/match/image"
payload := strings.NewReader("{\n \"imageSet\": {\n \"originalImage\": \"base64_encoded_image_1\",\n \"compareImage\": \"base64_encoded_image_2\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.argosidentity.com/v3/modules/match/image")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"imageSet\": {\n \"originalImage\": \"base64_encoded_image_1\",\n \"compareImage\": \"base64_encoded_image_2\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.argosidentity.com/v3/modules/match/image")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"imageSet\": {\n \"originalImage\": \"base64_encoded_image_1\",\n \"compareImage\": \"base64_encoded_image_2\"\n }\n}"
response = http.request(request)
puts response.read_body{
"originalHash": "70",
"compareHash": "71",
"hammingDistance": 2
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}이미지 검증기는 사용자가 두 이미지를 입력하고 유사도를 분석할 수 있게 하여 유사도 수준을 나타내는 결과를 제공합니다. 이 기능은 다양한 사용 사례에 적용할 수 있어 사용자가 특정 요구사항에 맞게 쉽게 적용할 수 있습니다.
요청
헤더
string
필수
인증 및 접근 제어 목적으로 필수적인 API 키로, 인증에 필요합니다.
본문 매개변수
object
필수
비교할 두 이미지를 포함하는 객체입니다.
string
필수
비교할 첫 번째 이미지를 base 64 형식으로 제공합니다.
string
필수
원본 이미지와 비교할 이미지를 base 64 형식으로 제공합니다.
응답
성공 응답 (200)
string
원본 이미지의 P Hash 값 (16진수)
string
비교 이미지의 P Hash 값 (16진수)
number
두 해시 값 간의 해밍 거리로, 이미지의 유사도를 나타냅니다. 값이 작을수록 이미지가 더 유사합니다.
오류 응답 (400)
string
오류에 대한 간략한 설명입니다.
요청 예시
{
"imageSet": {
"originalImage": "base64_encoded_image_1",
"compareImage": "base64_encoded_image_2"
}
}
응답 예시
{
"originalHash": "70",
"compareHash": "71",
"hammingDistance": 2
}
인증
본문
application/json
Show child attributes
Show child attributes
응답
Everything worked as expected.
P Hash value of the original image (hexadecimal)
예시:
"70"
P Hash value of the Compare image (hexadecimal)
예시:
"71"
Hamming Distance between the two hash values, indicating the similarity of the images. A smaller value means the images are more similar.
예시:
2
이 페이지가 도움이 되었나요?
⌘I
Compare two images
curl --request POST \
--url https://api.argosidentity.com/v3/modules/match/image \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"imageSet": {
"originalImage": "base64_encoded_image_1",
"compareImage": "base64_encoded_image_2"
}
}
'import requests
url = "https://api.argosidentity.com/v3/modules/match/image"
payload = { "imageSet": {
"originalImage": "base64_encoded_image_1",
"compareImage": "base64_encoded_image_2"
} }
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
imageSet: {
originalImage: 'base64_encoded_image_1',
compareImage: 'base64_encoded_image_2'
}
})
};
fetch('https://api.argosidentity.com/v3/modules/match/image', 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://api.argosidentity.com/v3/modules/match/image",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'imageSet' => [
'originalImage' => 'base64_encoded_image_1',
'compareImage' => 'base64_encoded_image_2'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.argosidentity.com/v3/modules/match/image"
payload := strings.NewReader("{\n \"imageSet\": {\n \"originalImage\": \"base64_encoded_image_1\",\n \"compareImage\": \"base64_encoded_image_2\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.argosidentity.com/v3/modules/match/image")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"imageSet\": {\n \"originalImage\": \"base64_encoded_image_1\",\n \"compareImage\": \"base64_encoded_image_2\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.argosidentity.com/v3/modules/match/image")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"imageSet\": {\n \"originalImage\": \"base64_encoded_image_1\",\n \"compareImage\": \"base64_encoded_image_2\"\n }\n}"
response = http.request(request)
puts response.read_body{
"originalHash": "70",
"compareHash": "71",
"hammingDistance": 2
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}