Skip to content

Update Password

Change the authenticated dashboard user's password.

Endpoint

INFO

PUT /api/v1/dashboard/profile/password

Headers

HeaderValueRequired
Content-Typeapplication/jsonYes
Acceptapplication/jsonYes
AuthorizationBearer {token}Yes

Request Body

ParameterTypeRequiredDescription
current_passwordstringYesCurrent password
passwordstringYesNew password (min: 8 chars)
password_confirmationstringYesNew password confirmation

Example Request

bash
curl -X PUT https://api.daakey.com/api/v1/dashboard/profile/password \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer {token}" \
  -d '{
    "current_password": "oldPassword123",
    "password": "newSecurePassword456",
    "password_confirmation": "newSecurePassword456"
  }'

Response

Success (200)

json
{
  "success": true,
  "message": "Password updated successfully",
  "data": null,
  "request_id": "uuid",
  "timestamp": "2024-01-01T00:00:00.000Z"
}

Error (422)

json
{
  "success": false,
  "message": "Validation failed",
  "errors": {
    "current_password": ["The current password is incorrect."]
  },
  "data": null,
  "request_id": "uuid",
  "timestamp": "2024-01-01T00:00:00.000Z"
}

Notes

  • Current password must be correct
  • New password must be at least 8 characters
  • Current session remains active after password change

Daakey Car Sharing Platform