Skip to content

DELETE /media/

Delete Media

DELETE
/media/{media_key}

Delete a media record and its file from disk.

Returns 404 if the media record does not exist. Returns 422 if the media
is still referenced by one or more media_connection edges — all connections
must be removed before the media can be deleted. On success, removes both
the Media document and the file from the filesystem.

Emits: (direct transaction — no event class)

Required scope: attachment:media:delete

Authorizations

OAuth2PasswordBearer
password Flow
Token URL"/api/auth"
Scopes:
  • "admin"User can access and edit users and system settings
  • "library"User can access and edit products
  • "production"User can access and edit production plans
  • "operator"User can access the operator panel and make production declarations

Parameters

Path Parameters

media_key*
Type
string
Required

Responses

Successful Response

application/json
JSON
{
  
"status": 200,
  
"message": "string",
  
"detail": "string"
}

Samples

Powered by VitePress OpenAPI

Released under the Apache 2.0 License.