Download the PHP package devstrefa/esemeser without Composer
On this page you can find all versions of the php package devstrefa/esemeser. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download devstrefa/esemeser
More information about devstrefa/esemeser
Files in devstrefa/esemeser
Package esemeser
Short Description PHP Library for sending SMS through esemeser.pl API
License MIT
Homepage https://github.com/DevStrefa/esemeser
Informations about the package esemeser
Esemeser 1.1.0
PHP Library designed to sending SMS messages through esemeser.pl API
Before you use it!
Esemeser.pl is a Polish service for sending SMS messages, so remember that You can send messages only to Polish phone numbers those numbers must be in format: xxxxxxxxx (9 digits), other numbers probably will not work.
This library is using file_get_contents as default mechanism to send requests, so before You start using it, make sure you have properly configured environment. Check if your allow_url_fopen is set to "1". You can use CURL instead of file_get_contents please read below to get more information.
How to install
Library is compatible with composer so You can install it by adding:
to Your composer.json file
You can also download zip file and include all necessary files by yourself
How to use
Library is designed for 2 main tasks:
1. Sending Messages
Below you can see example of code sending some message:
2. Checking Balance
Second function of library is checking how many messages of given type You can still send with Your current balance. To do this use library like in code below:
How to use CURL instead of file_get_contents
Since version 1.1.0 of library, You can choose mechanism which is used to make requests to API, if you want to do this add this line to Your code:
available values for setRequestMethod are:
- fgc - for file_get_contents
- curl - for curl library
For more information about library please read generated documentation.
Changelog
You can see Changelog for this project here
License
Whole code in this repository is Under MIT license