Read service event by UUID
Trae el evento asociado a un UUID, en caso de dejar el campo en blanco, traera todos. Su uso es para buscar todos los eventos relacionados a un servicio en cuestión.
Endpoint
Headers
| Key | Value | Description | 
|---|---|---|
| Content-Type | application/json | |
| Authorization | Bearer MdJWfp154y0HN... | access_token obtained in Atenea | 
Url
Method: GET
URL: https://api.trust.lat/events/v1/event/service/:uuid
caution
Recuerda que para utilizar este endpoint es necesario un access token obtenido en el servicio Atenea
Path Variables
| Key | Example | Required | Description | 
|---|---|---|---|
| uuid | 1d8914e1-c5de-46df-9918-c0369df68bfb | false | Event id | 
Code Examples
- Curl
 - JavaScript
 - Python
 
curl --location --request GET 'https://api.trust.lat/events/v1/event/service/0a62774a-8a77...' \
--header 'Authorization: Bearer 5oHKgny0aK...'
import requests
url = "https://api.trust.lat/events/v1/event/service/0a62774a..."
payload={}
headers = {
  'Authorization': 'Bearer 5oHKgny0aK...'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text)
var axios = require('axios');
var config = {
  method: 'get',
  url: 'https://api.trust.lat/events/v1/event/service/0a62774a...',
  headers: { 
    'Authorization': 'Bearer 5oHKgny0aK...'
  }
};
axios(config)
.then(function (response) {
  console.log(JSON.stringify(response.data));
})
.catch(function (error) {
  console.log(error);
});
Responses
HTTP Code: 200 OK
{
    "code": 200,
    "resource": "Service Log",
    "data": {
        "audit_id": "",
        "company_id": "6",
        "created_at": "2021-07-13T22:36:33.778Z",
        "description": "device created",
        "operation": "CREATE",
        "relevance": "INFO",
        "resource": "DEVICE",
        "resource_id": "1111-2222-3333-4444",
        "resource_id_2": "",
        "result": true,
        "service": "INDEX",
        "user_id": "1",
        "uuid": "d538c40b..."
    },
    "message": "Found"
}
HTTP Code: 404 Not Found
{
    "code": 404,
    "resource": "Service Log",
    "message": "Not found"
}