public function __construct($api_user, $api_key) { // $this->api_user = env(SEND_CLOUD_USER); // $this->api_key = env(SEND_CLOUD_KEY); $this->api_user = $api_user; $this->api_key = $api_key; }
这是什么?你看了我给你的链接么?你配置了 env 之后,在 services.php 中配置:
'sendcloud' => [
'api_key' => env('SEND_CLOUD_KEY'),
'api_user' => env('SEND_CLOUD_USER')
]