Skip to main content

Delete Tags From File

Endpoint destinado a eliminar tags de un archivo. Para realizar este procedimiento es necesario ingresar un body del tipo JSON que contenga un listado de claves a eliminar. Se debe respetar el formato Array\<String>, es decir, que cada clave ingresada sea del tipo String.

Endpoint#

Headers

KeyValueDescription
Content-Typeapplication/json
AuthorizationBearer {{access_token}}access_token obtained in Atenea

Url

Method: DELETE
URL: https://api.trust.lat/chronos/v1/file_registers/:uuid/tags/
caution

Recuerda que para utilizar este endpoint es necesario un access token obtenido en el servicio Atenea

Como obtener un access token

Path Variables

KeyValueDescription
uuid'ffffffff-ffff-ffff-ffff-ffffffffffff'Identificador único del archivo

Body#

{
"tags_keys": ["company"]
}

Code Examples#

curl --location --request DELETE 'https://api.trust.lat/chronos/v1/file_registers/ffffffff-ffff-ffff-ffff-ffffffffffff/tags/' \
--header 'Authorization: Bearer {{access_token}}' \
--header 'Content-Type: application/json' \
--data-raw '{
"tags_keys": ["company"]
}'

Responses#

HTTP Code: 200 OK (Tags successfully deleted)#

{
"code": 200,
"resource": "File Register",
"data": {
"uuid": "ffffffff-ffff-ffff-ffff-ffffffffffff",
"name": "forest2.jpg",
"size": "1351.80078125 KB",
"created_at": "2021-09-23T21:01:51.373Z",
"tags": {
"rut": "185924300",
"workspace": "home"
},
"path": "forest2.jpg"
},
"message": "Ok"
}

HTTP Code: 200 OK (No tags deleted)#

{
"code": 200,
"resource": "File Register",
"data": {
"uuid": "ffffffff-ffff-ffff-ffff-ffffffffffff",
"name": "forest4.jpg",
"size": "3495.1787109375 KB",
"created_at": "2021-09-23T21:08:40.663Z",
"tags": {},
"path": "forest4.jpg"
},
"message": "No tags deleted"
}

HTTP Code: 404 Not Found#

{
"code": 404,
"resource": "File Register",
"message": "Not found"
}
Last updated on by Claudio-Franco