Log Streamer

This API endpoint provides real-time access to raw system access logs. It is intended primarily for internal monitoring, debugging, and security audits, allowing authorized personnel to stream log data as it is generated.

Note: This endpoint is for Internal Use Only and may require elevated permissions or specific network access.

Endpoint

POST https://api.zapifyapi.com/v1/{api_token}

Path Parameters

Parameter Type Description
api_token string Required. Your unique API access token for the Log Streamer service.

Request Body

The request expects a JSON object. While the body can be empty to start a default stream, parameters can be added for filtering (if supported).

Key Type Description
(Empty) object Send an empty JSON object {} to initiate the standard log stream.

Example Request

cURL

curl -X POST "https://api.zapifyapi.com/v1/YOUR_API_TOKEN" 
     -H "Content-Type: application/json" 
     -d '{}'

Node.js

const axios = require("axios");

axios.post("https://api.zapifyapi.com/v1/YOUR_API_TOKEN", {})
.then(response => {
    console.log(response.data);
})
.catch(error => {
    console.error(error);
});

Response

Returns a JSON object containing the latest log entries.

{
    "status": "streaming",
    "logs": [
        "[INFO] 2023-10-27 10:00:01 - API Gateway started",
        "[INFO] 2023-10-27 10:05:23 - User login successful",
        "[WARN] 2023-10-27 10:12:45 - High latency detected on node-3"
    ],
    "count": 3
}