Actions3
- Messages (Komens) Actions
Overview
This node interacts with the Bakalari school system API, specifically focusing on handling messages (called "Komens"). The "Get Received" operation retrieves messages that have been received by the user from the Bakalari system.
Typical use cases include:
- Automatically fetching new incoming messages for a student or teacher.
- Integrating received messages into other workflows, such as notifications or logging.
- Filtering and processing received communications within an educational environment.
For example, a school administrator could use this node to pull all received messages for a particular user and then trigger alerts or archive them in another system.
Properties
| Name | Meaning |
|---|---|
| Additional Fields | Collection of optional parameters. |
| - Limit | Max number of results to return. Number between 1 and 1000. Limits how many messages are fetched. |
Output
The output is an array of JSON objects representing individual messages retrieved from the Bakalari system. Each message object includes all original message fields returned by the API, augmented with two additional properties:
operation: The operation performed, here always"getReceived".resource: The resource type, here always"komens".
If no messages are found, the output will contain the full response object instead.
No binary data is output by this node.
Example output JSON structure for each message item:
{
"id": "12345",
"sender": "Teacher Name",
"subject": "Homework Update",
"content": "Please complete your homework by Friday.",
"dateSent": "2024-06-01T12:00:00Z",
"operation": "getReceived",
"resource": "komens"
}
Dependencies
- Requires an API key credential with username, password, and school URL to authenticate against the Bakalari API.
- The node performs an OAuth-like login to obtain an access token before making requests.
- The API endpoint URLs depend on the provided school URL.
- No additional external dependencies beyond the Bakalari API and n8n's HTTP request helper.
Troubleshooting
- No access token received: This error occurs if the login request does not return an access token. Verify that the credentials (username, password, school URL) are correct and that the Bakalari API is reachable.
- Unsupported operation: If an invalid operation is selected, the node throws an error. Ensure the operation is one of the supported options ("Get Noticeboard", "Get Received", "Get Sent").
- Empty or unexpected response: If the API returns no messages or a different structure, check the API documentation and confirm the account has messages available.
- Limit parameter issues: Setting the limit outside the allowed range (1-1000) may cause unexpected behavior. Use valid numbers only.
Links and References
- Bakalari School System API Documentation (Note: link is illustrative, replace with actual if available)
- n8n HTTP Request Node Documentation: https://docs.n8n.io/nodes/n8n-nodes-base.httpRequest/