瀏覽代碼

增加aliSms服务

alexzy 3 年之前
父節點
當前提交
c8e3f98616
共有 1 個文件被更改,包括 23 次插入0 次删除
  1. 23 0
      src/AliSmsServiceInterface.php

+ 23 - 0
src/AliSmsServiceInterface.php

@@ -0,0 +1,23 @@
+<?php
+
+namespace Yxy\Service;
+
+interface AliSmsServiceInterface
+{
+    /**
+     * 发送短信验证码
+     * @param $phone
+     * @param string $scene
+     * @return bool
+     */
+    public function sendCodeSms($phone, string $scene = 'register'): bool;
+
+    /**
+     * 验证短信验证码
+     * @param $phone
+     * @param $code
+     * @param string $scene
+     * @return bool
+     */
+    public function checkSms($phone, $code, string $scene = 'register'): bool;
+}