Want to skip the docs? Use the MCP Server
Endpoint availability: Premium and aboveLearn more
{
"data": {
"score": 82,
"rules": [
{
"id": "PF10003",
"description": "Customer IP Address is probably VPN/Proxy/Bot/Hosting/Cloud."
},
{
"id": "PF10004",
"description": "Customer Email Address is probably invalid or spam."
},
{
"id": "PF10001",
"description": "High purchase rate, according to `customer_ip`."
},
{
"id": "PF10002",
"description": "High purchase rate, according to `customer_id`."
},
{
"id": "PF10013",
"description": "Customer device might not be a real device (according to `customer_useragent`)."
},
{
"id": "PF10014",
"description": "Customer device is registered as a high-risk device (according to `customer_useragent`)."
}
],
"rulesChecked": 21,
"rulesDetected": 6,
"custom_rules_applied": {
"total": 0,
"rules": []
}
},
"status": "success",
"executionTime": 5
}
{
"status": "error",
"code": 101,
"type": "invalid_key",
"description": "The API Key is missing or invalid."
}
Payment Fraud Detection
curl --request POST \
--url https://greipapi.com/scoring/payment \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"data": {},
"format": "<string>",
"mode": "<string>",
"userID": "<string>"
}
'import requests
url = "https://greipapi.com/scoring/payment"
payload = {
"data": {},
"format": "<string>",
"mode": "<string>",
"userID": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({data: {}, format: '<string>', mode: '<string>', userID: '<string>'})
};
fetch('https://greipapi.com/scoring/payment', 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://greipapi.com/scoring/payment",
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([
'data' => [
],
'format' => '<string>',
'mode' => '<string>',
'userID' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://greipapi.com/scoring/payment"
payload := strings.NewReader("{\n \"data\": {},\n \"format\": \"<string>\",\n \"mode\": \"<string>\",\n \"userID\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://greipapi.com/scoring/payment")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"data\": {},\n \"format\": \"<string>\",\n \"mode\": \"<string>\",\n \"userID\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://greipapi.com/scoring/payment")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"data\": {},\n \"format\": \"<string>\",\n \"mode\": \"<string>\",\n \"userID\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"score": 82,
"rules": [
{
"id": "PF10003",
"description": "Customer IP Address is probably VPN/Proxy/Bot/Hosting/Cloud."
},
{
"id": "PF10004",
"description": "Customer Email Address is probably invalid or spam."
},
{
"id": "PF10001",
"description": "High purchase rate, according to `customer_ip`."
},
{
"id": "PF10002",
"description": "High purchase rate, according to `customer_id`."
},
{
"id": "PF10013",
"description": "Customer device might not be a real device (according to `customer_useragent`)."
},
{
"id": "PF10014",
"description": "Customer device is registered as a high-risk device (according to `customer_useragent`)."
}
],
"rulesChecked": 21,
"rulesDetected": 6,
"custom_rules_applied": {
"total": 0,
"rules": []
}
},
"status": "success",
"executionTime": 5
}
{
"status": "error",
"code": 101,
"type": "invalid_key",
"description": "The API Key is missing or invalid."
}
Risk Scoring
Payment Fraud Detection
Prevent financial losses and protect your business by deploying AI-powered modules that analyze transaction patterns in real-time.
This method helps identify and block suspicious activities, mitigating the risk of fraudulent payments and ensuring a secure experience for both you and your customers.
Want to skip the docs? Use the MCP Server
Endpoint availability: Premium and aboveLearn more
{
"data": {
"score": 82,
"rules": [
{
"id": "PF10003",
"description": "Customer IP Address is probably VPN/Proxy/Bot/Hosting/Cloud."
},
{
"id": "PF10004",
"description": "Customer Email Address is probably invalid or spam."
},
{
"id": "PF10001",
"description": "High purchase rate, according to `customer_ip`."
},
{
"id": "PF10002",
"description": "High purchase rate, according to `customer_id`."
},
{
"id": "PF10013",
"description": "Customer device might not be a real device (according to `customer_useragent`)."
},
{
"id": "PF10014",
"description": "Customer device is registered as a high-risk device (according to `customer_useragent`)."
}
],
"rulesChecked": 21,
"rulesDetected": 6,
"custom_rules_applied": {
"total": 0,
"rules": []
}
},
"status": "success",
"executionTime": 5
}
{
"status": "error",
"code": 101,
"type": "invalid_key",
"description": "The API Key is missing or invalid."
}
POST
/
scoring
/
payment
Payment Fraud Detection
curl --request POST \
--url https://greipapi.com/scoring/payment \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"data": {},
"format": "<string>",
"mode": "<string>",
"userID": "<string>"
}
'import requests
url = "https://greipapi.com/scoring/payment"
payload = {
"data": {},
"format": "<string>",
"mode": "<string>",
"userID": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({data: {}, format: '<string>', mode: '<string>', userID: '<string>'})
};
fetch('https://greipapi.com/scoring/payment', 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://greipapi.com/scoring/payment",
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([
'data' => [
],
'format' => '<string>',
'mode' => '<string>',
'userID' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://greipapi.com/scoring/payment"
payload := strings.NewReader("{\n \"data\": {},\n \"format\": \"<string>\",\n \"mode\": \"<string>\",\n \"userID\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://greipapi.com/scoring/payment")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"data\": {},\n \"format\": \"<string>\",\n \"mode\": \"<string>\",\n \"userID\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://greipapi.com/scoring/payment")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"data\": {},\n \"format\": \"<string>\",\n \"mode\": \"<string>\",\n \"userID\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"score": 82,
"rules": [
{
"id": "PF10003",
"description": "Customer IP Address is probably VPN/Proxy/Bot/Hosting/Cloud."
},
{
"id": "PF10004",
"description": "Customer Email Address is probably invalid or spam."
},
{
"id": "PF10001",
"description": "High purchase rate, according to `customer_ip`."
},
{
"id": "PF10002",
"description": "High purchase rate, according to `customer_id`."
},
{
"id": "PF10013",
"description": "Customer device might not be a real device (according to `customer_useragent`)."
},
{
"id": "PF10014",
"description": "Customer device is registered as a high-risk device (according to `customer_useragent`)."
}
],
"rulesChecked": 21,
"rulesDetected": 6,
"custom_rules_applied": {
"total": 0,
"rules": []
}
},
"status": "success",
"executionTime": 5
}
{
"status": "error",
"code": 101,
"type": "invalid_key",
"description": "The API Key is missing or invalid."
}
Overview
Detecting and preventing fraudulent payments is a critical task for any business that accepts online payments. This AI-based module is designed to help you do that by analysing a range of data points related to each transaction. Using sophisticated machine learning algorithms, this method can detect and flag potentially fraudulent transactions by analysing user data, user behaviour, user device, and other factors. For example, if a transaction appears to be coming from an unusual location or device, or if the userâs behaviour is inconsistent with their past transactions, this method can flag the transaction for further review or rejection. One of the key advantages of this AI-based module is its ability to adapt and learn over time. As it analyses more data and detects more fraud, it can improve its accuracy and efficiency, making it a highly effective tool for preventing financial losses due to fraud. By implementing this method in your payment processing system, you can help protect your business and your customers from fraudulent activity, while providing a seamless and secure payment experience.âECOMMERCE LOSSES TO ONLINE PAYMENT FRAUD TO EXCEED $48 BILLION GLOBALLY
IN 2023, AS FRAUD INCURSIONS EVOLVEâ, according to a recent report by Juniper
Research.
Integration Workflow

