HAP icon

HAP

Interact with HAP (Hyper Application Platform) API

Overview

This node interacts with the HAP (Hyper Application Platform) API to retrieve operation logs related to a specific record in a worksheet. The "Get Logs" operation under the "Record" resource fetches detailed logs of actions performed on a particular record, such as creation, updates, deletions, restorations, and workflow operations.

This node is beneficial for auditing changes, tracking user activities, debugging workflows, or monitoring data modifications within an application built on the HAP platform. For example, a user can retrieve all update logs for a record to understand how its data evolved over time or filter logs by specific operators or date ranges to investigate suspicious activity.

Properties

Name Meaning
Worksheet ID The unique identifier of the worksheet containing the record.
Record ID The unique row ID of the record whose logs are being retrieved.
Page Size Number of log entries to return per page; maximum allowed is 500.
Page Index The page number to retrieve, starting from 1.
Log Type Filter logs by type. Options: All Types, Create Record, Delete Record, Restore Record, Update Record, Workflow Operation.
Start Date Filter logs starting from this date (format YYYY-MM-DD).
End Date Filter logs up to this date (format YYYY-MM-DD).
Operator IDs JSON array of operator user IDs to filter logs by specific users who performed the actions.
Field Filter logs by a specific field ID or alias within the record.

Output

The node outputs a JSON array of log entries corresponding to the requested filters and pagination. Each log entry typically contains details such as:

  • The type of operation performed (create, update, delete, etc.).
  • Timestamp of the operation.
  • Operator/user who performed the action.
  • Changes made to the record or specific fields.
  • Additional metadata relevant to the log entry.

If binary data were involved (not indicated here), it would represent attachments or files related to logs, but this operation focuses on JSON log data only.

Dependencies

  • Requires an API key credential for authenticating with the HAP API.
  • The node expects network access to the HAP service endpoint.
  • No additional external dependencies beyond the configured API authentication.

Troubleshooting

  • Common Issues:

    • Invalid or missing Worksheet ID or Record ID will result in errors or empty results.
    • Exceeding the maximum page size (over 500) may cause the request to fail.
    • Incorrect date formats for Start Date or End Date may lead to parsing errors.
    • Filtering by Operator IDs requires valid user IDs; invalid IDs may yield no results.
  • Error Messages:

    • Authentication errors indicate issues with the provided API key credential; verify and reconfigure if needed.
    • "Record not found" or similar messages suggest the specified record or worksheet does not exist or is inaccessible.
    • Rate limiting or timeout errors may occur if too many requests are sent in a short period; implement retries or backoff strategies.

Links and References

Discussion