curl --request GET \
--url https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts \
--header 'Authorization: Bearer <token>'import requests
url = "https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"MachineID": 123,
"EventDateTimeVMC": "2023-11-07T05:31:56Z",
"TransactionID": 123,
"EventLogID": 123,
"SiteID": 123,
"EntityTypeID": 123,
"EntityTypeName": "<string>",
"DeviceID": 123,
"EntityActorID": 123,
"EventDateTimeGMT": "2023-11-07T05:31:56Z",
"EventCode": 123,
"EventSourceID": 123,
"EventSourceName": "<string>",
"EventGroupId": 123,
"EventGroupName": "<string>",
"EventCategoryId": 123,
"EventCategoryName": "<string>",
"EventDescription": "<string>",
"EventData": "<string>",
"JSONData": "<string>",
"EventUserID": 123
}
]Get Machine Last Alerts
Retrieves the most recent alerts for a specific machine identified by the provided MachineID. This helps in monitoring recent issues or notifications related to the machine’s operation.
curl --request GET \
--url https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts \
--header 'Authorization: Bearer <token>'import requests
url = "https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://qa-lynx.nayax.com/operational/v1/machines/{MachineID}/lastAlerts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"MachineID": 123,
"EventDateTimeVMC": "2023-11-07T05:31:56Z",
"TransactionID": 123,
"EventLogID": 123,
"SiteID": 123,
"EntityTypeID": 123,
"EntityTypeName": "<string>",
"DeviceID": 123,
"EntityActorID": 123,
"EventDateTimeGMT": "2023-11-07T05:31:56Z",
"EventCode": 123,
"EventSourceID": 123,
"EventSourceName": "<string>",
"EventGroupId": 123,
"EventGroupName": "<string>",
"EventCategoryId": 123,
"EventCategoryName": "<string>",
"EventDescription": "<string>",
"EventData": "<string>",
"JSONData": "<string>",
"EventUserID": 123
}
]Authorizations
Enter your Bearer token. It's required to authenticate API requests.
Path Parameters
The unique identifier of the machine whose last alerts are being requested.
Response
A list of the most recent alerts for the specified machine.
The unique identifier of the machine associated with the alert.
The date and time of the event as recorded by the machine (VMC).
The unique identifier of the transaction associated with the event, if applicable.
The unique identifier of the event log entry.
The unique identifier of the site where the machine is located.
The unique identifier for the type of entity involved in the event.
The name of the entity type involved in the event.
The unique identifier of the device associated with the event.
The unique identifier of the actor (e.g., user or machine) associated with the event.
The date and time of the event in GMT.
A code representing the type of event that occurred.
The unique identifier of the source from which the event originated.
The name of the source from which the event originated.
The unique identifier of the group to which the event belongs.
The name of the group to which the event belongs.
The unique identifier of the category to which the event belongs.
The name of the category to which the event belongs.
A textual description of the event.
Additional data related to the event, provided as a string.
The event data in JSON format, if applicable.
The unique identifier of the user associated with the event, if applicable.
Was this page helpful?