1 | <?php |
||
21 | class Client extends BaseClient |
||
22 | { |
||
23 | const API_SEND = 'cgi-bin/message/wxopen/template/send'; |
||
24 | |||
25 | /** |
||
26 | * {@inheritdoc}. |
||
27 | */ |
||
28 | protected $message = [ |
||
29 | 'touser' => '', |
||
30 | 'template_id' => '', |
||
31 | 'page' => '', |
||
32 | 'form_id' => '', |
||
33 | 'data' => [], |
||
34 | 'emphasis_keyword' => '', |
||
35 | ]; |
||
36 | |||
37 | /** |
||
38 | * {@inheritdoc}. |
||
39 | */ |
||
40 | protected $required = ['touser', 'template_id', 'form_id']; |
||
41 | |||
42 | /** |
||
43 | * @param int $offset |
||
44 | * @param int $count |
||
45 | * |
||
46 | * @return \Psr\Http\Message\ResponseInterface|\EasyWeChat\Kernel\Support\Collection|array|object|string |
||
47 | */ |
||
48 | public function list(int $offset, int $count) |
||
52 | |||
53 | /** |
||
54 | * @param string $id |
||
55 | * |
||
56 | * @return \Psr\Http\Message\ResponseInterface|\EasyWeChat\Kernel\Support\Collection|array|object|string |
||
57 | */ |
||
58 | public function get(string $id) |
||
62 | |||
63 | /** |
||
64 | * @param string $id |
||
65 | * @param array $keyword |
||
66 | * |
||
67 | * @return \Psr\Http\Message\ResponseInterface|\EasyWeChat\Kernel\Support\Collection|array|object|string |
||
68 | */ |
||
69 | public function add(string $id, array $keyword) |
||
76 | |||
77 | /** |
||
78 | * @param string $templateId |
||
79 | * |
||
80 | * @return \Psr\Http\Message\ResponseInterface|\EasyWeChat\Kernel\Support\Collection|array|object|string |
||
81 | */ |
||
82 | public function delete(string $templateId) |
||
88 | |||
89 | /** |
||
90 | * @param int $offset |
||
91 | * @param int $count |
||
92 | * |
||
93 | * @return \Psr\Http\Message\ResponseInterface|\EasyWeChat\Kernel\Support\Collection|array|object|string |
||
94 | */ |
||
95 | public function getTemplates(int $offset, int $count) |
||
99 | } |
||
100 |