1 | <?php |
||
9 | class ClickatellClient |
||
10 | { |
||
11 | const SUCCESSFUL_SEND = 0; |
||
12 | const AUTH_FAILED = 1; |
||
13 | const INVALID_DEST_ADDRESS = 105; |
||
14 | const INVALID_API_ID = 108; |
||
15 | const CANNOT_ROUTE_MESSAGE = 114; |
||
16 | const DEST_MOBILE_BLOCKED = 121; |
||
17 | const DEST_MOBILE_OPTED_OUT = 122; |
||
18 | const MAX_MT_EXCEEDED = 130; |
||
19 | const NO_CREDIT_LEFT = 301; |
||
20 | const INTERNAL_ERROR = 901; |
||
21 | |||
22 | /** |
||
23 | * @var ClickatellHttp |
||
24 | */ |
||
25 | private $clickatell; |
||
26 | |||
27 | /** |
||
28 | * @param ClickatellHttp $clickatellHttp |
||
29 | */ |
||
30 | 4 | public function __construct(ClickatellHttp $clickatellHttp) |
|
34 | |||
35 | /** |
||
36 | * @param array $to String or Array of numbers |
||
37 | * @param string $message |
||
38 | */ |
||
39 | 1 | public function send(array $to, $message) |
|
47 | |||
48 | /** |
||
49 | * @param array $responses |
||
50 | * @throws CouldNotSendNotification |
||
51 | */ |
||
52 | 1 | protected function handleProviderResponses(array $responses) |
|
65 | |||
66 | /** |
||
67 | * @return array |
||
68 | */ |
||
69 | 1 | public function getFailedQueueCodes() |
|
81 | |||
82 | /** |
||
83 | * @return array |
||
84 | */ |
||
85 | 1 | public function getRetryQueueCodes() |
|
92 | } |
||
93 |