Steps
Confirming a user's identity with Authenteq Web IDV is fairly simple. You can integrate our solution into your system with three basic steps.
1) Get your Client Details
Once you sign up , we will create a client account for your system. You will get from us:
Client ID
- your client identifier.
Client Secret
- your secret key.
You need them to authorize your requests.
Use the Customer Dashboard to set:
Redirect URL
- a URL that your user is redirected to on successful identity verification.
You can specify multiple redirect URLs in case you have multiple deployment environments and should provide one of them on request the identity verification session and the result details retrieval.
You may use parameters in your redirect URL like ?id=14567678&email=user@business.com
. Please avoid use of thecode
one, as before redirect we add it with the granted code in its value.
2) Create the "Sign Up with Authenteq" Button
To initialize the identity process, request the verification session by performing a GET request to:
https://api.app.authenteq.com/web-idv/verification-url?redirectUrl=<redirectUrl>
Where <redirectUrl>
should be replaced with one of your redirect URLs corresponding to your current deployment environment.
To authorize the request, combine your client ID and secret with a colon separator, encode in base64 and add to the Authorization
header like so:
Copy Authorization: Basic base64(<clientId>:<clientSecret>)
To issue request, you can use one of the snippets in your target language, just replace <client_id>
, <client_secret>
and <redirect_url>
with proper values:
Python Java JavaScript PHP Go Ruby C#
Copy import requests
url = 'https://api.app.authenteq.com/web-idv/verification-url?redirectUrl=<redirect_url>'
headers = {
'Content-Type' : 'application/x-www-form-urlencoded' ,
}
auth = requests . auth . HTTPBasicAuth ( '<client_id>' , '<client_secret>' )
response = requests . request ( 'GET' , url, headers = headers, auth = auth)
print (response.text. encode ( 'utf8' ))
Copy import okhttp3 . OkHttpClient ;
import okhttp3 . Request ;
import okhttp3 . Response ;
import okhttp3 . Credentials ;
OkHttpClient client = new OkHttpClient() . newBuilder () . build ();
String credential = Credentials . basic ( "<client_id>" , "<client_secret>" );
Request request = new Request . Builder ()
. url ( "https://api.app.authenteq.com/web-idv/verification-url?redirectUrl=<redirect_url>" )
. method ( "GET" , null )
. addHeader ( "Content-Type" , "application/x-www-form-urlencoded" )
. addHeader ( "Authorization" , credential)
. build ();
Response response = client . newCall (request) . execute ();
Copy var axios = require ( 'axios' );
var config = {
method : 'get' ,
url : 'https://api.app.authenteq.com/web-idv/verification-url?redirectUrl=<redirect_url>' ,
headers : {
'Content-Type' : 'application/x-www-form-urlencoded' ,
} ,
auth : {
username : '<client_id>' ,
password : '<client_secret>' ,
}
};
axios (config)
.then ( function (response) {
console .log ( JSON .stringify ( response .data));
})
.catch ( function (error) {
console .log (error);
});
Copy <? php
$curl = curl_init () ;
curl_setopt_array ( $curl , array(
CURLOPT_URL => "https://api.app.authenteq.com/web-idv/verification-url?redirectUrl=<redirect_url>" ,
CURLOPT_RETURNTRANSFER => true ,
CURLOPT_ENCODING => "" ,
CURLOPT_MAXREDIRS => 10 ,
CURLOPT_TIMEOUT => 0 ,
CURLOPT_FOLLOWLOCATION => true ,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1 ,
CURLOPT_CUSTOMREQUEST => "GET" ,
CURLOPT_USERPWD => "<client_id>:<client_secret>" ,
CURLOPT_HTTPHEADER => array(
"Content-Type: application/x-www-form-urlencoded"
) ,
) ) ;
$response = curl_exec ( $curl ) ;
curl_close ( $curl ) ;
echo $response;
Copy package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main () {
url := "https://api.app.authenteq.com/web-idv/verification-url?redirectUrl=<redirect_url>"
method := "GET"
payload := strings. NewReader ( "" )
client := & http.Client {
}
req, err := http. NewRequest (method, url, payload)
if err != nil {
fmt. Println (err)
}
req.Header. Add ( "Content-Type" , "application/x-www-form-urlencoded" )
req.Header. Add ( "Authorization" , "Basic " + basicAuth ( "<client_id>" , "<client_secret" ))
res, err := client. Do (req)
defer res.Body. Close ()
body, err := ioutil. ReadAll (res.Body)
fmt. Println ( string (body))
}
Copy require "uri"
require "net/http"
url = URI ( "https://api.app.authenteq.com/web-idv/verification-url?redirectUrl=<redirect_url>" )
https = Net :: HTTP . new (url . host , url . port)
https . use_ssl = true
request = Net :: HTTP :: Get . new (url)
request . basic_auth( "<client_id>" , "<client_password>" )
request[ "Content-Type" ] = "application/x-www-form-urlencoded"
response = https . request(request)
puts response . read_body
Copy using System ;
using RestSharp . Authenticators ;
using RestSharp ;
var client = new RestClient ( "https://api.app.authenteq.com/web-idv/verification-url?redirectUrl=<redirect_url>" );
client . Authenticator = new HttpBasicAuthenticator ( "<client_id>" , "<client_secret>" );
client . Timeout = - 1 ;
var request = new RestRequest ( Method . GET );
request . AddHeader ( "Content-Type" , "application/x-www-form-urlencoded" );
IRestResponse response = client . Execute (request);
Console . WriteLine ( response . Content );
In response you will receive a verification URL that leads to Authenteq Identity Server. By following the URL, the user will begin the identity process:
identity verification - where we verify that the person who performed the liveness test is the document holder.
To inform the user that their identity will be verified using an external service you could use our button:
Here are the HTML and CSS for the button:
Please use this file to display our logo:
3) Get Verification Result Details
When the identify verification process is complete, we will redirect the user to the redirect URL and add the code
parameter that you will use to retrieve the verification result details.
If the user interrupts or fails the verification the code
will not be present on the redirect URL. The endpoint you provide as the redirect URL must handle that case. If the code
is missing we recommend redirecting the user to the beginning of the flow.
To get the verification result details, perform a GET request to:
https://api.app.authenteq.com/web-idv/verification-result?redirectUrl=<redirectUrl>&code=<code>
Where <redirectUrl>
should be replaced with the same URL you used to request the verification session and <code>
with one you got on redirect earlier.
To authorize the request, combine your client ID and secret with a colon separator, encode in base64 and add to the Authorization
header like so:
Copy Authorization: Basic base64(<clientId>:<clientSecret>)
The endpoint will return the user details:
To retrieve details you can use one of the snippets we prepared for you, just replace <client_id>
, <client_secret>
, <redirect_url>
and <code>
with proper values:
Python Java JavaScript PHP Go Ruby C#
Copy import requests
url = "https://api.app.authenteq.com/web-idv/verification-result?code=<code>&redirectUrl=<redirect_url>"
auth = requests . auth . HTTPBasicAuth ( '<client_id>' , '<client_secret>' )
response = requests . request ( 'GET' , url, auth = auth)
print (response.text. encode ( 'utf8' ))
Copy import okhttp3 . OkHttpClient ;
import okhttp3 . Request ;
import okhttp3 . Response ;
import okhttp3 . Credentials ;
OkHttpClient client = new OkHttpClient() . newBuilder () . build ();
String credential = Credentials . basic ( "<client_id>" , "<client_secret>" );
Request request = new Request . Builder ()
. url ( "https://api.app.authenteq.com/web-idv/verification-result?code=<code>&redirectUrl=<redirect_url>" )
. method ( "GET" , null )
. addHeader ( "Authorization" , credential)
. build ();
Response response = client . newCall (request) . execute ();
Copy var axios = require ( 'axios' );
var config = {
method : 'get' ,
url : 'https://api.app.authenteq.com/web-idv/verification-result?code=<code>&redirectUrl=<redirect_url>' ,
auth : {
username : '<client_id>' ,
password : '<client_secret>' ,
}
};
axios (config)
.then ( function (response) {
console .log ( JSON .stringify ( response .data));
})
.catch ( function (error) {
console .log (error);
});
Copy <? php
$curl = curl_init () ;
curl_setopt_array ( $curl , array(
CURLOPT_URL => "https://api.app.authenteq.com/web-idv/verification-result?code=<code>&redirectUrl=<redirect_url>" ,
CURLOPT_RETURNTRANSFER => true ,
CURLOPT_ENCODING => "" ,
CURLOPT_MAXREDIRS => 10 ,
CURLOPT_TIMEOUT => 0 ,
CURLOPT_FOLLOWLOCATION => true ,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1 ,
CURLOPT_CUSTOMREQUEST => "GET" ,
CURLOPT_USERPWD => "<client_id>:<client_secret>" ,
) ) ;
$response = curl_exec ( $curl ) ;
curl_close ( $curl ) ;
echo $response;
Copy package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main () {
url := "https://api.app.authenteq.com/web-idv/verification-result?code=<code>&redirectUrl=<redirect_url>"
method := "GET"
client := & http.Client {
}
req, err := http. NewRequest (method, url, nil )
req. SetBasicAuth ( "<client_id>" , "<client_secret>" )
if err != nil {
fmt. Println (err)
}
res, err := client. Do (req)
defer res.Body. Close ()
body, err := ioutil. ReadAll (res.Body)
fmt. Println ( string (body))
}
Copy require "uri"
require "net/http"
url = URI ( "https://api.app.authenteq.com/web-idv/verification-result?code=<code>&redirectUrl=<redirect_url>" )
https = Net :: HTTP . new (url . host , url . port) ;
https . use_ssl = true
request = Net :: HTTP :: Get . new (url)
request . basic_auth( "<client_id>" , "<client_password>" )
request[ "Authorization" ] = "Basic bzdNNzFuWlY2a0ZFUHdpaWd4TXk6MURmSTh2bzBJVEFYcFYxRDJyN3d5WXByNGU5dXJIckgyZmdkT2RNNQ=="
response = https . request(request)
puts response . read_body
Copy var client = new RestClient ( "https://api.app.authenteq.com/web-idv/verification-result?code=<code>&redirectUrl=<redirect_url>" );
client . Authenticator = new HttpBasicAuthenticator ( "<client_id>" , "<client_secret>" )
client . Timeout = - 1 ;
var request = new RestRequest ( Method . GET );
IRestResponse response = client . Execute (request);
Console . WriteLine ( response . Content );
The endpoint will return the user details:
Copy {
"id" : "3631324b-5bcc-48b0-b717-4f12f45e0a1d" ,
"status" : "PASSED" ,
"platform" : "WEB" ,
"startTime" : "2020-04-10T11:44:40Z" ,
"endTime" : "2020-04-10T11:47:23Z" ,
"livenessFaceImage" : {
"contentType" : "image/jpeg" ,
"content" : "bGl2ZW5lc3NGYWNlSW1hZ2UK"
} ,
"documentData" : {
"documentType" : "DL" ,
"documentNumber" : "1234567890" ,
"issuingCountry" : "USA" ,
"jurisdiction" : "UTA" ,
"nationality" : "USA" ,
"surnameAndGivenNames" : "DOE JOHN" ,
"surname" : "DOE" ,
"givenNames" : "JOHN" ,
"nameSuffixes" : "MR" ,
"namePrefixes" : "JR" ,
"sex" : "M" ,
"dateOfBirth" : "1964-12-30" ,
"dateOfExpiry" : "2022-12-30" ,
"dateOfIssue" : "2012-05-30" ,
"address" : "430-985 ELEIFEND^DULUTH WA 92611" ,
"licenseClass" : "B/C/D" ,
"licenseClassDetails" : {
"B" : {
"from" : "2019-01-30" ,
"to" : "2029-01-30" ,
"notes" : "Some valuable note"
} ,
"C" : {
"from" : "2019-01-30" ,
"to" : "2029-01-30"
} ,
"D" : {
"from" : "2019-01-30" ,
"to" : "2029-01-30"
}
} ,
"croppedFrontImage" : {
"contentType" : "image/jpeg" ,
"content" : "Y3JvcHBlZEZyb250SW1hZ2U="
} ,
"croppedBackImage" : {
"contentType" : "image/jpeg" ,
"content" : "Y3JvcHBlZEJhY2tJbWFnZQ=="
} ,
"faceImage" : {
"contentType" : "image/jpeg" ,
"content" : "ZmFjZUltYWdlCg=="
}
} ,
"nfcVerified" : false
}