OnOffice icon

OnOffice

Consume OnOffice API

Overview

This node integrates with the OnOffice API to manage real estate-related data. Specifically, for the Estate resource and the Update operation, it updates an existing estate record identified by its ID. This is useful in scenarios where property details need to be modified or corrected after creation, such as updating pricing, descriptions, or status.

Practical examples include:

  • Updating the details of a property listing after receiving new information.
  • Correcting errors in previously entered estate data.
  • Changing the availability status of a property.

Properties

Name Meaning
ID The unique identifier of the estate record to update.
Include Debug Info Whether to include detailed debug information (such as raw API response and request) in the output.

Output

The node outputs JSON data structured as follows:

  • If Include Debug Info is enabled, the output includes:

    • debug: A boolean flag set to true.
    • rawResponse: The full raw response from the OnOffice API.
    • requestSent: The exact request payload sent to the API.
    • url: The API endpoint URL used.
  • Otherwise, the output contains:

    • success: Boolean indicating if the update was successful.
    • resourceType: The resource type, here always "estate".
    • operation: The operation performed, here "update".
    • data: An array (empty in this implementation, but could be extended with updated data).

If an error occurs and the node is configured to continue on failure, the output will contain:

  • success: false
  • error: The error message
  • resourceType and operation fields for context.

Dependencies

  • Requires valid credentials for the OnOffice API, specifically an API token and secret.
  • Uses HMAC signature generation for authentication.
  • Makes HTTP POST requests to the OnOffice API endpoint:
    https://api.onoffice.de/api/latest/api.php (or a legacy endpoint for certain relation queries).
  • Requires n8n's HTTP Request helper and credential management.

Troubleshooting

  • Common issues:

    • Invalid or expired API credentials will cause authentication failures.
    • Providing an incorrect or non-existent estate ID will result in API errors.
    • Network connectivity problems can prevent reaching the OnOffice API.
    • Misconfiguration of the "Include Debug Info" property may lead to large outputs.
  • Error messages:

    • "OnOffice API error: <message>" indicates an error returned by the API; check the message for specifics.
    • Unknown errors may occur if the API response is malformed or unexpected.
  • Resolutions:

    • Verify that the API token and secret are correct and have necessary permissions.
    • Confirm the estate ID exists and is correctly formatted.
    • Enable "Include Debug Info" to get detailed request/response data for debugging.
    • Ensure stable internet connection and that the API endpoint is reachable.

Links and References

Discussion