Skip to content

Update Damage Report

Update an existing damage report.

Endpoint

INFO

PUT /api/v1/dashboard/damages/{damage}

Headers

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

Path Parameters

ParameterTypeDescription
damageintegerDamage report ID

Request Body

ParameterTypeRequiredDescription
typestringNoDamage type
locationstringNoDamage location
severitystringNoSeverity level
descriptionstringNoDescription
estimated_costdecimalNoEstimated repair cost
notesstringNoInternal notes

Example Request

bash
curl -X PUT https://api.daakey.com/api/v1/dashboard/damages/1 \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer {token}" \
  -d '{
    "severity": "moderate",
    "estimated_cost": 250.00,
    "notes": "Needs professional touch-up"
  }'

Response

Success (200)

json
{
  "success": true,
  "message": "Damage report updated",
  "data": {
    "id": 1,
    "severity": "moderate",
    "repair": {
      "estimated_cost": 250.00,
      "notes": "Needs professional touch-up"
    },
    "updated_at": "2024-01-15T12:00:00Z"
  },
  "request_id": "uuid",
  "timestamp": "2024-01-01T00:00:00.000Z"
}

Daakey Car Sharing Platform