All URIs are relative to https://api.onfido.com/v2
Method | HTTP request | Description |
---|---|---|
cancelReport | POST /checks/{check_id}/reports/{report_id}/cancel | This endpoint is for cancelling individual paused reports. |
createApplicant | POST /applicants | Create Applicant |
createCheck | POST /applicants/{applicant_id}/checks | Create a check |
createWebhook | POST /webhooks | Create a webhook |
destroyApplicant | DELETE /applicants/{applicant_id} | Delete Applicant |
downloadDocument | GET /applicants/{applicant_id}/documents/{document_id}/download | Download a documents raw data |
downloadLivePhoto | GET /live_photos/{live_photo_id}/download | Download live photo |
findAddresses | GET /addresses/pick | Search for addresses by postcode |
findApplicant | GET /applicants/{applicant_id} | Retrieve Applicant |
findCheck | GET /applicants/{applicant_id}/checks/{check_id} | Retrieve a Check |
findDocument | GET /applicants/{applicant_id}/documents/{document_id} | A single document can be retrieved by calling this endpoint with the document’s unique identifier. |
findLivePhoto | GET /live_photos/{live_photo_id} | Retrieve live photo |
findReport | GET /checks/{check_id}/reports/{report_id} | A single report can be retrieved using this endpoint with the corresponding unique identifier. |
findReportTypeGroup | GET /report_type_groups/{report_type_group_id} | Retrieve single report type group object |
findWebhook | GET /webhooks/{webhook_id} | Retrieve a Webhook |
listApplicants | GET /applicants | List Applicants |
listChecks | GET /applicants/{applicant_id}/checks | Retrieve Checks |
listDocuments | GET /applicants/{applicant_id}/documents | List documents |
listLivePhotos | GET /live_photos | List live photos |
listReportTypeGroups | GET /report_type_groups | Retrieve all report type groups |
listReports | GET /checks/{check_id}/reports | All the reports belonging to a particular check can be listed from this endpoint. |
listWebhooks | GET /webhooks | List webhooks |
resumeCheck | POST /checks/{check_id}/resume | Resume a Check |
resumeReport | POST /checks/{check_id}/reports/{report_id}/resume | This endpoint is for resuming individual paused reports. |
updateApplicant | PUT /applicants/{applicant_id} | Update Applicant |
uploadDocument | POST /applicants/{applicant_id}/documents | Upload a document |
uploadLivePhoto | POST /live_photos | Upload live photo |
cancelReport($check_id, $report_id)
This endpoint is for cancelling individual paused reports.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$check_id = "check_id_example"; // string |
$report_id = "report_id_example"; // string |
try {
$api_instance->cancelReport($check_id, $report_id);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
check_id | string | ||
report_id | string |
void (empty response body)
\Onfido\Models\Applicant createApplicant($data)
Create Applicant
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$data = new \Onfido\Models\Applicant(); // \Onfido\Models\Applicant |
try {
$result = $api_instance->createApplicant($data);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
data | \Onfido\Models\Applicant | [optional] |
\Onfido\Models\Check createCheck($applicant_id, $data)
Create a check
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
$data = new \Onfido\Models\CheckCreationRequest(); // \Onfido\Models\CheckCreationRequest |
try {
$result = $api_instance->createCheck($applicant_id, $data);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | ||
data | \Onfido\Models\CheckCreationRequest | [optional] |
\Onfido\Models\Webhook createWebhook($data)
Create a webhook
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$data = new \Onfido\Models\Webhook(); // \Onfido\Models\Webhook |
try {
$result = $api_instance->createWebhook($data);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
data | \Onfido\Models\Webhook | [optional] |
destroyApplicant($applicant_id)
Delete Applicant
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
try {
$api_instance->destroyApplicant($applicant_id);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string |
void (empty response body)
\SplFileObject downloadDocument($applicant_id, $document_id)
Download a documents raw data
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
$document_id = "document_id_example"; // string |
try {
$result = $api_instance->downloadDocument($applicant_id, $document_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | ||
document_id | string |
\SplFileObject downloadLivePhoto($live_photo_id)
Download live photo
Live photos are downloaded using this endpoint.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$live_photo_id = "live_photo_id_example"; // string | The live photo’s unique identifier.
try {
$result = $api_instance->downloadLivePhoto($live_photo_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
live_photo_id | string | The live photo’s unique identifier. |
\Onfido\Models\GenericAddressesList findAddresses($postcode)
Search for addresses by postcode
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$postcode = "postcode_example"; // string |
try {
$result = $api_instance->findAddresses($postcode);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
postcode | string |
\Onfido\Models\GenericAddressesList
\Onfido\Models\Applicant findApplicant($applicant_id)
Retrieve Applicant
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
try {
$result = $api_instance->findApplicant($applicant_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string |
\Onfido\Models\Check findCheck($applicant_id, $check_id)
Retrieve a Check
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
$check_id = "check_id_example"; // string |
try {
$result = $api_instance->findCheck($applicant_id, $check_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | ||
check_id | string |
\Onfido\Models\Document findDocument($applicant_id, $document_id)
A single document can be retrieved by calling this endpoint with the document’s unique identifier.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
$document_id = "document_id_example"; // string |
try {
$result = $api_instance->findDocument($applicant_id, $document_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | ||
document_id | string |
\Onfido\Models\LivePhoto findLivePhoto($live_photo_id)
Retrieve live photo
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$live_photo_id = "live_photo_id_example"; // string | The live photo’s unique identifier.
try {
$result = $api_instance->findLivePhoto($live_photo_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
live_photo_id | string | The live photo’s unique identifier. |
\Onfido\Models\Report findReport($check_id, $report_id)
A single report can be retrieved using this endpoint with the corresponding unique identifier.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$check_id = "check_id_example"; // string |
$report_id = "report_id_example"; // string |
try {
$result = $api_instance->findReport($check_id, $report_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
check_id | string | ||
report_id | string |
\Onfido\Models\ReportTypeGroup findReportTypeGroup($report_type_group_id)
Retrieve single report type group object
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$report_type_group_id = "report_type_group_id_example"; // string |
try {
$result = $api_instance->findReportTypeGroup($report_type_group_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
report_type_group_id | string |
\Onfido\Models\ReportTypeGroup
\Onfido\Models\Webhook findWebhook($webhook_id)
Retrieve a Webhook
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$webhook_id = "webhook_id_example"; // string |
try {
$result = $api_instance->findWebhook($webhook_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
webhook_id | string |
\Onfido\Models\ApplicantsList listApplicants($page, $per_page)
List Applicants
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$page = "page_example"; // string | The page to return. Defaults to the first page if omitted. The first page is `page=1`
$per_page = "per_page_example"; // string | The number of objects per page. Defaults to 20 if omitted.
try {
$result = $api_instance->listApplicants($page, $per_page);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
page | string | The page to return. Defaults to the first page if omitted. The first page is `page=1` | [optional] |
per_page | string | The number of objects per page. Defaults to 20 if omitted. | [optional] |
\Onfido\Models\ChecksList listChecks($applicant_id, $page, $per_page)
Retrieve Checks
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
$page = "page_example"; // string | The page to return. Defaults to the first page if omitted. The first page is `page=1`
$per_page = "per_page_example"; // string | The number of objects per page. Defaults to 20 if omitted.
try {
$result = $api_instance->listChecks($applicant_id, $page, $per_page);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | ||
page | string | The page to return. Defaults to the first page if omitted. The first page is `page=1` | [optional] |
per_page | string | The number of objects per page. Defaults to 20 if omitted. | [optional] |
\Onfido\Models\DocumentsList listDocuments($applicant_id)
List documents
All documents belonging to an applicant can be listed from this endpoint
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
try {
$result = $api_instance->listDocuments($applicant_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string |
\Onfido\Models\LivePhotosList listLivePhotos($applicant_id)
List live photos
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string | The id of the applicant the live photos belongs to.
try {
$result = $api_instance->listLivePhotos($applicant_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | The id of the applicant the live photos belongs to. |
\Onfido\Models\ReportTypeGroupsList listReportTypeGroups()
Retrieve all report type groups
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
try {
$result = $api_instance->listReportTypeGroups();
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
This endpoint does not need any parameter.
\Onfido\Models\ReportTypeGroupsList
\Onfido\Models\ReportsList listReports($check_id)
All the reports belonging to a particular check can be listed from this endpoint.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$check_id = "check_id_example"; // string |
try {
$result = $api_instance->listReports($check_id);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
check_id | string |
\Onfido\Models\WebhooksList listWebhooks()
List webhooks
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
try {
$result = $api_instance->listWebhooks();
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
This endpoint does not need any parameter.
resumeCheck($check_id)
Resume a Check
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$check_id = "check_id_example"; // string |
try {
$api_instance->resumeCheck($check_id);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
check_id | string |
void (empty response body)
resumeReport($check_id, $report_id)
This endpoint is for resuming individual paused reports.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$check_id = "check_id_example"; // string |
$report_id = "report_id_example"; // string |
try {
$api_instance->resumeReport($check_id, $report_id);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
check_id | string | ||
report_id | string |
void (empty response body)
\Onfido\Models\Applicant updateApplicant($applicant_id, $data)
Update Applicant
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
$data = new \Onfido\Models\Applicant(); // \Onfido\Models\Applicant |
try {
$result = $api_instance->updateApplicant($applicant_id, $data);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | ||
data | \Onfido\Models\Applicant | [optional] |
\Onfido\Models\Document uploadDocument($applicant_id, $type, $side, $file)
Upload a document
Documents are uploaded using this endpoint. Along with the file upload the relevant document type must be specified. Documents must be uploaded as a multipart form. The valid file types are: jpg, png and pdf. The file size must be between 2KB and 3MB.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string |
$type = "type_example"; // string |
$side = "side_example"; // string |
$file = "/path/to/file.txt"; // \SplFileObject |
try {
$result = $api_instance->uploadDocument($applicant_id, $type, $side, $file);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | ||
type | string | ||
side | string | [optional] | |
file | \SplFileObject | [optional] |
\Onfido\Models\LivePhoto uploadLivePhoto($applicant_id, $file, $advanced_validation)
Upload live photo
You can upload live photos to this endpoint. Like document upload, files must be uploaded as a multipart form. Valid file types are jpg, png and pdf. The file size must be between 32KB and 10MB. Live photos are validated at the point of upload to check that they contain exactly one face. This validation can be disabled by setting the advanced_validation argument to false.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: Token
Onfido\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'token=' . 'YOUR_API_KEY');
Onfido\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Token');
$api_instance = new Onfido\Api\DefaultApi();
$applicant_id = "applicant_id_example"; // string | The applicant_id to associate the live photo to.
$file = "/path/to/file.txt"; // \SplFileObject | The file to be uploaded.
$advanced_validation = true; // bool | Validates that the live photo contains exactly one face.
try {
$result = $api_instance->uploadLivePhoto($applicant_id, $file, $advanced_validation);
print_r($result);
} catch (Exception $e) {
print_r($e->getResponseBody());
}
?>
Name | Type | Description | Notes |
---|---|---|---|
applicant_id | string | The applicant_id to associate the live photo to. | |
file | \SplFileObject | The file to be uploaded. | |
advanced_validation | bool | Validates that the live photo contains exactly one face. | [optional] |