Gitea icon

Gitea

Interact with Gitea via API

Actions393

Overview

This node operation marks notifications as read or changes their status in a notification system. It is useful for managing notification states programmatically, such as marking all notifications as read after processing them or updating the status of specific notifications based on criteria like last read time or current status.

Practical examples include:

  • Automatically marking all notifications as read when a user views their notification list.
  • Updating only unread notifications to read after a certain timestamp.
  • Changing the status of pinned notifications to read or another status.

Properties

Name Meaning
Last Read At Timestamp indicating the last point notifications were checked. Notifications updated since this time will not be changed.
All If set to true, marks all notifications on the repository regardless of other filters. Default is false.
Status Types Array specifying which notification statuses to mark (e.g., unread, read, pinned). Defaults to unread.
To Status The status to assign to the selected notifications. Defaults to "read".

Output

The node outputs JSON data representing the result of the notification update operation. This typically includes confirmation of which notifications were marked or updated and their new statuses. There is no indication that binary data is output by this node.

Dependencies

  • Requires an API key credential to authenticate with the notification service's API.
  • The base URL for the API must be configured in the node credentials.
  • Uses HTTP requests with query parameters corresponding to the input properties to perform the notification status updates.

Troubleshooting

  • Common issues:

    • Incorrect or missing API authentication can cause authorization errors.
    • Providing invalid timestamps or status types may result in failed requests or no notifications being updated.
    • Setting "All" to true without proper permissions might be rejected by the API.
  • Error messages:

    • Authorization errors indicate problems with the API key or credentials; verify and re-enter credentials.
    • Validation errors about query parameters suggest incorrect property values; ensure timestamps are ISO strings and status types are valid.
    • Empty results may mean no notifications matched the filter criteria; adjust filters accordingly.

Links and References

  • Refer to the notification service API documentation for details on notification status values and query parameters.
  • Consult n8n documentation on how to configure API credentials and use query parameter routing in nodes.

Discussion