Obține token bearer
Obține tokenul bearer necesar pentru autentificare în aplicatie.
Endpoint
http
POST /api/v1/loginParametri
Parametri body
| Parametru | Tip | Obligatoriu | Descriere |
|---|---|---|---|
email | string | yes | Emailul înregistrat al utilizatorului. |
password | string | yes | Parola utilizatorului. |
Exemplu de cerere
sh
curl --location --request POST 'https://files.ro/api/v1/login' \
--header 'Content-Type: application/json' \
--data-raw '{
"email": "john@doe.com",
"password": "filesro"
}'Răspuns
json
{
"type": "success",
"message": "You were successfully authenticated",
"data": {
"token": "1|token"
}
}json
{
"message": "The given data was invalid.",
"errors": {
"field": [
"The field is required."
]
}
}json
{
"type": "error",
"message": "Email address is not verified."
}