Lexoffice Public API icon

Lexoffice Public API

Contacts the Lexoffice Public API

Overview

This n8n node allows you to update an existing contact in the Lexoffice system via its Public API. Specifically, it performs a "PUT" operation on a contact resource, enabling you to modify details such as company information, addresses, email addresses, phone numbers, and more. This is useful for automating customer or vendor data management workflows, keeping your Lexoffice contacts up-to-date from other systems, or integrating Lexoffice with CRM/ERP tools.

Example scenarios:

  • Automatically updating contact information in Lexoffice when changes are made in your CRM.
  • Syncing address or contact person updates from another business application.
  • Bulk-updating multiple contacts' details based on external triggers.

Properties

Name Type Meaning
Category options Selects the type of resource to interact with. For this operation, should be set to "Contacts".
Contact ID string The unique identifier of the contact to update in Lexoffice. Required for identifying which contact record will be modified.
JSON json The full contact object in JSON format containing all fields to update. This includes IDs, version, roles, company info, addresses, emails, phone numbers, notes, and archive status. Must be valid JSON.

Output

  • json: The response from the Lexoffice API after updating the contact. The structure typically mirrors the updated contact object, including all fields that were sent and any additional metadata returned by Lexoffice.
  • If the API returns an error and "Continue On Fail" is enabled, the output will include an error field with the error message, an empty json object, and the itemIndex.

Example output (success):

{
  "json": {
    "id": "df315523-1e92-473a-9d00-052212da84f8",
    "version": 2,
    "roles": { ... },
    "company": { ... },
    "addresses": { ... },
    "emailAddresses": { ... },
    "phoneNumbers": { ... },
    "note": "Notizen",
    "archived": false
  }
}

Example output (failure, with Continue On Fail):

{
  "error": "Error message here",
  "json": {},
  "itemIndex": 0
}

Dependencies

  • Lexoffice Public API: Requires access to the Lexoffice API endpoint.
  • API Credentials: You must provide a valid API token and domain via n8n credentials named lexofficePuplicApi.
  • n8n Configuration: No special environment variables required beyond standard credential setup.

Troubleshooting

Common issues:

  • Invalid JSON: If the "JSON" property contains malformed JSON, the node will return an error like Error parsing JSON. Ensure your input is valid JSON.
  • Missing or incorrect Contact ID: If the "Contact ID" does not match an existing contact, the API may return a "not found" or similar error.
  • Authentication errors: If the API token or domain is missing or invalid, you'll receive authentication/authorization errors from Lexoffice.
  • Field validation errors: If required fields are missing or have invalid values in the JSON body, Lexoffice will return descriptive error messages.

Error messages:

  • "No API Item found": Likely indicates a misconfiguration of the category or operation properties.
  • "Error parsing JSON": The provided JSON is not valid; check for syntax errors.
  • API-specific errors: These will be passed through from Lexoffice and can include details about missing fields, invalid data, or permission issues.

Links and References

Discussion