Authorization
Basic Auth authorization is required to connect to FraudAI. The Basic Auth authorization can be found directly in the Betraud customer panel or you can ask us via [email protected].
Token Creation
To create the authorization token you will need to base64 encode the username and password.
To do this, we leave you some code examples to get the token in Base64.
<?php
$username = 'YOUR_USERNAME'; // Set your username
$password = 'YOUR_PASSWORD'; // Set your password
$token = base64_encode("$username:$password");
// Use $token in the API call as Authorization
echo $token;
?>import base64
username = 'YOUR_USERNAME' # Set your username
password = 'YOUR_PASSWORD' # Set your password
token = base64.b64encode(f'{username}:{password}'.encode()).decode()
# Use the token in the API call as Authorization
print(token)const btoa = require('btoa');
const username = 'YOUR_USERNAME'; // Set your username
const password = 'YOUR_PASSWORD'; // Set your password
const token = btoa(`${username}:${password}`);
// Use the token in the API call as Authorization
console.log(token);Check Auth Validation
GET /check-auth
Check if the Token is valid and can be used.
Headers
Name
Value
Content-Type
application/json
Authorization
Basic <token>
Body
No Body to send.
Response
Last updated