DELETE 5 min read

Delete Part Image

DELETE /api/v1/parts/{id}/image

Remove the image from a part

Delete Part Image

Remove the image associated with a part.

Path Parameters

Parameter Type Description
id integer The part ID

Example Request

curl -X DELETE "https://hydra.marketdragon.ph/api/v1/parts/1/image" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Accept: application/json"

Example Response

{
    "data": {
        "id": 1,
        "company_id": 1,
        "name": "Oil Filter",
        "part_number": "OF-12345",
        "sku": "SKU-001",
        "description": "Premium oil filter for most vehicles",
        "category": "Filters",
        "brand": "FilterPro",
        "cost_price": "150.00",
        "selling_price": "250.00",
        "quantity_in_stock": 25,
        "reorder_level": 10,
        "unit": "pcs",
        "is_active": true,
        "stock_status": "in_stock",
        "is_low_stock": false,
        "profit_margin": 66.67,
        "thumbnail_url": null,
        "image_url": null,
        "created_at": "2024-01-15T08:30:00+00:00",
        "updated_at": "2024-01-20T17:00:00+00:00"
    }
}

Error Responses

403 Forbidden

{
    "message": "You do not have access to this part."
}

404 Not Found

{
    "message": "No query results for model [Part] 999"
}
Back to Parts
Was this helpful?