Skip to main content

API Reference: file-unassign


API Reference: file-unassign

Used to unassign a file from an entity.

URL : /api/v1/file/unassign/<fileId>

URL Parameters :

  • fileId=[integer] : a valid file ID

Method : PUT

Auth required : YES

Permissions required

  • Roles: _administrator_, developer, operator

Data constraints: None

Data example : None

Success Response

Code : 200 OK

Content example

PUT /api/v1/file/unassign/7

{
  "id": 7,
  "parent_combined_id": "5063_1_A_1",
  "type": null,
  "number": null,
  "filename": "CT_5063_1_A_1.F7.jpg",
  "original_filename": "UN_5063_1_A_2017-04-19_1.jpg",
  "filesize": 56300,
  "mime_type": "image/jpeg",
  "checksum": "e1abd5eb9bf664c1e2e9c98dce29e220",
  "upload_date": "2019-03-21 02:27:45",
  "expedition_id": 1,
  "site_id": 41,
  "hole_id": 205,
  "core_id": 38,
  "section_id": null,
  "remarks": "Some notes about the file assignment",
  "metadata": "FILE:\n- FileName: UN_5063_1_A_2017-04-19_1.jpg\n- FileSize: 56300\n- FileDateTime: 2019-03-21 02:27:45\n- MimeType: image/jpeg\n\n"
}