"cn-shenzhen", 'PhoneNumbers' => "13481194554", 'SignName' => "懒族生活", 'TemplateCode' => "SMS_201720790", 'TemplateParam' => json_encode(['name'=>'DESION','money'=>999]), ]; AlibabaCloud::accessKeyClient(env('OSS_ACCESS_ID'),env('OSS_ACCESS_SECRET')) ->regionId('cn-shenzhen') ->asDefaultClient(); try { $result = AlibabaCloud::rpc() ->product('Dysmsapi') ->version('2017-05-25') ->action('SendSms') ->method('POST') ->host('dysmsapi.aliyuncs.com') ->options([ 'query' => $params ]) ->request(); dd($result); }catch (ClientException $e){ echo $e->getErrorMessage() . PHP_EOL; }catch (ServerException $e){ echo $e->getErrorMessage() . PHP_EOL; } } public function testRpc() { $client = Client::factory('http://store.api.lanzulive.com:9505'); $request = $client->request(uniqid(),'/myrpc/mymethod', ['args' => null]); $response = $client->send($request); return $response->getBody()->getContents(); } }