Skip to main content
Version: 1.0

Responses

Every API response is accompanied by a response body, the format of which depends on the type of endpoint you have used.

Types of Responses​

When issuing a HTTP request to the Fraudio API, you may encounter the following types of responses:

  • Successful responses: Any response in the 2xx range indicates a successful transaction.
  • Redirects: You should never expect to see any response in the 3xx range from our APIs. These are only used to forward regular HTTP requests to HTTPS.
  • Functional errors: Any response in the 4xx range indicates an intentional error from the API, such as an invalid token or an incorrectly formatted request body.
  • Programming errors: Any response with a status code of 500 or 501 indicates an unintentional error from the API, such as a bug in the code.
  • Network errors: Any response with a status code of 502, 503, or 504 indicates that the network layer, or the API itself, could not be reached, possibly due to a cloud outage.
  • Timeouts: When no response is received by the client, it is classified as a timeout.

Please check the full list of HTTP status codes for more details.

200 OK - Fraud score response​

The request message to the Fraud Score endpoint has been successfully processed. You will receive a 200 OK response.

200 OK response example
{
"Score": "0.54",
"Transaction_ID": "0f48djmm",
"Recommendation": "yellow",
"Notes": "Default values were used for the following missing fields: Important fields: acceptorip, eci, recurring. Optional fields: acceptorpostalcode, avsused."
}

Properties​

NameTypeRequiredDescription
ScorestringtrueThe Score is a fraud score between 0 and 1, where the closer to 1, the higher the likelihood that the transaction is fraudulent. The value -1 may be served during onboarding.
Transaction_IDstringtrueThe Transaction_ID is an echo of the transaction ID provided by you. If you have any questions about a certain transaction we recommend providing the corresponding Transaction_ID.
RecommendationstringtrueThe Recommendation is an advised course of action. The recommendations will be either Red, Yellow, Green, or Unavailable. Recommendations are generated by starting with the default thresholds, and then optimising the model using your customised preferences that you specify during onboarding. The value 'Unavailable' may be served during onboarding.
NotesstringtrueThe Notes consist of relevant information about the transaction that was sent.

200 OK - Post-auth backfill​

The request message to the Post-auth backfill endpoint has been successfully processed. You will receive a 200 OK response.

200 OK - Data collection response​

The request message to the endpoint has been successfully processed. You will receive a 200 OK response.

The following endpoints are designed only for data collection:

  • chargebacks
  • merchant account information
  • inter-account transfers
  • account bank transfers
  • merchant evaluations
Data collection response example
{
"created": 2,
"deleted": 0,
"errors": 2,
"ignored": 5,
"received": 0,
"updated": 0
}

Properties​

NameTypeRequiredDescription
createdintegerfalsehow many entities have been created
deletedintegerfalsehow many entities have been deleted
errors[string]falselist of errors that happened during the operation
ignoredintegerfalsehow many entities have been ignored (usually because they already exist)
receivedintegerfalsehow many entities have been received
updatedintegerfalsehow many entities have been updated

Problem response​

If the HTTP response code is not 200 OK, it indicates that there is a problem. We use RFC7807-compliant error messages to provide you with details of the problem.

Problem response example
{
"type": "about:blank",
"title": "Service Unavailable",
"status": 503,
"detail": "Connection to database timed out",
"instance": "http://example.com"
}

Properties​

NameTypeRequiredDescription
typestring(uri)falseA relative URI reference that uniquely identifies the problem type only in the context of the provided API. Opposed to the specification in RFC-7807, it is neither recommended to be dereferencable and point to a human-readable documentation nor globally unique for the problem type.
titlestringfalseA short summary of the problem type. Written in English and readable for engineers; usually not suited for non-technical stakeholders, and not localized.
statusinteger(int32)falseThe HTTP status code generated by the origin server for this specific occurrence of the problem.
detailstringfalseA human-readable explanation specific to this occurrence of the problem that is helpful to locate the problem and give advice on how to proceed. Written in English and readable for engineers, usually not suited for non technical stakeholders and not localized.
instancestring(uri)falseA relative URI reference that identifies the specific occurrence of the problem. It may be used to locate the root of the problem in the source code, for example, by adding a fragment identifier or sub-path to the problem type.