I accept a response from a form and I want to create a request using Request::create() and pass parameters to it. But when the request gets created, the previous form request parameters is also attached. I want to clear those request and only pass parameters through Request::create() Below is my code:
$request = Request::create('api/my-api', 'POST', $response);
$request->headers->set('Content-Type', 'application/json');
$request->headers->set('api-key' , $api_key);
$request->headers->set('api-secret', $api_secret);
Route::dispatch($request)
Please help.
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire