Download the PHP package ovh/php-ovh-sms without Composer
On this page you can find all versions of the php package ovh/php-ovh-sms. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package php-ovh-sms
PHP OVH SMS
Send SMS directly from your code using OVH SMS offer.
Install
To download this SDK and integrate it inside your PHP application, you can use Composer.
Add the repository in your composer.json file or, if you don't already have this file, create it at the root of your project with this content:
Then, you can install OVH SMS APIs SDK and dependencies with:
php composer.phar install
This will install ovh/php-ovh-sms
to ./vendor
, along with other dependencies
including autoload.php
.
Configure
To use this SDK, you'll need API credentials. API credentials allows you to log in and manage OVH products without ever storing your password.
Even better, the credentials can be configured to only allow access on some specific features. In this case, we only want the script to access the SMS features.
To generate credentials to access all the SMS features, you can simply visit https://api.ovh.com/createToken/index.cgi?GET=/sms&GET=/sms/*&PUT=/sms/*&DELETE=/sms/*&POST=/sms/*
And then use the generated credentials in you application.
For more advanced use cases, please consult the php-ovh or python-ovh wrappers.
Send a test message without specifying a sender using php-ovh-sdk
This example will create a new SDK instance, configure it to send a message to a french number without declaring a sender (a random shortcode will be used). It will then use this instance to plan a message in the future using the first account it finds.
To avoid consuming any credit accidentally, it will delete the message before actually sending it.
Send a test message by using a beforehand declared sender
This example will create a new SDK instance, configure it to send a message. It will then use this instance to plan a message in the future using the first account it finds and the first sender it finds in the account as the message sender.
To avoid consuming any credit accidentally, it will delete the message before actually sending it.
Hacking
Get the code:
Submit your changes:
And visit Github to submit your change! https://github.com/ovh/php-ovh-sms/pulls
Related links
- Order SMS credit: https://www.ovhtelecom.fr/sms/
- Get API credentials: https://api.ovh.com/createToken/index.cgi
- Contribute: https://github.com/ovh/php-ovh-sms
- Report bugs: https://github.com/ovh/php-ovh-sms/issues
- Official OVH PHP wrapper: https://github.com/ovh/php-ovh