require_once 'vendor/autoload.php';
use TwilioRestClient;
$sid = "ACe39b1abc88826a6a4b571e0d0c829d25";
$token = "579fd6e6fdb99ccdbd4db57d54e23ad6";
$twilio = new Client($sid, $token);
$verification_check = $twilio->verify->v2->services("VA60737f4811c8c00f6a9a5297962c2b3f")
->verificationChecks
->create([
"to" => "+911234567890",
"code" => "888577"
]
);
print($verification_check);
print($verification_check->status);
the same code prints the whole object on localhost but prints [Twilio.Verify.V2.VerificationCheckInstance] like this on live worpress server . but I can access the properties like print($verification_check->status); on both local and live . Another point to mention I downloaded the twillo from composer on localhost and uploaded the directory to wordpress theme folder