OnOffice icon

OnOffice

Consume OnOffice API

Actions15

Overview

This node integrates with the OnOffice API to manage real estate-related data. Specifically, for the Relation resource with the Get Many operation, it retrieves multiple relation records that link estates and addresses (contacts). This is useful when you want to fetch a list of relationships such as owners, tenants, interested parties, or contacts associated with estates or addresses.

Common scenarios include:

  • Retrieving all tenants related to a specific estate.
  • Listing all relations filtered by type or linked to particular estate or address IDs.
  • Fetching paginated results with limits and offsets for large datasets.

Practical example:

  • You want to get all "Owner" type relations for an estate with ID 12345, returning only the relation ID and estate ID fields, limited to 20 results starting from the first record.

Properties

Name Meaning
Fields Select which fields to return for each relation. Options: ID, Type, Estate ID, Address ID
Filter by Type Filter relations by their type. Options: Any (no filter), Owner, Tenant, Interested, Contact
Filter by Estate ID Filter relations linked to a specific estate ID (string)
Filter by Address ID Filter relations linked to a specific address ID (string)
Advanced Filter Additional advanced filter criteria in string form, merged with other filters
Limit Maximum number of results to return (number, default 50)
Offset Number of results to skip before starting to collect the result set (number, default 0)

Output

The output JSON contains the following structure:

  • success: Boolean indicating if the API call was successful.
  • resourceType: The resource queried, here always "relation".
  • operation: The operation performed, here "getMany".
  • data: An array of relation records, each containing the requested fields (e.g., id, type, estateid, addressid).
  • total (optional): Total count of matching records available on the server.
  • status / message: Status information or messages returned by the API.

Additionally, the node outputs debug information including the raw API response and the request sent, useful for troubleshooting.

No binary data is output by this node.

Dependencies

  • Requires an API token credential for authenticating with the OnOffice API.
  • Uses the OnOffice REST API endpoint at https://api.onoffice.de/api/latest/api.php.
  • The node internally generates HMAC signatures for request authentication.
  • No additional external dependencies beyond the OnOffice API and n8n's HTTP request helper.

Troubleshooting

  • Invalid JSON in Data Property: If creating or updating resources with JSON data, ensure the JSON is valid; otherwise, a parsing error will occur.
  • API Request Failed: Network issues or invalid credentials can cause failures. Check your API token and secret are correctly configured.
  • API Action Errors: The API may return errors with messages explaining the issue (e.g., invalid filters, missing required parameters). These are surfaced as node errors.
  • Unsupported Resource or Operation: Selecting a resource or operation not supported by the node will throw an error.
  • Pagination Limits: Large result sets should be paginated using limit and offset to avoid timeouts or excessive memory use.

To resolve errors:

  • Verify credentials and API access.
  • Validate input parameters and JSON syntax.
  • Use smaller limits and proper offsets for large queries.
  • Review API error messages for specific guidance.

Links and References


This summary focuses on the Relation resource's Get Many operation as requested, based on static analysis of the provided source code and property definitions.

Discussion