Please let me know how to use SendGrid Email Validation API in Gravity Forms, using gform_field_validation
filter?
Gravity Forms filter example:
add_filter( 'gform_field_validation', function ( $result, $value, $form, $field ) {
if ( $field->get_input_type() === 'email' && $result['is_valid'] ) {
// put your code here
}
return $result;
}, 10, 4 );
SendGrid Email Validation API:
/
Gravity Forms gform_field_validation
Filter:
I want this type of result:
{
"result": {
"email": "[email protected]",
"verdict": "Invalid",
"score": 0.00089,
"local": "john.doe",
"host": "gmial",
"suggestion": "gmail",
"checks": {
"domain": {
"has_valid_address_syntax": true,
"has_mx_or_a_record": true,
"is_suspected_disposable_address": false
},
"local_part": {
"is_suspected_role_address": false
},
"additional": {
"has_known_bounces": false,
"has_suspected_bounces": true
}
},
"ip_address": "123.45.67.89"
}
}
Thanks in advance :)