We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fatal error: Uncaught exception 'GuzzleHttp\Exception\ClientException' with message 'Client error response [url] https://api.ovh.com/1.0/sms/ [status code] 403 [reason phrase] Forbidden' in /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php:89 Stack trace: #0 /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/Subscriber/HttpError.php(33): GuzzleHttp\Exception\RequestException::create(Object(GuzzleHttp\Message\Request), Object(GuzzleHttp\Message\Response)) #1 /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/Event/Emitter.php(108): GuzzleHttp\Subscriber\HttpError->onComplete(Object(GuzzleHttp\Event\CompleteEvent), 'complete') #2 /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/RequestFsm.php(91): GuzzleHttp\Event\Emitter->emit('complete', Object(GuzzleHttp\Event\CompleteEvent)) #3 /var/www/vhosts/formainap.net/subdomains/idiomas/applica in /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php on line 89
The code:
`require $_SERVER['DOCUMENT_ROOT'].'/application/vendor/autoload.php'; use \Ovh\Api;
$endpoint = 'ovh-eu'; $applicationKey = "xxxxx"; $applicationSecret = "xxxxxx"; $consumer_key = "xxxxxxxx";
$conn = new Api( $applicationKey, $applicationSecret, $endpoint, $consumer_key);
$smsServices = $conn->get('/sms/'); foreach ($smsServices as $smsService) {
print_r($smsService);
}
$content = (object) array( "charset"=> "UTF-8", "class"=> "phoneDisplay", "coding"=> "7bit", "message"=> "Ya están disponibles los SMS de OVHcloud en api.ovh.com", "noStopClause"=> false, "priority"=> "high", "receivers"=> [ "+3460000000" ], "senderForResponse"=> true, "validityPeriod"=> 2880 ); $resultPostJob = $conn->post('/sms/'. $smsServices[0] . '/jobs/', $content);
print_r($resultPostJob);
$smsJobs = $conn->get('/sms/'. $smsServices[0] . '/jobs/'); print_r($smsJobs); `
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Fatal error: Uncaught exception 'GuzzleHttp\Exception\ClientException' with message 'Client error response [url] https://api.ovh.com/1.0/sms/ [status code] 403 [reason phrase] Forbidden' in /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php:89 Stack trace: #0 /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/Subscriber/HttpError.php(33): GuzzleHttp\Exception\RequestException::create(Object(GuzzleHttp\Message\Request), Object(GuzzleHttp\Message\Response)) #1 /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/Event/Emitter.php(108): GuzzleHttp\Subscriber\HttpError->onComplete(Object(GuzzleHttp\Event\CompleteEvent), 'complete') #2 /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/RequestFsm.php(91): GuzzleHttp\Event\Emitter->emit('complete', Object(GuzzleHttp\Event\CompleteEvent)) #3 /var/www/vhosts/formainap.net/subdomains/idiomas/applica in /var/www/vhosts/formainap.net/subdomains/idiomas/application/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php on line 89
The code:
`require $_SERVER['DOCUMENT_ROOT'].'/application/vendor/autoload.php';
use \Ovh\Api;
$endpoint = 'ovh-eu';
$applicationKey = "xxxxx";
$applicationSecret = "xxxxxx";
$consumer_key = "xxxxxxxx";
$conn = new Api( $applicationKey,
$applicationSecret,
$endpoint,
$consumer_key);
$smsServices = $conn->get('/sms/');
foreach ($smsServices as $smsService) {
}
$content = (object) array(
"charset"=> "UTF-8",
"class"=> "phoneDisplay",
"coding"=> "7bit",
"message"=> "Ya están disponibles los SMS de OVHcloud en api.ovh.com",
"noStopClause"=> false,
"priority"=> "high",
"receivers"=> [ "+3460000000" ],
"senderForResponse"=> true,
"validityPeriod"=> 2880
);
$resultPostJob = $conn->post('/sms/'. $smsServices[0] . '/jobs/', $content);
print_r($resultPostJob);
$smsJobs = $conn->get('/sms/'. $smsServices[0] . '/jobs/');
print_r($smsJobs);
`
The text was updated successfully, but these errors were encountered: