GetAnswers

This section describes one of the fraud screening methods used in the development of fraud screening plugins that allow CloudBlue Commerce to integrate with third-party fraud screening systems. For more information, refer to Overview and How to Develop Fraud Screening Plugins.

Method naming convention

%PluginName%_GetAnswers

Purpose

This method is used for CloudBlue Commerce to receive the list of possible plug-in answers for the conditions of a rule. These answers will be listed on the rule condition creation screen as value options for the user to choose from.

Mandatory / optional

This is one of the generic methods implemented optionally. However, this method is not used in validation and eligibility plugins because such plugins do not use fraud screening rules.

Input Parameters

None

Return Parameters

  • answers: an object of the \FraudSDK\Answers type that describes a set of possible plug-in answers for rule conditions.

Relationship with other methods

None

Implementation examples

Example 1. V&E plugin

function VNEDemo_GetAnswers()
{
    return
        \FraudSDK\createAnswers()
        ->addAnswer('successfull');
}

Example 2. Blacklist plugin

function BlacklistDemo_GetAnswers()
{
    $answers = \FraudSDK\createAnswers();

    $answers->addAnswer('amongst blacklisted ZIP codes');

    return $answers;
}
CloudBlue, an Ingram Micro business, uses cookies to improve the usability of our site. By continuing to use this site and/or logging in you are accepting the use of these cookies. For more information, visit our Privacy Policy.