-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.php
More file actions
35 lines (23 loc) · 805 Bytes
/
main.php
File metadata and controls
35 lines (23 loc) · 805 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php
$client = new http\Client;
$request = new http\Client\Request;
/*
HTTPS API Endpoint: https://secure.smslink.ro/sms/gateway/communicate/index.php
HTTP API Endpoint: http://www.smslink.ro/sms/gateway/communicate/index.php
*/
$request->setRequestUrl('https://secure.smslink.ro/sms/gateway/communicate/index.php');
$request->setRequestMethod('GET');
/*
Get your SMSLink / SMS Gateway Connection ID and Password from
https://www.smslink.ro/get-api-key/
*/
$request->setQuery(new http\QueryString(array(
'connection_id' => '... My SMS Gateway Connection ID ...',
'password' => '... My SMS Gateway Password ...',
'to' => '07xyzzzzzz',
'message' => 'My Test Message'
)));
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
?>