I am trying to upoload a file to my laravel backend using form data and I need to send the jwt bearer token. What headers should I use.
I am trying to upoload a file to my laravel backend using form data and I need to send the jwt bearer token. What headers should I use.
You should send Authorization header with your request . please try like this.
const headers = new Headers({
'Authorization': `Bearer ${token}`
})
return this.http.post(apiUrl,formData , { headers: headers })