Question

RingCentral Terminating PubNub SMS Subscription (PHP)

  • 9 October 2020
  • 1 reply
  • 304 views

I tried and failed to find manual on RC PHP SDK. In my application I need to create pubnub subscription, send SMS and wait for the answer for 3 seconds, then terminate the subscription whether answer is received or not...

I tried

$subscription->setKeepPolling(false);

and

$subscription->remove();

but they all result in throwing an error. Is there a peaceful way to do this? And how can I create subscription for a limited period of time?


Thanks


1 reply

Userlevel 1

Are you seeing this error?

"Uncaught Error: Cannot use object of type PubNubModelsConsumerPubSubPNMessageResult as array"

If so, update your RingCentral PHP SSDK to get the latest version.

$ php composer.phar require ringcentral/ringcentral-php

If it was not this error, print out the error and share it here.

Reply