An introduction to Forter's API Documentation
API Reference
Forter's APIs can be leveraged for a variety of use cases throughout the user journey. The API reference documentation includes synchronous API endpoints for real-time decisions as well as supplementary APIs used to provide Forter with subsequent status updates after Forter has provided a binary decision and/or recommendation.
The Forter API differs for every merchant account as we release new versions and tailor functionality and each merchants available data. To view your specific API schema and data requirements, log into your Forter portal account.
Path
Please send all API requests to a dedicated path for your account, by appending your Site ID to the beginning of the URL.
https://{site-id}.api.forter-secure.com/{endpoint}
Authentication
All requests to Forter’s APIs must be made over HTTPS. In order to authenticate, include both the Site ID and API Key, which can be found in Credentials, in the request headers. Forter uses Basic Authentication credentials in the form of a username and password, where the API key is the username and the password is empty.
Note that your Site ID and API Key are different for your Forter test site and production site.
curl -X POST "https://{site-id}.api.forter-secure.com/{endpoint}"
-u "{api-key}:"
-H "api-version: 10.1"
-H "content-type: application/json"
-H "x-forter-siteid: {site-id}"
-d @filepost.data
Headers
Code | Status |
---|---|
| String Required |
| String Required |
| String Required |
| String Required |
| String |
| Boolean |
HTTP Codes
Forter uses conventional HTTP response codes to indicate the success or failure of an API request. In general, codes in the 2xx range indicate success, codes in the 4xx range indicate an error that resulted from the provided information, while codes in the 5xx range indicate an error with Forter's servers.
Code | Status |
---|---|
| OK |
| Bad Request |
| Unauthorized |
| Not Found |
| Too Many Requests |
| Internal Server Error |
Timeouts
In order to prevent connection failovers due to internet network failures on the way, please limit the HTTP requests timeout to 2 seconds.
Retries
In the event of exceptions from our API we advise merchants to retry once and afterward to capture the money and resend the transaction to Forter at a later stage.
Load Testing
Your test site is limited to 10 RPS. Requests beyond this limit will result in a 429
error code. You can exceed this rate limit by including the header x-forter-disable-persistence = true
in your load test requests. Requests made with this header will not be visible in Forter’s decision dashboard, so you should not include this header in real production requests.
TLS Session Reuse
For low-latency applications, every millisecond counts. One common source of unnecessary latency is the repeated TLS handshake process when making API requests. If your application does not reuse TLS sessions, it incurs extra latency and computational overhead for every new connection. To mitigate this, we strongly recommend implementing TLS session reuse and connection pooling.
Response Handling
API requests made with your test Site ID will return a randomized decision. In order to test your response handling, you can trigger a specific decision or recommendation by using a specific email address as the customer’s email, a specific credit card number as the payment method, and/or a specific IP address.
Fraud Management
Customer Email | Order v3 Response |
---|---|
[email protected] | "forterDecision": "APPROVE" |
[email protected] | "forterDecision": "DECLINE" |
[email protected] | "forterDecision": "NOT_REVIEWED" |
3DS Recommendation
Customer Email | Order v3 Response |
---|---|
[email protected] | "forterDecision": "DECLINE", "recommendation": "VERIFICATION_REQUIRED_3DS_CHALLENGE" |
[email protected] | "forterDecision": "DECLINE", "recommendation": "VERIFICATION_REQUIRED_3DS_CHALLENGE" |
[email protected] | "forterDecision": "APPROVE", "recommendation": "REQUEST_SCA_EXEMPTION_TRA" |
[email protected] | "forterDecision": "APPROVE", "recommendation": "REQUEST_SCA_EXEMPTION_LOW_VALUE" |
[email protected] | "forterDecision": "APPROVE", "recommendation": "REQUEST_SCA_EXEMPTION_CORP" |
[email protected] | "forterDecision": "APPROVE", "recommendation": "REQUEST_SCA_EXEMPTION_TRUSTED_BENEFICIARY" |
[email protected] | "forterDecision": "APPROVE", "recommendation": "REQUEST_SCA_EXCLUSION_ONE_LEG_OUT" |
[email protected] | "forterDecision": "APPROVE", "recommendation": "REQUEST_SCA_EXCLUSION_MOTO" |
[email protected] | "forterDecision": "APPROVE", "recommendation": "REQUEST_SCA_EXCLUSION_ANONYMOUS" |
3DS Execution
No challenge required
Credit Card | 3DS Result Response |
---|---|
5222220000000005 | "forterDecision": "APPROVE", "verificationMethod": { "status": "FRICTIONLESS" } |
4111110000001142 | "forterDecision": "APPROVE", "verificationMethod": { "status": "ATTEMPTED" } |
4000000000001992 | "forterDecision": "DECLINE", "verificationMethod": { "status": "FRICTIONLESS_NOT_AUTHENTICATED" } |
5200000000000031 | "forterDecision": "DECLINE", "verificationMethod": { "status": "FRICTIONLESS_BANK_REJECT" } |
5200000000001336 | "forterDecision": "DECLINE", "verificationMethod": { "status": "FRICTIONLESS_TECHNICAL_ISSUE" } |
Challenge executed
Credit Card | 3DS Result Response |
---|---|
5111220000000009 Use code 1234 in the challenge window |
|
5200000000004447 Use code 1234 in the challenge window |
|
5111220000000009 Use code 4567 in the challenge window |
|
5200000000002227 Use code 1234 in the challenge window |
|
5200000000003332 Use code 1234 in the challenge window |
|
Identities
Customer Email | Signup, Login, Profile Access Response |
---|---|
[email protected] | "forterDecision": "APPROVE" |
[email protected] | "forterDecision": "DECLINE" |
[email protected] | "forterDecision": "NOT_REVIEWED" |
[email protected] | "forterDecision": "VERIFICATION_REQUIRED", "recommendation": "EMAIL_VERIFICATION" |
[email protected] | "forterDecision": "VERIFICATION_REQUIRED", "recommendation": "SMS_VERIFICATION" |
IP Address | Signup, Login, Profile Access Response |
---|---|
0.0.0.1 | "forterDecision": "APPROVE" |
0.0.0.2 | "forterDecision": "DECLINE" |
0.0.0.3 | "forterDecision": "NOT_REVIEWED" |
0.0.0.4 | "forterDecision": "VERIFICATION_REQUIRED", "recommendation": "EMAIL_VERIFICATION" |
0.0.0.5 | "forterDecision": "VERIFICATION_REQUIRED", "recommendation": "SMS_VERIFICATION" |