Greip Payment Fraud Module - Workflow
Body Parameters
object
required
Hide properties
Hide properties
string
The action your customer try to implement.Accepts:
purchase, deposit, or withdrawal.string
The domain name of the website the customer trying to purchase from.Sample value:
domain.comstring
The name of the website the customer trying to purchase from.Sample value:
Nike Store, Californiastring|integer
If your a service provider with âsub-websitesâ (like Shopify), then provide a unique identification code indicating the website the customer trying to purchase from.Sample values:
12330098, 01as-aowq-029jd, or abcdefg.string|integer|number
The identification code of the shipment.
string|integer|number
The identification code of the transaction in your system.
string|number|float
The total amount of the transaction.
string
The currency in which the customer pay with.Sample value:
GBPstring|integer|number
boolean
Set this to true if the customer is purchasing a digital product.
string
The promo code used by the customer to complete the checkout.
string|integer
The identification number of the customer in your system.
string
The first name of the customer.
string
The last name of the customer (Family Name).
string
The Place of Birth of the customer.
string
The IP address of the customer.
string
The
ISO 3166-1 alpha-2 code format of the country where the customer live. Learn morestring
The name of the region where the customer live.
string
The name of the city where the customer live.
string|integer|number
The name of the zip code of customer location.
string
The âaddress line 1â of the customer.
string
The âaddress line 2â of the customer.
integer|float
The customer latitude on the map (GPS Coordinates).
integer|float
The customer longitude on the map (GPS Coordinates).
string|integer|number
The device identification code of the customer.
string|integer|number
The phone number of the customer (international format).
integer
The registration date of the customer (UNIX Timestamp).
string|integer|float
If you offer a Wallet feature in your website, then pass the user balance to this pararmeter.
string
The customerâs date of birth.Sample value: â1985-12-27`
string
The email address of the customer.
boolean
Set this to true if the customer has 2FA enabled in his/her account.
string
Pass the User Agent of the customer to this parameter.
string
The shipping country code of the customer (in
ISO 3166-1 alpha-2 format).string
The shipping region name of the customer.
string
The shipping city name of the customer.
string|number|integer
The zip code of the customerâs shipping address.
string
The shipping âaddress 1â of the customer.
string
The shipping âaddress 2â of the customer.
integer|number|float
The latitude of the customerâs shipping address (GPS Coordinates).
integer|number|float
The longitude of the customerâs shipping address (GPS Coordinates).
string
The billing country code of the customer (in
ISO 3166-1 alpha-2 format).string
The billing region name of the customer.
string
The billing city name of the customer.
string|number|integer
The zip code of the customerâs billing address.
string
The billing âaddress 1â of the customer.
string
The billing âaddress 2â of the customer.
integer|float
The latitude of the customerâs billing address (GPS Coordinates).
integer|float
The longitude of the customerâs billing address (GPS Coordinates).
string
The payment method used to complete this transaction.Accepted values:
cards, cards_mada, applepay, stcpay, bank, crypto, wallet, or cod.string
The name on the card (Cardholder Name).
string|number|integer
The card number (min: 6 digits).
string
The expiry date of the customer debit/credit card.Sample value: 29/05
boolean
Set this to true if the customer passed the CVV/CSV verification process.
string
default:"JSON"
The format command is used to get a response in a specific format.Expected values:
JSON, XML, CSV, or NewlineFor more information please refer to Response Format.string
default:"live"
The mode command is used to in the development stage to simulate the integration process before releasing it to the production environment.Expected values:
live, or test.For more information please refer to Development Environment.string
The userID command can be used to identify requests sent by specific users to monitor in the Events Page.Expected values: email address, phone number, user id, name, etc.For more information please refer to User Identifier.
Response properties
object
required
Hide properties
Hide properties
float
A risk-score from 0 to 100 indicating how risky this transaction is
(
10.5 means itâs 10.5% risky to pass this transaction).array
required
integer
required
Total rules checked against the transaction.
integer
required
Total rules detected in the transaction.
object
The custom rules applied to this request, learn
more.
Hide properties
Hide properties
integer
required
The total number of custom rules applied to this request.
object
required
The custom rules applied to this request, learn
more.
string
required
The response status.Expected values:
success, or error.integer
required
Time spent in milliseconds to process the data.
Possible Rules
| Id | Description |
|---|---|
| PF1001 | High purchase rate, according to customer_ip. |
| PF1002 | High purchase rate, according to customer_id. |
| PF1003 | Customer IP Address is probably VPN/Proxy/Bot/Hosting/Cloud. |
| PF1004 | Customer Email Address is probably invalid, disposable or spam. |
| PF1005 | Customer Phone Number is probably invalid or spam. |
| PF1006 | Customer Latitude/Longitude is invalid. |
| PF1007 | Customer card number (BIN/IIN) is invalid. |
| PF1008 | Customer debit/credit card issued by a brand different from the one exist in payment_type parameter. |
| PF1009 | Customer country is a high-fraud country. |
| PF1010 | Customer debit/credit card issued in a high-risk country. |
| PF1011 | Customer is purchasing multiple times from multiple locations within the past 30 days. |
| PF1012 | Customer debit/credit card is being used multiple times from multiple customer accounts (according to customer_id and card_number). |
| PF1013 | Customer device might not be a real device (according to customer_useragent). |
| PF1014 | Customer device is registered as a high-risk device (according to customer_useragent). |
| PF1015 | AI flagged the transaction as potentially fraudulent. |
| PF1016 | AI flagged the transaction as potentially fraudulent due to high transaction amount. |
| PF1017 | Mismatch between billing address and IP geolocation. |
| PF1018 | Customer has multiple fraudulent transactions in the past 30 days. |
| PF1019 | Unusual purchase amount compared to customerâs history. |
| PF1020 | Transaction initiated from a newly created account. |
| PF10021 | Multiple payment cards used by a single account within a short timeframe. |
| PF10022 | Customer IP address were found in one of your blacklists. |
| PF10023 | Customer email address were found in one of your blacklists. |
| PF10024 | Customer phone number were found in one of your blacklists. |
| PF10025 | Customer card number were found in one of your blacklists. |
| PF10026 | Customer Id were found in one of your blacklists. |
Was this page helpful?
âI