如何通过post url传递api密钥。
下面是我的控制员,请指教
public function postOrder(Request $request)
{
$api_key = Config::get('app.key');
if ($api_key)
{
$Order = $request->only('no_of_kits', 'total')
$Order = new OrderTestKits;
$Order ->no_of_kits = $request->input('no_of_kits');
$Order ->total = $request->input('total');
$Order ->save();
return $Order ;
}
else
{
return "api key not found";
}
}